cmd/recycle.py

15 lines
363 B
Python
Raw Normal View History

2020-08-11 03:51:51 +00:00
import send2trash
import sys
2020-08-11 03:51:51 +00:00
from voussoirkit import pathclass
from voussoirkit import pipeable
2020-08-11 03:51:51 +00:00
def main(argv):
for path in pathclass.glob_many(pipeable.go(argv, skip_blank=True)):
pipeable.stdout(path.absolute_path)
send2trash.send2trash(path.absolute_path)
return 0
if __name__ == '__main__':
raise SystemExit(main(sys.argv[1:]))