Skip to content

Commit

Permalink
Didn't need branch in the end at all
Browse files Browse the repository at this point in the history
  • Loading branch information
Simon Guest committed Oct 7, 2024
1 parent b5ba520 commit 28ca3ca
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions workflow/playpen.smk
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,8 @@ rule a2b:
output: "{path}.b"
shell: "sed -e 's/a/b/g' {wildcards.path}.a >{wildcards.path}.b"

def wildcard_path_endswith_gz(wildcards):
return wildcards["path"].endswith(".gz")

rule gunzip:
input:
branch(wildcard_path_endswith_gz,
then=[],
otherwise="{path}.gz")
input: "{path}.gz"
output: "{path}"
shell: "gunzip -k {wildcards.path}.gz"

Expand Down

0 comments on commit 28ca3ca

Please sign in to comment.