mirror of
https://github.com/marty-oehme/scripts.git
synced 2024-12-22 16:08:09 +00:00
Minor tweaks
This commit is contained in:
parent
96abe16fa7
commit
ba259c6e2f
1 changed files with 3 additions and 3 deletions
|
@ -251,9 +251,6 @@ if __name__ == '__main__':
|
||||||
if file[-5:] == '.lock':
|
if file[-5:] == '.lock':
|
||||||
os.remove(script_path + os.sep + file)
|
os.remove(script_path + os.sep + file)
|
||||||
|
|
||||||
lockfile_path = script_path + os.sep + str(int(time.time())) + '.lock'
|
|
||||||
open(lockfile_path, 'w').close()
|
|
||||||
|
|
||||||
arg_parser = argparse.ArgumentParser(description='A script to turn everything in the inbox directory to markdown notes.')
|
arg_parser = argparse.ArgumentParser(description='A script to turn everything in the inbox directory to markdown notes.')
|
||||||
arg_parser.add_argument('-i', '--inbox', action='store', dest='inbox_dir', required=True,
|
arg_parser.add_argument('-i', '--inbox', action='store', dest='inbox_dir', required=True,
|
||||||
help="Full absolute path to the inbox directory to organize")
|
help="Full absolute path to the inbox directory to organize")
|
||||||
|
@ -335,6 +332,9 @@ if __name__ == '__main__':
|
||||||
write_note_and_delete(obj_to_write)
|
write_note_and_delete(obj_to_write)
|
||||||
|
|
||||||
|
|
||||||
|
lockfile_path = script_path + os.sep + str(int(time.time())) + '.lock'
|
||||||
|
open(lockfile_path, 'w').close()
|
||||||
|
|
||||||
event_handler = FsEventHandler()
|
event_handler = FsEventHandler()
|
||||||
observer = watchdog.observers.Observer()
|
observer = watchdog.observers.Observer()
|
||||||
observer.schedule(event_handler, scan_path, recursive=True)
|
observer.schedule(event_handler, scan_path, recursive=True)
|
||||||
|
|
Loading…
Reference in a new issue