-
Notifications
You must be signed in to change notification settings - Fork 4
75 lines (61 loc) · 1.76 KB
/
ci.yaml
File metadata and controls
75 lines (61 loc) · 1.76 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
name: CI
on:
workflow_dispatch:
concurrency:
group: ci-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: read
packages: read
statuses: write
jobs:
format:
name: Format workflow
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Checkout code
uses: actions/checkout@v5
with:
fetch-depth: 0
persist-credentials: false
- name: Format code base
uses: super-linter/super-linter@v8.5.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
VALIDATE_ALL_CODEBASE: true
DEFAULT_BRANCH: main
VALIDATE_SNAKEMAKE_SNAKEFMT: true
VALIDATE_PYTHON_BLACK: true
VALIDATE_YAML_PRETTIER: true
- name: Set up R
uses: r-lib/actions/setup-r@v2
- name: Set up R dependencies
uses: r-lib/actions/setup-r-dependencies@v2
with:
packages: styler
- name: Check R style
run: Rscript -e 'changed <- styler::style_dir(".", dry = "on"); if (any(changed$changed)) quit(status = 1)'
test:
name: Test example data
runs-on: ubuntu-latest
timeout-minutes: 45
steps:
- name: Checkout code
uses: actions/checkout@v5
with:
persist-credentials: false
- name: Restore test data and resources
run: bash test/setup_test_resources.sh
- name: Run workflow on example data
uses: snakemake/snakemake-github-action@v2
with:
directory: .
snakefile: workflow/Snakefile
snakemake-version: 8.25.3
args: >-
--cores all
--sdm conda
--conda-cleanup-pkgs cache
--show-failed-logs
show-disk-usage-on-error: true