From afc31b8de1b56a6c4dc864842a27c2347dc68adf Mon Sep 17 00:00:00 2001 From: Steven Murray Date: Wed, 24 Jul 2024 16:28:31 +0200 Subject: [PATCH] ci: better release --- .github/workflows/merge-me.yaml | 27 --------------------------- .github/workflows/merge-to-dev.yaml | 22 ---------------------- .github/workflows/tag-release.yaml | 17 ----------------- .github/workflows/test_suite.yaml | 5 +---- .github/workflows/warnings-tests.yaml | 8 ++------ 5 files changed, 3 insertions(+), 76 deletions(-) delete mode 100644 .github/workflows/merge-me.yaml delete mode 100644 .github/workflows/merge-to-dev.yaml delete mode 100644 .github/workflows/tag-release.yaml diff --git a/.github/workflows/merge-me.yaml b/.github/workflows/merge-me.yaml deleted file mode 100644 index 99a9f415..00000000 --- a/.github/workflows/merge-me.yaml +++ /dev/null @@ -1,27 +0,0 @@ -name: Merge me! - -on: - pull_request: - types: - - edited - - labeled - - ready_for_review - - reopened - - synchronize - - unlabeled - - unlocked - -jobs: - merge-me: - name: Merge me! - runs-on: ubuntu-latest - if: contains(github.event.pull_request.labels.*.name, 'auto-pr') - steps: - - name: Merge me! - uses: ridedott/merge-me-action@v1 - with: - # This must be used as GitHub Actions token does not support - # pushing to protected branches. - GITHUB_TOKEN: ${{ secrets.BUMP_VERSION }} - GITHUB_LOGIN: steven-murray - MERGE_METHOD: REBASE diff --git a/.github/workflows/merge-to-dev.yaml b/.github/workflows/merge-to-dev.yaml deleted file mode 100644 index 37369b5f..00000000 --- a/.github/workflows/merge-to-dev.yaml +++ /dev/null @@ -1,22 +0,0 @@ -name: Merge to dev - -on: - push: - tags: - - '*' - -jobs: - pull-request: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: pull-request - uses: repo-sync/pull-request@v2 - with: - source_branch: "master" - destination_branch: "dev" - pr_title: "Pulling master into dev" # Title of pull request - pr_body: ":crown: *An automated PR*" # Full markdown support, requires pr_title to be set - pr_assignee: "steven-murray" # Comma-separated list (no spaces) - pr_label: "auto-pr" # Comma-separated list (no spaces) - github_token: ${{ secrets.BUMP_VERSION }} diff --git a/.github/workflows/tag-release.yaml b/.github/workflows/tag-release.yaml deleted file mode 100644 index cb77a7f5..00000000 --- a/.github/workflows/tag-release.yaml +++ /dev/null @@ -1,17 +0,0 @@ -name: Tag-Release - -on: - push: - branches: [master] - -jobs: - tag-release: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - run: echo "version=$(cat VERSION)" >> $GITHUB_ENV - - name: Tag commit - uses: tvdias/github-tagger@v0.0.2 - with: - repo-token: "${{ secrets.BUMP_VERSION }}" - tag: "${{ env.version }}" diff --git a/.github/workflows/test_suite.yaml b/.github/workflows/test_suite.yaml index 3ec48a73..6d290ce7 100644 --- a/.github/workflows/test_suite.yaml +++ b/.github/workflows/test_suite.yaml @@ -5,12 +5,9 @@ name: Tests # Also, only test on pull requests into master/dev. on: push: - tags-ignore: - - 'v*' pull_request: branches: - - 'master' - - 'dev' + - 'main' jobs: tests: diff --git a/.github/workflows/warnings-tests.yaml b/.github/workflows/warnings-tests.yaml index cb4acbfa..3dbd0e7e 100644 --- a/.github/workflows/warnings-tests.yaml +++ b/.github/workflows/warnings-tests.yaml @@ -5,16 +5,12 @@ name: Warnings Tests # Also, only test on pull requests into master/dev. on: push: - tags-ignore: - - 'v*' pull_request: branches: - - 'master' - - 'dev' + - 'main' jobs: tests: - if: "!contains(github.event.pull_request.labels.*.name, 'auto-pr')" env: ENV_NAME: tests PYTHON: ${{ matrix.python-version }} @@ -45,7 +41,7 @@ jobs: run: | python -m pytest -Werror --cov=hmf --cov-config=.coveragerc --cov-report xml:./coverage.xml --durations=25 - uses: codecov/codecov-action@v3 - if: matrix.os == 'ubuntu-latest' && success() && !contains(github.event.pull_request.labels.*.name, 'auto-pr') + if: matrix.os == 'ubuntu-latest' && success() with: file: ./coverage.xml # optional fail_ci_if_error: true