From 4f99973787cff1cc0b2478b53a142f237495b509 Mon Sep 17 00:00:00 2001 From: GitHub Actions Date: Fri, 4 Aug 2023 15:03:46 +0000 Subject: [PATCH] markdown source builds Auto-generated via {sandpaper} Source : c6ba6d114f6547f9cbce4b9cadf760034d9bf89c Branch : main Author : Trevor Keller Time : 2023-08-04 15:02:27 +0000 Message : Merge pull request #10 from carpentries-incubator/snakefiles Draft example snakefiles. --- files/Snakefile_amdahl_cluster | 8 ++++++++ files/Snakefile_cluster | 4 ++++ files/Snakefile_hello | 4 ++++ files/Snakefile_tworules | 9 +++++++++ 4 files changed, 25 insertions(+) create mode 100644 files/Snakefile_amdahl_cluster create mode 100644 files/Snakefile_cluster create mode 100644 files/Snakefile_hello create mode 100644 files/Snakefile_tworules diff --git a/files/Snakefile_amdahl_cluster b/files/Snakefile_amdahl_cluster new file mode 100644 index 0000000..eca4d3e --- /dev/null +++ b/files/Snakefile_amdahl_cluster @@ -0,0 +1,8 @@ +rule one: + input: + output: 'amdahl_cluster.txt' + resources: + mpi="mpirun", + tasks=3 + shell: + "module load OpenMPI; mpirun -np {resources.tasks} amdahl > amdahl_cluster.txt" diff --git a/files/Snakefile_cluster b/files/Snakefile_cluster new file mode 100644 index 0000000..ac60d86 --- /dev/null +++ b/files/Snakefile_cluster @@ -0,0 +1,4 @@ +rule: + input: + output: 'host.txt' + shell: 'hostname > host.txt' diff --git a/files/Snakefile_hello b/files/Snakefile_hello new file mode 100644 index 0000000..0b94a00 --- /dev/null +++ b/files/Snakefile_hello @@ -0,0 +1,4 @@ +rule: + input: + output: 'hello.txt' + shell: 'echo "Hello there, world!" >> hello.txt' diff --git a/files/Snakefile_tworules b/files/Snakefile_tworules new file mode 100644 index 0000000..66558a6 --- /dev/null +++ b/files/Snakefile_tworules @@ -0,0 +1,9 @@ +rule last: + input: 'lower.txt' + output: 'upper.txt' + shell: 'cat lower.txt | tr a-z A-Z > upper.txt' + +rule first: + input: + output: 'lower.txt' + shell: 'echo "Hello, world!" > lower.txt'