This commit is contained in:
Gizzy
2024-12-20 12:52:53 +00:00
parent 5539ae2c63
commit 9947bfc3dc

View File

@@ -56,78 +56,78 @@ jobs:
name: checksums name: checksums
path: sha256sum.txt path: sha256sum.txt
build-windows: # build-windows:
name: Build bsky-desktop (Windows) # name: Build bsky-desktop (Windows)
runs-on: windows-latest # runs-on: windows-latest
env: # env:
ext: "exe" # ext: "exe"
GITHUB_TOKEN: ${{ secrets.GHT }} # GITHUB_TOKEN: ${{ secrets.GHT }}
steps: # steps:
- name: Checkout git repo # - name: Checkout git repo
uses: actions/checkout@v3 # uses: actions/checkout@v3
- name: Setup node and npm # - name: Setup node and npm
uses: actions/setup-node@v3 # uses: actions/setup-node@v3
with: # with:
node-version: 16 # node-version: 16
- name: Install dependencies # - name: Install dependencies
run: npm install # run: npm install
- name: Build (x64) # - name: Build (x64)
run: npm run build -- --arch x64 # run: npm run build -- --arch x64
- name: Build (arm64) # - name: Build (arm64)
run: npm run build -- --arch arm64 # run: npm run build -- --arch arm64
- name: Upload Windows Artifacts # - name: Upload Windows Artifacts
uses: actions/upload-artifact@v4 # uses: actions/upload-artifact@v4
id: upload-artifact # id: upload-artifact
with: # with:
name: windows-artifacts # name: windows-artifacts
path: | # path: |
dist/*.exe # dist/*.exe
dist/latest*.yml # dist/latest*.yml
build-macos: # build-macos:
name: Build bsky-desktop (macOS) # name: Build bsky-desktop (macOS)
runs-on: macos-latest # runs-on: macos-latest
env: # env:
ext: "dmg" # ext: "dmg"
GITHUB_TOKEN: ${{ secrets.GHT }} # GITHUB_TOKEN: ${{ secrets.GHT }}
steps: # steps:
- name: Checkout git repo # - name: Checkout git repo
uses: actions/checkout@v3 # uses: actions/checkout@v3
- name: Setup node and npm # - name: Setup node and npm
uses: actions/setup-node@v3 # uses: actions/setup-node@v3
with: # with:
node-version: 16 # node-version: 16
- name: Install dependencies # - name: Install dependencies
run: npm install # run: npm install
- name: Build (x64) # - name: Build (x64)
run: npm run build -- --arch x64 # run: npm run build -- --arch x64
- name: Build (arm64) # - name: Build (arm64)
run: npm run build -- --arch arm64 # run: npm run build -- --arch arm64
- name: Upload macOS Artifacts # - name: Upload macOS Artifacts
uses: actions/upload-artifact@v4 # uses: actions/upload-artifact@v4
id: upload-artifact # id: upload-artifact
with: # with:
name: macos-artifacts # name: macos-artifacts
path: | # path: |
dist/*.dmg # dist/*.dmg
dist/latest*.yml # dist/latest*.yml
release: release:
name: Create Release name: Create Release
runs-on: ubuntu-latest runs-on: ubuntu-latest
needs: [build-linux, build-windows, build-macos] needs: [build-linux]
outputs: outputs:
version_tag: ${{ steps.version.outputs.version }} version_tag: ${{ steps.version.outputs.version }}
env: env:
@@ -147,17 +147,17 @@ jobs:
name: linux-artifacts name: linux-artifacts
path: dist/linux path: dist/linux
- name: Download Windows Artifacts #- name: Download Windows Artifacts
uses: actions/download-artifact@v4 # uses: actions/download-artifact@v4
with: # with:
name: windows-artifacts # name: windows-artifacts
path: dist/windows # path: dist/windows
- name: Download macOS Artifacts #- name: Download macOS Artifacts
uses: actions/download-artifact@v4 # uses: actions/download-artifact@v4
with: # with:
name: macos-artifacts # name: macos-artifacts
path: dist/macos # path: dist/macos
- name: Display structure of downloaded files - name: Display structure of downloaded files
run: ls -R dist run: ls -R dist
@@ -176,9 +176,9 @@ jobs:
generate_release_notes: true generate_release_notes: true
files: | files: |
dist/linux/*.AppImage dist/linux/*.AppImage
dist/windows/*.exe # dist/windows/*.exe
dist/macos/*.dmg # dist/macos/*.dmg
dist/combined.yml # dist/combined.yml
aur: aur:
name: Publish to AUR name: Publish to AUR
@@ -205,7 +205,8 @@ jobs:
echo ${{ steps.version.outputs.version }} echo ${{ steps.version.outputs.version }}
new_checksum=$(awk 'NR==1 { print $1 }' ./sha256sum.txt) new_checksum=$(awk 'NR==1 { print $1 }' ./sha256sum.txt)
sed -i "s|sha256sums=('SKIP' 'SKIP')|sha256sums=('$new_checksum' 'SKIP')|" ./build/PKGBUILD sed -i "s|sha256sums=('SKIP' 'SKIP')|sha256sums=('$new_checksum' 'SKIP')|" ./build/PKGBUILD
sed -i "s/^pkgver=.*$/pkgver=${{ needs.release.outputs.version_tag }}/" ./build/PKGBUILD sed -i "s/^pkgver=.*$/pkgver=${{ steps.version.outputs.version }}/" ./build/PKGBUILD
cat ./build/PKGBUILD
# - name: Publish AUR package # - name: Publish AUR package
# if: false # if: false