Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def main():
logging.basicConfig()
args = parse_args()
if args.debug:
logging.getLogger().setLevel(logging.DEBUG)
argv = args.argv_prefix if args.argv_prefix else ("bash", "-c")
operations = BashFS(argv_prefix=argv, separator=args.separator.encode())
fuse_options = set(pyfuse3.default_options)
fuse_options.add("fsname=bashfs")
fuse_options.discard("default_permissions")
if args.debug_fuse:
fuse_options.add("debug")
pyfuse3.init(operations, args.mountpoint, fuse_options)
try:
trio.run(pyfuse3.main)
except:
pyfuse3.close(unmount=True)
raise
pyfuse3.close()