mirror of
https://github.com/wimpysworld/stream-sprout
synced 2026-03-14 14:45:50 +01:00
ci: fix release workflow
This commit is contained in:
parent
040d5f7ba9
commit
15d407226d
1 changed files with 5 additions and 8 deletions
15
.github/workflows/publish-release.yml
vendored
15
.github/workflows/publish-release.yml
vendored
|
|
@ -25,7 +25,7 @@ jobs:
|
|||
run: |
|
||||
APP_VERSION=$(grep "^readonly VERSION" stream-sprout | cut -d'"' -f2)
|
||||
GIT_VERSION=$(git describe --tags | cut -d'-' -f1)
|
||||
echo "App version: ${REL_VERSION}"
|
||||
echo "App version: ${APP_VERSION}"
|
||||
echo "Git version: ${GIT_VERSION}"
|
||||
if [ "${APP_VERSION}" != "${GIT_VERSION}" ]; then
|
||||
echo "ERROR! Version mismatch.";
|
||||
|
|
@ -39,8 +39,6 @@ jobs:
|
|||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: "Build .deb 🍥"
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
run: |
|
||||
sudo apt-get -y update
|
||||
sudo apt-get -y install debhelper devscripts
|
||||
|
|
@ -48,14 +46,13 @@ jobs:
|
|||
rm debian/changelog
|
||||
dch --package stream-sprout --newversion="${REL_VER}-1" --distribution=unstable "New upstream release." --create
|
||||
dpkg-buildpackage --build=binary --no-check-builddeps --compression=gzip
|
||||
- name: "Draft Release 📥️"
|
||||
run: |
|
||||
gh release create "${{ github.ref }}" --draft --generate-notes
|
||||
- name: "Upload .deb ⤴️"
|
||||
run: |
|
||||
gh release upload "${{ github.ref }}" "../stream-sprout_${REL_VER}-1_all.deb" --clobber
|
||||
- name: "Publish release 📤️"
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
run: |
|
||||
REL_VER=$(grep "^readonly VERSION" stream-sprout | cut -d'"' -f2)
|
||||
gh release create "${{ github.ref }}" --draft --generate-notes
|
||||
gh release upload "${{ github.ref }}" "../stream-sprout_${REL_VER}-1_all.deb" --clobber
|
||||
if [ "$(gh release view "${{ github.ref }}" --json assets --template '{{len .assets}}')" -lt 0 ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue