1. Sean Davis
  2. Snakemake

Commits

Johannes Köster  committed 08bd56e

Make snakemake work better with sbatch.

  • Participants
  • Parent commits d1c168d
  • Branches master

Comments (0)

Files changed (3)

File snakemake/__init__.py

View file
     return parser
 
 
-def get_snakemake_path():
-    return os.path.realpath(inspect.getmodule(inspect.stack()[1][0]).__file__)
-
-
 def main():
     parser = get_argument_parser()
     args = parser.parse_args()
         print("complete -C snakemake-bash-completion snakemake")
         sys.exit(0)
 
-    snakemakepath = get_snakemake_path()
+    snakemakepath = sys.argv[0]
 
     try:
         resources = parse_resources(args)

File snakemake/workflow.py

View file
         self.rule_count = 0
         self.basedir = os.path.dirname(snakefile)
         self.snakefile = os.path.abspath(snakefile)
-        self.snakemakepath = os.path.abspath(snakemakepath)
+        self.snakemakepath = snakemakepath
         self.jobscript = jobscript
         self.persistence = None
         self.global_resources = None

File tests/test07/Snakefile

View file
+
 rule rule1:
 	input: 'test.in'
 	output: 'test.out'