Skip to content

Add Galaxy Tool CI/CD pipeline configuration #1

Add Galaxy Tool CI/CD pipeline configuration

Add Galaxy Tool CI/CD pipeline configuration #1

name: Galaxy Tool CI/CD Pipeline

Check failure on line 1 in .github/workflows/galaxy-tool-ci.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/galaxy-tool-ci.yml

Invalid workflow file

`tag` is not a valid event name
on:
push:
branches: [ main, master ]
pull_request:
branches: [ main, master ]
release:
types: [ published ]
tag:
types: [ created ]
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.9'
- name: Create Planemo config
env:
USER: ${{ secrets.USER }}
KEY: ${{ secrets.KEY }}
EMAIL: ${{ secrets.EMAIL }}
PASS: ${{ secrets.PASS }}
run: |
mkdir -p $HOME/.planemo
cat > $HOME/.planemo.yml << EOF
shed_username: $USER # your ToolShed username
sheds:
toolshed:
key: $KEY # your ToolShed API key, under 'User > API Keys'
email: $EMAIL # your ToolShed email
password: $PASS # your ToolShed password
EOF
- name: Install Planemo
run: pip install planemo
- name: Lint Galaxy tool
run: planemo lint structural_validator.xml
- name: Test Galaxy tool
run: planemo test structural_validator.xml
deploy:
needs: test
if: startsWith(github.ref, 'refs/tags/v')
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.9'
- name: Create Planemo config
env:
USER: ${{ secrets.USER }}
KEY: ${{ secrets.KEY }}
EMAIL: ${{ secrets.EMAIL }}
PASS: ${{ secrets.PASS }}
run: |
mkdir -p $HOME/.planemo
cat > $HOME/.planemo.yml << EOF
shed_username: $USER # your ToolShed username
sheds:
toolshed:
key: $KEY # your ToolShed API key, under 'User > API Keys'
email: $EMAIL # your ToolShed email
password: $PASS # your ToolShed password
EOF
- name: Install Planemo
run: pip install planemo
- name: Update Tool Shed
run: planemo shed_update --shed_target toolshed