Add github action that packages a release tarball (#148)

Change-Id: I368a834a27f69550596a041c1e6b84afd40011b7
This commit is contained in:
csett86
2021-08-19 12:12:27 +02:00
committed by Manuel Stahl
parent e6f01f035b
commit 865fc98336
2 changed files with 42 additions and 4 deletions

28
.github/workflows/github-release.yml vendored Normal file
View File

@@ -0,0 +1,28 @@
name: Create release tarball and attach to tag
on:
push:
tags:
- "*"
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: "14"
- run: yarn install
- run: yarn build
- run: |
version=`git describe --dirty --tags || echo unknown`
mkdir -p dist
cp -r build synapse-admin-$version
tar chvzf dist/synapse-admin-$version.tar.gz synapse-admin-$version
- uses: softprops/action-gh-release@b7e450da2a4b4cb4bfbae528f788167786cfcedf
with:
files: dist/*.tar.gz
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}