Skip to content

Commit

Permalink
bump workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
bernt-matthias committed Aug 7, 2023
1 parent 0c52223 commit 8dc9381
Show file tree
Hide file tree
Showing 3 changed files with 69 additions and 5 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
types: [run-all-tool-tests-command]
env:
GALAXY_FORK: galaxyproject
GALAXY_BRANCH: release_22.05
GALAXY_BRANCH: release_23.1
MAX_CHUNKS: 40
jobs:
setup:
Expand Down Expand Up @@ -112,6 +112,8 @@ jobs:
- name: Get number of CPU cores
uses: SimenB/github-actions-cpu-cores@v1
id: cpu-cores
- name: Clean dotnet folder for space
run: rm -Rf /usr/share/dotnet
# TODO this is only temporary and only for OpenMS
- name: create test data
run: |
Expand Down
53 changes: 49 additions & 4 deletions .github/workflows/pr.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,23 @@
name: Galaxy Tool Linting and Tests for push and PR
on: [push, pull_request]
on:
pull_request:
paths-ignore:
- '.github/**'
- 'deprecated/**'
- 'docs/**'
- '*'
push:
branches:
- main
- master
paths-ignore:
- '.github/**'
- 'deprecated/**'
- 'docs/**'
- '*'
env:
GALAXY_FORK: galaxyproject
GALAXY_BRANCH: release_22.05
GALAXY_BRANCH: release_23.1
MAX_CHUNKS: 4
MAX_FILE_SIZE: 2M
concurrency:
Expand Down Expand Up @@ -189,7 +204,7 @@ jobs:
- name: lintr
run: |
library(lintr)
linters <- linters_with_defaults(line_length_linter = NULL, cyclocomp_linter = NULL, object_usage_linter = NULL)
linters <- linters_with_defaults(line_length_linter = NULL, cyclocomp_linter = NULL, object_usage_linter = NULL, object_name_linter = NULL)
con <- file("repository_list.txt", "r")
status <- 0
while (TRUE) {
Expand Down Expand Up @@ -299,6 +314,8 @@ jobs:
- name: Get number of CPU cores
uses: SimenB/github-actions-cpu-cores@v1
id: cpu-cores
- name: Clean dotnet folder for space
run: rm -Rf /usr/share/dotnet
- name: Planemo test
uses: galaxyproject/planemo-ci-action@v1
id: test
Expand All @@ -325,7 +342,7 @@ jobs:
combine_outputs:
name: Combine chunked test results
needs: [setup, test]
if: ${{ needs.setup.outputs.repository-list != '' }}
if: ${{ always() && needs.setup.outputs.repository-list != '' }}
runs-on: ubuntu-latest
strategy:
matrix:
Expand Down Expand Up @@ -358,6 +375,12 @@ jobs:
id: check
with:
mode: check
- name: Check if all test chunks succeeded
run: |
NFILES=$(ls artifacts/ | grep "Tool test output" | wc -l)
if [[ "${{ needs.setup.outputs.chunk-count }}" != "$NFILES" ]]; then
exit 1
fi
# deploy the tools to the toolsheds (first TTS for testing)
deploy:
Expand Down Expand Up @@ -397,6 +420,28 @@ jobs:
shed-target: toolshed
shed-key: ${{ secrets.TS_API_KEY }}

deploy-report:
name: Report deploy status
needs: [deploy]
if: ${{ always() && needs.deploy.result != 'success' && (github.ref == 'refs/heads/master' || github.ref == 'refs/heads/main' ) && github.repository_owner == 'galaxyproject' }}
runs-on: ubuntu-latest
steps:
# report to the PR if deployment failed
- name: Get PR object
uses: 8BitJonny/gh-get-current-pr@2.2.0
id: getpr
with:
sha: ${{ github.event.after }}
- name: Create comment
uses: peter-evans/create-or-update-comment@v2
with:
token: ${{ secrets.PAT }}
issue-number: ${{ steps.getpr.outputs.number }}
body: |
Attention: deployment ${{ needs.deploy.result }}!
https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}
determine-success:
name: Check workflow success
needs: [setup, lint, flake8, lintr, file_sizes, combine_outputs]
Expand Down
17 changes: 17 additions & 0 deletions .github/workflows/pr_without_tool_change.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: Galaxy Tool Linting and Tests for push and PR
# Fallback workflow that provides a succeeding "Check workflow success" job
# as this is a requirement for being able to merge a PR
# see https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/defining-the-mergeability-of-pull-requests/troubleshooting-required-status-checks#handling-skipped-but-required-checks
on:
pull_request:
concurrency:
# Group runs by PR, but keep runs on the default branch separate
# because we do not want to cancel ToolShed uploads
group: pr-${{ (github.ref == 'refs/heads/master' || github.ref == 'refs/heads/main') && github.run_number || github.ref }}
cancel-in-progress: true
jobs:
determine-success:
name: Check workflow success
runs-on: ubuntu-latest
steps:
- run: 'echo "No tool tests required for this PR"'

0 comments on commit 8dc9381

Please sign in to comment.