Skip to content

Commit

Permalink
ci: call release workflow from main if a release is created
Browse files Browse the repository at this point in the history
  • Loading branch information
Mctalian committed Jan 5, 2025
1 parent ee5ac81 commit 12c016c
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 6 deletions.
7 changes: 1 addition & 6 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,11 +69,6 @@ jobs:
release:
needs: [run_tests, i18n_translations]
runs-on: ubuntu-latest
env:
CF_API_KEY: ${{ secrets.CF_API_KEY }}
WOWI_API_TOKEN: ${{ secrets.WOWI_API_TOKEN }}
WAGO_API_TOKEN: ${{ secrets.WAGO_API_TOKEN }}
GITHUB_OAUTH: ${{ secrets.GH_PAT }}
permissions:
contents: write
steps:
Expand Down Expand Up @@ -102,4 +97,4 @@ jobs:

- name: Package and release
if: env.RELEASE_CREATED == 'true'
uses: BigWigsMods/packager@v2
uses: ./.github/workflows/release.yml@main
31 changes: 31 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Package and release

on:
workflow_call:
workflow_dispatch:

permissions:
contents: write

jobs:
release:
runs-on: ubuntu-latest
env:
CF_API_KEY: ${{ secrets.CF_API_KEY }}
WOWI_API_TOKEN: ${{ secrets.WOWI_API_TOKEN }}
WAGO_API_TOKEN: ${{ secrets.WAGO_API_TOKEN }}
GITHUB_OAUTH: ${{ secrets.GH_PAT }}

steps:
- name: Clone project
uses: actions/checkout@v4
with:
fetch-depth: 0

- uses: awalsh128/cache-apt-pkgs-action@latest
with:
packages: subversion
version: test_package_apt_cache

- name: Package and release
uses: BigWigsMods/packager@v2

0 comments on commit 12c016c

Please sign in to comment.