Skip to content

Shed

Shed #15

Workflow file for this run

name: Shed
on:
schedule:
- cron: '0 0 1 * *' # Run monthly
jobs:
list:
runs-on: ubuntu-latest
outputs:
matrix: ${{ steps.set-matrix.outputs.matrix }}
steps:
- name: 'Checkout'
uses: actions/checkout@v3
- name: 'List repos'
id: set-matrix
run: echo "matrix=$(find tools -mindepth 1 -maxdepth 1 -type d | jq -R -s -c 'split("\n")[:-1] | map(split("/")[-1])')" >> "${GITHUB_OUTPUT}"
shed:
needs: list
runs-on: ubuntu-latest
continue-on-error: true
strategy:
max-parallel: 1
matrix:
repo: ${{ fromJson(needs.list.outputs.matrix) }}
steps:
- name: 'Checkout'
uses: actions/checkout@v3
- name: "Setup python"
uses: actions/setup-python@v4
with:
python-version: '3.10'
cache: 'pip' # caching pip dependencies
cache-dependency-path: |
env/requirements.txt
- name: 'Install packages'
run: |
pip install -r env/requirements.txt
- name: 'Test ToolShed'
run: |
planemo shed_update --force_repository_creation --shed_target testtoolshed --shed_key "${{ secrets.TESTTOOLSHED }}" "tools/${{ matrix.repo }}" || planemo shed_update --force_repository_creation --shed_target testtoolshed --shed_key "${{ secrets.TESTTOOLSHED }}" "tools/${{ matrix.repo }}"
- name: 'Main ToolShed'
run: |
planemo shed_update --force_repository_creation --shed_target toolshed --shed_key "${{ secrets.TOOLSHED }}" "tools/${{ matrix.repo }}" || planemo shed_update --force_repository_creation --shed_target toolshed --shed_key "${{ secrets.TOOLSHED }}" "tools/${{ matrix.repo }}"