You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
353 B

  1. #!/usr/bin/env python3
  2. import os
  3. import sys
  4. import tempfile
  5. (fd,filepath) = tempfile.mkstemp(dir=sys.argv[1])
  6. ino = os.fstat(fd).st_ino
  7. os.unlink(filepath)
  8. for entry in os.scandir(sys.argv[1]):
  9. if entry.inode() == ino:
  10. print("found .fuse_hidden file {}".format(entry.name),end='')
  11. os.close(fd)
  12. sys.exit(1)
  13. os.close(fd)