Skip to content

v1.6.1 . Tweaked GoCache

Compare
Choose a tag to compare
@natefinch natefinch released this 20 Sep 01:21
· 92 commits to master since this release
8c5bce8

Fixed

PR #172 brought up a problem with systems where the magefile cachedir is on a different drive. On these machines, trying to move the generated mainfile fails because it's not a simple rename, you have to copy the data. However, this defeats the purpose of moving the mainfile, which was just to retain the modtime so the go tool wouldn't think it was newer than the compiled binary.

Upon more reflection the obvious thing to do is just to generate the mainfile tweak its mod time to be old. That's what this change does, which greatly simplifies that code, and fixes the bug.

Changelog

Don't cache mainfiles, just set modtime (#173)