Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: trigger rerun when new files are yield by an input function
Added the "missing" input flags to trigger rerun when new files are yield by an input function. Such flag is forwarded to all elements yield by the input function.
- Loading branch information
Christophe Clienti
committed
Mar 10, 2022
1 parent
5355f5a
commit ceb3ba9
Showing
14 changed files
with
186 additions
and
40 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -41,6 +41,7 @@ | |
temp, | ||
temporary, | ||
ancient, | ||
missing, | ||
directory, | ||
expand, | ||
dynamic, | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
rule all: | ||
input: "A1.txt", "A2.txt" | ||
|
||
rule A: | ||
input: "A{index}.tmp" | ||
output: "A{index}.txt" | ||
shell: "cp {input} {output}" | ||
|
||
|
||
rule A_TMP_1: | ||
input: | ||
"B-fred.txt" | ||
|
||
output: | ||
temp("A1.tmp") | ||
|
||
run: | ||
f = open(output[0], "w") | ||
f.write(' '.join(input) + "\n") | ||
|
||
rule A_TMP_2: | ||
input: | ||
missing(lambda wildcards: [rules.B.output[0].format(name=name) | ||
for name in config.get("names", "john").split(",")]) | ||
output: | ||
temp("A2.tmp") | ||
|
||
run: | ||
f = open(output[0], "w") | ||
f.write(' '.join(input) + "\n") | ||
|
||
rule B: | ||
output: | ||
touch("B-{name}.txt") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
B-fred.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
B-john.txt B-doe.txt |
Empty file.
Empty file.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters