This website requires JavaScript.
CODE
0x495fab29
Explore
Sign in
forks
/
apenwarr-redo
Watch
1
Star
0
Fork
You've already forked apenwarr-redo
0
Code
Issues
Pull requests
Projects
Releases
Packages
Wiki
Activity
Actions
d0607d0091
apenwarr-redo
/
t
/
360-symlinks
/
a.do
4 lines
67 B
Text
Raw
Normal View
History
Unescape
Escape
minimal/do: don't create a .did file until after a file is actually built. With the new "continue" feature on by default, it turned out that ctrl-c during a build, or a .do file returning an error, would mark a target as "built" even though it hadn't been. This would prevent retrying it when you started minimal/do again. Use a temp file instead. It's a little tricky: to prevent accidental recursion, we want to create a file *before* building, but clean up that file when starting the next session. And we rename that file to the actual .did file *after* building successfully.
2018-11-02 03:48:25 -04:00
echo x >>a.ran
Use os.lstat() instead of os.stat(). I think this aligns better with how redo works. Otherwise, if a.do creates a as a symlink, then changes to the symlink's *target* will change a's stat/stamp information without re-running a.do, which looks to redo like you modified a by hand, which causes it to stop running a.do altogether. With this change, modifications to a's target are okay, but they don't trigger any redo dependency changes. If you want that, then a.do should redo-ifchange on its symlink target explicitly.
2018-10-06 00:14:02 -04:00
rm -f $2.extra
echo foo >$2.extra
ln -s $2.extra $3
Reference in a new issue
Copy permalink