Commit a7f49c6
committed
ScriptInfo: do not mix datestamp into the version
At the time I wrote that code, I was mainly concerned with ensuring that
generated version strings do not clash. However, there are compelling
reasons to avoid "false negatives" as well (two scripts which are
actually the same, but end up with differing version strings).
When mixing in the datestamp with the hash, a false negative will happen
if the script's last modified date is not preserved when copied between
systems. This makes data provenance more difficult, because two systems
may have identical installations content-wise, but different version
strings due to timestamp skew.
So, let's keep it simpler: use the content hash if available (i.e.:
if the script contents can be read), and the datestamp only if not.1 parent aef704c commit a7f49c6
1 file changed
+4
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
322 | 322 | | |
323 | 323 | | |
324 | 324 | | |
325 | | - | |
326 | | - | |
327 | | - | |
328 | 325 | | |
329 | | - | |
330 | | - | |
| 326 | + | |
331 | 327 | | |
332 | 328 | | |
333 | 329 | | |
334 | 330 | | |
| 331 | + | |
| 332 | + | |
| 333 | + | |
335 | 334 | | |
336 | 335 | | |
337 | 336 | | |
| |||
0 commit comments