Switch to ncipollo/release-action for generating our Nightly releases (#4125)
This commit is contained in:
@@ -6,8 +6,13 @@ if [ ! -f ./bin/chatterino ] || [ ! -x ./bin/chatterino ]; then
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
chatterino_version=$(git describe | cut -c 2-)
|
chatterino_version=$(git describe 2>/dev/null | cut -c 2-) || true
|
||||||
echo "Found Chatterino version $chatterino_version via git"
|
if [ -z "$chatterino_version" ]; then
|
||||||
|
chatterino_version="0.0.0-dev"
|
||||||
|
echo "Falling back to setting the version to '$chatterino_version'"
|
||||||
|
else
|
||||||
|
echo "Found Chatterino version $chatterino_version via git"
|
||||||
|
fi
|
||||||
|
|
||||||
rm -vrf "./package" || true # delete any old packaging dir
|
rm -vrf "./package" || true # delete any old packaging dir
|
||||||
|
|
||||||
@@ -32,4 +37,4 @@ DESTDIR="$packaging_dir" make INSTALL_ROOT="$packaging_dir" -j"$(nproc)" install
|
|||||||
echo ""
|
echo ""
|
||||||
|
|
||||||
echo "Building package..."
|
echo "Building package..."
|
||||||
dpkg-deb --build "$packaging_dir" "Chatterino.deb"
|
dpkg-deb --build "$packaging_dir" "Chatterino-x86_64.deb"
|
||||||
|
|||||||
+15
-64
@@ -183,7 +183,7 @@ jobs:
|
|||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: Chatterino-${{ matrix.qt-version }}.deb
|
name: Chatterino-${{ matrix.qt-version }}.deb
|
||||||
path: build/Chatterino.deb
|
path: build/Chatterino-x86_64.deb
|
||||||
|
|
||||||
# MACOS
|
# MACOS
|
||||||
- name: Install dependencies (MacOS)
|
- name: Install dependencies (MacOS)
|
||||||
@@ -229,83 +229,34 @@ jobs:
|
|||||||
if: (github.event_name == 'push' && github.ref == 'refs/heads/master')
|
if: (github.event_name == 'push' && github.ref == 'refs/heads/master')
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Create release
|
|
||||||
id: create_release
|
|
||||||
uses: pajlada/create-release@v2.0.4
|
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
with:
|
|
||||||
tag_name: nightly-build
|
|
||||||
backup_tag_name: backup-nightly-build
|
|
||||||
release_name: Nightly Release
|
|
||||||
body: |
|
|
||||||
Nightly Build
|
|
||||||
prerelease: true
|
|
||||||
|
|
||||||
- uses: actions/download-artifact@v3
|
- uses: actions/download-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: chatterino-windows-x86-64-5.15.2.zip
|
name: chatterino-windows-x86-64-5.15.2.zip
|
||||||
path: windows/
|
path: release-artifacts/
|
||||||
|
|
||||||
- uses: actions/download-artifact@v3
|
- uses: actions/download-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: Chatterino-x86_64-5.15.2.AppImage
|
name: Chatterino-x86_64-5.15.2.AppImage
|
||||||
path: linux/
|
path: release-artifacts/
|
||||||
|
|
||||||
- uses: actions/download-artifact@v3
|
- uses: actions/download-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: Chatterino-5.15.2.deb
|
name: Chatterino-5.15.2.deb
|
||||||
path: ubuntu/
|
path: release-artifacts/
|
||||||
|
|
||||||
- uses: actions/download-artifact@v3
|
- uses: actions/download-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: chatterino-osx-5.15.2.dmg
|
name: chatterino-osx-5.15.2.dmg
|
||||||
path: macos/
|
path: release-artifacts/
|
||||||
|
|
||||||
# TODO: Extract dmg and appimage
|
- name: Create release
|
||||||
|
uses: ncipollo/release-action@v1.11.1
|
||||||
# - name: Read upload URL into output
|
|
||||||
# id: upload_url
|
|
||||||
# run: |
|
|
||||||
# echo "::set-output name=upload_url::$(cat release-upload-url.txt/release-upload-url.txt)"
|
|
||||||
|
|
||||||
- name: Upload release asset (Windows)
|
|
||||||
uses: actions/upload-release-asset@v1.0.2
|
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
with:
|
with:
|
||||||
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
removeArtifacts: true
|
||||||
asset_path: ./windows/chatterino-windows-x86-64.zip
|
allowUpdates: true
|
||||||
asset_name: chatterino-windows-x86-64.zip
|
artifactErrorsFailBuild: true
|
||||||
asset_content_type: application/zip
|
artifacts: "release-artifacts/*"
|
||||||
|
generateReleaseNotes: true
|
||||||
- name: Upload release asset (Ubuntu)
|
prerelease: true
|
||||||
uses: actions/upload-release-asset@v1.0.2
|
name: Nightly Release
|
||||||
env:
|
tag: nightly-build
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
with:
|
|
||||||
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
|
||||||
asset_path: ./linux/Chatterino-x86_64.AppImage
|
|
||||||
asset_name: Chatterino-x86_64.AppImage
|
|
||||||
asset_content_type: application/x-executable
|
|
||||||
|
|
||||||
- name: Upload release asset (Ubuntu .deb)
|
|
||||||
uses: actions/upload-release-asset@v1.0.2
|
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
with:
|
|
||||||
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
|
||||||
asset_path: ./ubuntu/Chatterino.deb
|
|
||||||
asset_name: Chatterino-x86_64.deb
|
|
||||||
asset_content_type: application/vnd.debian.binary-package
|
|
||||||
|
|
||||||
- name: Upload release asset (MacOS)
|
|
||||||
uses: actions/upload-release-asset@v1.0.2
|
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
with:
|
|
||||||
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
|
||||||
asset_path: ./macos/chatterino-osx.dmg
|
|
||||||
asset_name: chatterino-osx.dmg
|
|
||||||
asset_content_type: application/x-bzip2
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user