-
-
Notifications
You must be signed in to change notification settings - Fork 307
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
49a28c3
commit 2c6be28
Showing
1 changed file
with
51 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,7 +11,7 @@ concurrency: | |
|
||
jobs: | ||
|
||
Release: | ||
ReleaseSourceArchive: | ||
if: startsWith(github.ref, 'refs/tags/') | ||
runs-on: ubuntu-latest | ||
steps: | ||
|
@@ -35,7 +35,25 @@ jobs: | |
${{ github.ref_name }}.tar.gz | ||
${{ github.ref_name }}.zip | ||
MacOS: | ||
LinuxBuilds: | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
fail-fast: false | ||
matrix: | ||
dockerfile: [arch.Dockerfile, fedora.Dockerfile, ubuntu.Dockerfile] | ||
|
||
steps: | ||
|
||
- name: Checkout source code | ||
uses: actions/checkout@v3 | ||
with: | ||
submodules: recursive | ||
|
||
- name: Build docker test image | ||
run: docker build . --file .docker/${{ matrix.dockerfile }} | ||
|
||
MacBuilds: | ||
name: ${{matrix.buildname}} | ||
runs-on: ${{matrix.os}} | ||
strategy: | ||
|
@@ -143,9 +161,6 @@ jobs: | |
mv "${dmg}" "${new_dmg}" | ||
mv "${dmg}.sha256" "${new_dmg}.sha256" | ||
- name: list files | ||
run: find build | ||
|
||
- name: Upload macOS bundle | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
|
@@ -155,8 +170,8 @@ jobs: | |
build/*.sha256 | ||
#appcast_item.txt | ||
Relase: | ||
needs: MacOS | ||
RelaseMacBuilds: | ||
needs: MacBuilds | ||
if: startsWith(github.ref, 'refs/tags/') | ||
runs-on: ubuntu-latest | ||
steps: | ||
|
@@ -165,18 +180,41 @@ jobs: | |
with: | ||
merge-multiple: true | ||
|
||
- name: list files | ||
run: find . | ||
|
||
- name: Upload | ||
uses: softprops/action-gh-release@v1 | ||
with: | ||
files: | | ||
build/Albert-*.dmg | ||
build/Albert-*.sha256 | ||
Albert-*.dmg | ||
Albert-*.sha256 | ||
UpdateTap: | ||
needs: RelaseMacBuilds | ||
if: startsWith(github.ref, 'refs/tags/') | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Get all build artifacts | ||
uses: actions/download-artifact@v4 | ||
with: | ||
merge-multiple: true | ||
|
||
- uses: actions/checkout@v4 | ||
with: | ||
repository: albertlauncher/homebrew-albert | ||
token: ${{ secrets.PAT }} | ||
|
||
- name: Update cask | ||
run: | | ||
sha_arm=$(cut -f 1 -d " " Albert-v0.26.8-arm64.dmg.sha256) | ||
sha_intel=$(cut -f 1 -d " " Albert-v0.26.8-x86_64.dmg.sha256) | ||
sed -i '.bak' "s/version .*$/version \"${{ github.ref_name }}\"/; s/^ sha256.*$/ sha256 arm: \"${sha_arm}\", intel: \"${sha_intel}\"/" albert.rb | ||
git config --local user.email "[email protected]" | ||
git config --local user.name "GitHub Action" | ||
git add albert.rb | ||
git commit -m "${{ github.ref_name }}" | ||
git push | ||
# Appcast: | ||
# needs: Relase | ||
# needs: RelaseMacBuilds | ||
# if: startsWith(github.ref, 'refs/tags/') | ||
# runs-on: ubuntu-latest | ||
# steps: | ||
|
@@ -200,20 +238,3 @@ jobs: | |
# git commit -m "Update appcast" | ||
# git push origin master | ||
|
||
Linux: | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
fail-fast: false | ||
matrix: | ||
dockerfile: [arch.Dockerfile, fedora.Dockerfile, ubuntu.Dockerfile] | ||
|
||
steps: | ||
|
||
- name: Checkout source code | ||
uses: actions/checkout@v3 | ||
with: | ||
submodules: recursive | ||
|
||
- name: Build docker test image | ||
run: docker build . --file .docker/${{ matrix.dockerfile }} |