|
20 | 20 |
|
21 | 21 | /** |
22 | 22 | * Turns a directory into one gzipped tar layer. |
23 | | - * |
24 | | - * @implNote every field that could vary between two builds of the same tree is pinned: entries are |
25 | | - * sorted, modification times are zero, and uid and gid are zero with no owner names. Without that |
26 | | - * the digest changes on every build and the node re-pulls a layer whose content is identical. |
| 23 | + * Every field that could vary between two builds of the same tree is pinned: entries are sorted, modification |
| 24 | + * times are zero, and uid and gid are zero with no owner names. Without that the digest changes on every |
| 25 | + * build and the node re-pulls a layer whose content is identical. |
27 | 26 | * |
28 | 27 | * @author Finn Birich |
29 | 28 | */ |
@@ -84,9 +83,9 @@ public int compare(Path a, Path b) { |
84 | 83 | } |
85 | 84 |
|
86 | 85 | /** |
87 | | - * @implNote a rule, not an inspection: Windows cannot report the POSIX executable bit, so |
88 | | - * reading it would make the layer depend on which machine built it, and the launcher script |
89 | | - * would be non-executable exactly on the machine this project is developed on. |
| 86 | + * A rule, not an inspection: Windows cannot report the POSIX executable bit, so reading it would make the |
| 87 | + * layer depend on which machine built it, and the launcher script would be non-executable exactly on the |
| 88 | + * machine this project is developed on. |
90 | 89 | */ |
91 | 90 | static boolean isUnderBin(String nameInArchive) { |
92 | 91 | return nameInArchive.contains("/bin/") || nameInArchive.startsWith("bin/"); |
@@ -114,22 +113,22 @@ static List<String> directoriesFor(String prefix, Path source, List<Path> files) |
114 | 113 | } |
115 | 114 |
|
116 | 115 | /** |
117 | | - * @implNote {@code Path} natural ordering is case-insensitive on Windows and case-sensitive on |
118 | | - * Linux, so sorting by {@code Path} directly would order two names differing only by case |
119 | | - * differently depending on the building platform, changing the digest with it. This is the |
120 | | - * string that is actually written to the archive, so sorting by it is platform-independent. |
| 116 | + * {@code Path} natural ordering is case-insensitive on Windows and case-sensitive on Linux, so sorting by |
| 117 | + * {@code Path} directly would order two names differing only by case differently depending on the |
| 118 | + * building platform, changing the digest with it. This is the string that is actually written to the |
| 119 | + * archive, so sorting by it is platform-independent. |
121 | 120 | */ |
122 | 121 | static String archiveName(Path source, Path file) { |
123 | 122 | return source.relativize(file).toString().replace('\\', '/'); |
124 | 123 | } |
125 | 124 |
|
126 | 125 | /** |
127 | | - * @implNote the uid, gid and owner name calls are redundant with commons-compress 1.24.0's own |
128 | | - * defaults for the {@code TarArchiveEntry(String)} constructor used above: it reads |
129 | | - * {@code userName} from {@code System.getProperty("user.name")} during construction and resets |
130 | | - * it to {@code ""} immediately afterward, in that same overload's own body. The calls stay to |
131 | | - * guard against a future change to which constructor is used, which would otherwise leak the |
132 | | - * building machine's identity into the layer and silently break cross-machine determinism. |
| 126 | + * The uid, gid and owner name calls are redundant with commons-compress 1.24.0's own defaults for the |
| 127 | + * {@code TarArchiveEntry(String)} constructor used above: it reads {@code userName} from |
| 128 | + * {@code System.getProperty("user.name")} during construction and resets it to {@code ""} immediately |
| 129 | + * afterward, in that same overload's own body. The calls stay to guard against a future change to which |
| 130 | + * constructor is used, which would otherwise leak the building machine's identity into the layer and |
| 131 | + * silently break cross-machine determinism. |
133 | 132 | */ |
134 | 133 | private static void pin(TarArchiveEntry entry, int mode, long size) { |
135 | 134 | entry.setMode((entry.isDirectory() ? TarArchiveEntry.DEFAULT_DIR_MODE : 0) | mode); |
|
0 commit comments