Skip to content

.github/workflows/test.yml #113

.github/workflows/test.yml

.github/workflows/test.yml #113

Workflow file for this run

name: Test
on:
workflow_dispatch:
push:
branches:
- main
- dev
pull_request:
branches:
- "**"
jobs:
skip_duplicate:
permissions:
actions: write
contents: read
runs-on: ubuntu-latest
outputs:
should_skip: ${{ steps.skip_check.outputs.should_skip }}
steps:
- id: skip_check
uses: fkirc/skip-duplicate-actions@v5.3.0
with:
cancel_others: 'true'
concurrent_skipping: 'same_content_newer'
paths_ignore: '["**/README.md", "CITATION.cff"]'
run_test_pipeline:
needs: skip_duplicate
if: ${{ needs.skip_duplicate.outputs.should_skip != 'true' }}
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Setup environment
uses: conda-incubator/setup-miniconda@v3
with:
channel-priority: strict
activate-environment: snakemake
auto-activate-base: false
environment-file: .test/environment_7.32.4.yaml
- name: Run test pipeline
shell: bash -el {0}
run: snakemake --snakefile workflow/Snakefile --directory .test --configfile config/config.yaml .test/targets.yaml --use-conda -c1 --conda-frontend conda
- name: Pack logs
if: success() || failure()
shell: bash -el {0}
run: tar czf logs.tar.gz .test/output/logs .test/.snakemake/log
- name: Upload output file
if: success() || failure()
uses: actions/upload-artifact@v4
with:
name: output-logs
path: logs.tar.gz