Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# SCM syntax highlighting & preventing 3-way merges
pixi.lock merge=binary linguist-language=YAML linguist-generated=true -diff
14 changes: 3 additions & 11 deletions .github/workflows/deploy-apptainer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,27 +11,19 @@ jobs:
packages: write
steps:
- name: checkout repo
uses: actions/checkout@v4
uses: actions/checkout@v6
Comment thread
m-jahn marked this conversation as resolved.
with:
fetch-depth: 0

- name: create dockerfile
- name: create apptainer recipe
uses: snakemake/snakemake-github-action@v2
with:
directory: .
snakefile: workflow/Snakefile
install-apptainer: true
args: "--cores 1"
task: containerize

- name: create apptainer recipe
shell: bash
run: |
pip install spython
sed -i "2i RUN apt-get update && apt-get install -y curl" Dockerfile
spython recipe Dockerfile > apptainer.def
sed -i 's/\/environment.yaml\/environment.yaml$/\/environment.yaml/' apptainer.def
sed -i 's/^curl /curl -L /' apptainer.def
containerize-args: apptainer

- name: create apptainer image
shell: bash
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/snakemake-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
Formatting:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Formatting
Expand All @@ -33,7 +33,7 @@ jobs:
Linting:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v6
- name: Lint workflow
uses: snakemake/snakemake-github-action@v2
with:
Expand All @@ -47,7 +47,7 @@ jobs:
- Linting
- Formatting
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v6

- name: Test workflow
uses: snakemake/snakemake-github-action@v2
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/yaml-formatting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
Formatting:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Formatting
Expand Down
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# workspace
.snakemake
.test/result.*
.test/apptainer.*

# pixi environments
.pixi/*
!.pixi/config.toml
26 changes: 26 additions & 0 deletions .test/Snakefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
rule all:
input:
"result.txt",
"result.html",


rule test:
output:
"result.txt",
conda:
"test_env.yaml"
shell:
"echo 'This is just a test.' > {output}"


rule test_wrapper:
input:
sample=["input.fastq"],
output:
html="result.html",
json="result.json",
log:
"result.log",
threads: 1
wrapper:
"v9.5.0/bio/fastp"
40 changes: 40 additions & 0 deletions .test/input.fastq
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
@read1
ACGTACGTACGTACGTACGTACGTACGTACGTACGTACGTACGTACGA
+
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII
@read2
TGCATGCATGCATGCATGCATGCATGCATGCATGCATGCATGCATGCG
+
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII
@read3
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
+
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII
@read4
TTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTT
+
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII
@read5
GCGCGCGCGCGCGCGCGCGCGCGCGCGCGCGCGCGCGCGCGCGCGCGC
+
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII
@read6
ATATATATATATATATATATATATATATATATATATATATATATATAT
+
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII
@read7
ACACACACACACACACACACACACACACACACACACACACACACACAC
+
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII
@read8
GTGTGTGTGTGTGTGTGTGTGTGTGTGTGTGTGTGTGTGTGTGTGTGT
+
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII
@read9
AGAGAGAGAGAGAGAGAGAGAGAGAGAGAGAGAGAGAGAGAGAGAGAG
+
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII
@read10
CTCTCTCTCTCTCTCTCTCTCTCTCTCTCTCTCTCTCTCTCTCTCTCT
+
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII
6 changes: 6 additions & 0 deletions .test/test_env.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
name: test_env
channels:
- conda-forge
- bioconda
dependencies:
- pyyaml=6.0.3
1,891 changes: 1,891 additions & 0 deletions pixi.lock

Large diffs are not rendered by default.

16 changes: 16 additions & 0 deletions pixi.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
[workspace]
authors = ["m-jahn <jahn@mpusp.mpg.de>"]
channels = ["conda-forge", "bioconda"]
name = "mpusp-github-actions"
platforms = ["linux-64"]
version = "0.1.0"

[tasks]
test-workflow = { cmd = "snakemake -d .test -s .test/Snakefile -c 1 --sdm conda" }
test-containerize = { cmd = "snakemake -d .test -s .test/Snakefile -c 1 --show-failed-logs --containerize apptainer > .test/apptainer.def" }
test-uidmap = { cmd = "dpkg -l uidmap 2>/dev/null" }
test-apptainer = { cmd = "cd .test; apptainer build --fakeroot apptainer.sif apptainer.def" }

[dependencies]
snakemake = ">=9.19.0,<10"
apptainer = ">=1.4.5,<2"