apenwarr-redo/redo/cmd_always.py
Avery Pennarun bd8dbfb487 Switch to module-relative import syntax.
Now that the python scripts are all in a "redo" python module, we can
use the "new style" (ahem) package-relative imports.  This appeases
pylint, plus avoids confusion in case more than one package has
similarly-named modules.
2018-12-05 02:34:36 -05:00

22 lines
517 B
Python

import sys, os
from . import env, state
def main():
try:
env.inherit()
me = os.path.join(env.v.STARTDIR,
os.path.join(env.v.PWD, env.v.TARGET))
f = state.File(name=me)
f.add_dep('m', state.ALWAYS)
always = state.File(name=state.ALWAYS)
always.stamp = state.STAMP_MISSING
always.set_changed()
always.save()
state.commit()
except KeyboardInterrupt:
sys.exit(200)
if __name__ == '__main__':
main()