mirror of
https://forgejo.merr.is/annika/actions-docker-extract.git
synced 2025-12-12 12:45:45 -05:00
ci: Package action automatically on release branch (#15)
This commit is contained in:
parent
abde1147dd
commit
917745b929
9 changed files with 161 additions and 1623 deletions
35
.github/workflows/package-action.yaml
vendored
Normal file
35
.github/workflows/package-action.yaml
vendored
Normal file
|
|
@ -0,0 +1,35 @@
|
|||
name: "Package Action"
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- "main"
|
||||
|
||||
env:
|
||||
source: "main"
|
||||
release: "release"
|
||||
|
||||
jobs:
|
||||
package-changes:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
with:
|
||||
ref: "${{ env.release }}"
|
||||
fetch-depth: 0
|
||||
ssh-key: "${{ secrets.COMMIT_KEY }}"
|
||||
- uses: pr-mpt/actions-merge-branch@v2
|
||||
with:
|
||||
from: "origin/${{ env.source }}"
|
||||
commit: false
|
||||
- name: Install Javascript dependencies with npm
|
||||
run: npm install
|
||||
- name: Package action for distribution
|
||||
run: npm run package
|
||||
- name: Push packaged action to branch
|
||||
uses: EndBug/add-and-commit@v7
|
||||
with:
|
||||
add: "['.', 'dist --force']"
|
||||
branch: "${{ env.release }}"
|
||||
default_author: github_actions
|
||||
message: "build: Package action as `dist` with latest changes"
|
||||
Loading…
Add table
Add a link
Reference in a new issue