From edd345401f63e6097eaa0c44285e0e5dd6ec99f6 Mon Sep 17 00:00:00 2001 From: Anton Agestam Date: Wed, 4 Dec 2024 17:16:22 +0100 Subject: [PATCH] Revert "feature: Introduce upgrade workflow (#95)" (#97) This reverts commit 3a3b722c4f63bb9dc54adab77662df6318b4ebfc. Github does not fully support creating PRs from workflows, as those PRs will not in turn run workflows required for verifying them. --- .github/workflows/bump.yaml | 14 -------- .github/workflows/upgrade.yaml | 58 ---------------------------------- goose.yaml | 2 +- 3 files changed, 1 insertion(+), 73 deletions(-) delete mode 100644 .github/workflows/bump.yaml delete mode 100644 .github/workflows/upgrade.yaml diff --git a/.github/workflows/bump.yaml b/.github/workflows/bump.yaml deleted file mode 100644 index 6a4ae17..0000000 --- a/.github/workflows/bump.yaml +++ /dev/null @@ -1,14 +0,0 @@ -name: Bump -on: - workflow_dispatch: {} - schedule: - # Trigger first of every month. - - cron: "30 12 1 * *" - -jobs: - goose-bump: - name: Bump goose dependencies - uses: "./.github/workflows/upgrade.yaml" - permissions: - contents: write - pull-requests: write diff --git a/.github/workflows/upgrade.yaml b/.github/workflows/upgrade.yaml deleted file mode 100644 index bd9462b..0000000 --- a/.github/workflows/upgrade.yaml +++ /dev/null @@ -1,58 +0,0 @@ -# This is a reusable workflow that's meant to be the canonical way of upgrading goose -# dependencies in Github Actions workflows. See README for an example of how to use this -# in your workflows. -# -# This workflow requires allowing GitHub Actions to create and approve pull requests -# in your repository's Actions settings. - -on: - workflow_call: {} - -env: - PYTHON_VERSION: "3.13" - COLUMNS: "120" - FORCE_COLOR: "1" - PYTHONUNBUFFERED: "1" - -jobs: - goose-upgrade: - name: Upgrade goose dependencies - runs-on: ubuntu-latest - permissions: - contents: write - pull-requests: write - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-python@v5 - with: - python-version: 3.13 - cache: pip - check-latest: true - - name: Set up git branch and config - run: | - git config --global user.name "${{ github.actor }}" - git config --global user.email "${{ github.actor }}@users.noreply.github.com" - git checkout -b "${{ github.actor }}/chore/bump-goose-deps" - - name: goose cache - uses: actions/cache@v4 - with: - path: ~/.cache/goose - key: "${{ runner.os }}-goose-${{ env.PYTHON_VERSION }}-${{ hashFiles('.goose/**/manifest.json') }}" - restore-keys: | - ${{ runner.os }}-goose-${{ env.PYTHON_VERSION }} - ${{ runner.os }}-goose - - run: pip install --upgrade git-goose - - run: goose upgrade - - run: git add .goose - - run: >- - git commit --message='chore: Bump goose dependencies' - - run: git show HEAD - - run: git push origin "${{ github.actor }}/chore/bump-goose-deps" --force - - name: Create pull request - run: >- - gh pr create - --base=${{ github.base_ref || github.ref_name }} - --head=${{ github.actor }}/chore/bump-goose-deps - --fill - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/goose.yaml b/goose.yaml index 7e7df3b..152cf52 100644 --- a/goose.yaml +++ b/goose.yaml @@ -109,7 +109,7 @@ hooks: environment: python command: check-jsonschema read_only: true - args: ["--builtin-schema", "vendor.github-workflows", "--verbose"] + args: ["--builtin-schema", "vendor.github-workflows"] types: [yaml] limit: - "^.github/workflows/"