Skip to content

convert to use umi_count #1122

convert to use umi_count

convert to use umi_count #1122

name: Test Singularity Build
on:
# push:
# branches:
# - master
# Do the builds on all pull requests (to test them)
pull_request:
branches:
- "*"
jobs:
changes:
name: Checking changed files
runs-on: ubuntu-latest
outputs:
keepgoing: ${{ steps.changed-files.outputs.any_changed }}
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v41
with:
files: |
**/*.{yml,yaml,py}
requirements.txt
container/database
container/tests
container/scripts/*.{sh,py}
container/*.{yml,yaml,py,def}
tests
- name: List all changed files
run: |
for file in ${{ steps.changed-files.outputs.all_changed_files }}; do
echo "$file was changed"
done
echo ${{ steps.changed-files.outputs.any_changed }}
container:
needs:
- changes
if: needs.changes.outputs.keepgoing == 'true'
runs-on: ubuntu-latest
steps:
- name: Check out code for the container build
uses: actions/checkout@v3
- name: Setup Singularity
uses: singularityhub/install-singularity@main
- name: Extract repository location
shell: bash
run: |
echo "location=$(echo " - git+https://www.github.com/${GITHUB_REPOSITORY}@${GITHUB_REF#refs/heads/}")" >> $GITHUB_OUTPUT
id: extract_location
- name: Build Container
run: |
cd container
echo '${{ steps.extract_location.outputs.location }}' >> environment_test.yml
sudo -E singularity build --notest sc-dandelion.sif sc-dandelion_test.def
- name: Test Container
run: |
cd container
sudo singularity test --writable-tmpfs sc-dandelion.sif
singularity run -B $PWD sc-dandelion.sif dandelion-preprocess --help