Skip to content

Commit

Permalink
overwrite system temp directory for panaroo python instance to redire…
Browse files Browse the repository at this point in the history
…ct gffutils temporary files
  • Loading branch information
gtonkinhill committed Feb 18, 2024
1 parent 1a6c59a commit 735065d
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion panaroo/__init__.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
'''An updated pipeline for pangenome investigation'''
__version__ = '1.4.0'
__version__ = '1.4.1'
1 change: 1 addition & 0 deletions panaroo/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -294,6 +294,7 @@ def main():
args.output_dir = os.path.join(args.output_dir, "")
# Create temporary directory
temp_dir = os.path.join(tempfile.mkdtemp(dir=args.output_dir), "")
os.environ['TMPDIR'] = temp_dir

# check if input is a file containing filenames
if len(args.input_files) == 1:
Expand Down
1 change: 1 addition & 0 deletions panaroo/integrate.py
Original file line number Diff line number Diff line change
Expand Up @@ -260,6 +260,7 @@ def main():

# Create temporary directory
temp_dir = os.path.join(tempfile.mkdtemp(dir=args.output_dir), "")
os.environ['TMPDIR'] = temp_dir

directories = [args.input_dir, temp_dir]

Expand Down
1 change: 1 addition & 0 deletions panaroo/merge_graphs.py
Original file line number Diff line number Diff line change
Expand Up @@ -596,6 +596,7 @@ def main():

# create temporary directory
temp_dir = os.path.join(tempfile.mkdtemp(dir=args.output_dir), "")
os.environ['TMPDIR'] = temp_dir

# run the main merge script
merge_graphs(directories=args.directories,
Expand Down
1 change: 1 addition & 0 deletions panaroo/run_prokka.py
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,7 @@ def run_prokka_mod(input_file, out_folder, train_file, force, add_cmds):
# Create temporary directory
temp_dir = os.path.join(os.path.abspath(tempfile.mkdtemp(dir=out_folder)),
"")
os.environ['TMPDIR'] = temp_dir
with open(temp_dir + "/prodigal", 'w') as outfile:
outfile.write("#!/bin/bash\n")
outfile.write("(>&2 echo 'running prokka mod!')\n")
Expand Down

0 comments on commit 735065d

Please sign in to comment.