-
Notifications
You must be signed in to change notification settings - Fork 134
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: beta version add discord notification (#1605)
Co-authored-by: Hien To <[email protected]>
- Loading branch information
1 parent
f5fbad6
commit f37ad6b
Showing
2 changed files
with
42 additions
and
43 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 |
---|---|---|
|
@@ -35,6 +35,7 @@ jobs: | |
name: "${{ env.VERSION }}" | ||
draft: true | ||
prerelease: false | ||
generate_release_notes: true | ||
|
||
build-macos: | ||
uses: ./.github/workflows/template-build-macos.yml | ||
|
@@ -79,26 +80,47 @@ jobs: | |
upload_url: ${{ needs.create-draft-release.outputs.upload_url }} | ||
cortex-llamacpp-version: ${{ needs.get-cortex-llamacpp-latest-version.outputs.cortex_llamacpp_latest_version }} | ||
|
||
update_release_draft: | ||
needs: [build-macos, build-windows-x64, build-linux-x64] | ||
update_release: | ||
needs: [get-update-version, create-draft-release, build-macos, build-windows-x64, build-linux-x64] | ||
permissions: | ||
# write permission is required to create a github release | ||
contents: write | ||
# write permission is required for autolabeler | ||
# otherwise, read permission is required at least | ||
pull-requests: write | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: set release to prerelease | ||
run: | | ||
gh release edit v${{ needs.get-update-version.outputs.new_version }} --draft=false --prerelease | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
noti-discord: | ||
needs: [get-update-version, create-draft-release, build-macos, build-windows-x64, build-linux-x64, update_release] | ||
runs-on: ubuntu-latest | ||
permissions: | ||
# write permission is required to create a github release | ||
contents: write | ||
# write permission is required for autolabeler | ||
# otherwise, read permission is required at least | ||
pull-requests: write | ||
runs-on: ubuntu-latest | ||
steps: | ||
# (Optional) GitHub Enterprise requires GHE_HOST variable set | ||
#- name: Set GHE_HOST | ||
# run: | | ||
# echo "GHE_HOST=${GITHUB_SERVER_URL##https:\/\/}" >> $GITHUB_ENV | ||
- name: Set version to environment variable | ||
run: | | ||
echo "VERSION=${{ needs.get-update-version.outputs.new_version }}" >> $GITHUB_ENV | ||
echo "RUNNER_ID=$GITHUB_RUN_ID" >> $GITHUB_ENV | ||
# Drafts your next Release notes as Pull Requests are merged into "master" | ||
- uses: release-drafter/release-drafter@v5 | ||
# (Optional) specify config name to use, relative to .github/. Default: release-drafter.yml | ||
# with: | ||
# config-name: my-config.yml | ||
# disable-autolabeler: true | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
- name: Notify Discord | ||
uses: appleboy/[email protected] | ||
with: | ||
webhook_id: ${{ secrets.WEBHOOK_ID_BETA }} | ||
webhook_token: ${{ secrets.WEBHOOK_TOKEN_BETA }} | ||
message: | | ||
Cortex.cpp beta build artifact version ${{ env.VERSION }}: | ||
- Windows: | ||
- Network Installer: https://github.com/janhq/cortex.cpp/releases/download/v${{ env.VERSION }}/cortex-${{ env.VERSION }}-windows-amd64-network-installer.exe | ||
- Local Installer: https://github.com/janhq/cortex.cpp/releases/download/v${{ env.VERSION }}/cortex-${{ env.VERSION }}-windows-amd64-local-installer.exe | ||
- macOS Universal: | ||
- Network Installer: https://github.com/janhq/cortex.cpp/releases/download/v${{ env.VERSION }}/cortex-${{ env.VERSION }}-mac-universal-network-installer.pkg | ||
- Local Installer: https://github.com/janhq/cortex.cpp/releases/download/v${{ env.VERSION }}/cortex-${{ env.VERSION }}-mac-universal-local-installer.pkg | ||
- Linux Deb: | ||
- Network Installer: https://github.com/janhq/cortex.cpp/releases/download/v${{ env.VERSION }}/cortex-${{ env.VERSION }}-linux-amd64-network-installer.deb | ||
- Local Installer: https://github.com/janhq/cortex.cpp/releases/download/v${{ env.VERSION }}/cortex-${{ env.VERSION }}-linux-amd64-local-installer.deb | ||
- Github Release: https://github.com/janhq/cortex.cpp/releases/tag/v${{ env.VERSION }} |
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