-
Notifications
You must be signed in to change notification settings - Fork 46
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: native binaries installation docs and cd refinements (#442)
* docs: updating installation docs * docs: update docs * docs: update docs * docs: update docs - PR reviewa * docs: update docs on supported architectures * docs: tweak wording * refactor: removing choco; updating snapshots and doctor; tweaking CD * chore: patch pre-commit ignores for vendor folder * chore: patching portability test --------- Co-authored-by: Neil Campbell <[email protected]> Co-authored-by: Altynbek Orumbayev <[email protected]>
- Loading branch information
1 parent
7162a62
commit 3f13704
Showing
20 changed files
with
74 additions
and
376 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 |
---|---|---|
|
@@ -3,7 +3,7 @@ name: Publish packages to public repositories | |
on: | ||
workflow_call: | ||
inputs: | ||
wheelArtifactName: | ||
artifactName: | ||
required: true | ||
type: string | ||
description: "The github artifact holding the wheel file which will be published" | ||
|
@@ -16,11 +16,6 @@ on: | |
default: true | ||
type: boolean | ||
description: "Publish to brew repository" | ||
do_chocolatey: | ||
required: false | ||
default: true | ||
type: boolean | ||
description: "Publish to Chocolatey repository" | ||
do_snap: | ||
required: false | ||
default: true | ||
|
@@ -31,32 +26,6 @@ on: | |
default: true | ||
type: boolean | ||
description: "Publish to Winget repository" | ||
workflow_dispatch: | ||
inputs: | ||
release_version: | ||
required: true | ||
type: string | ||
description: "The release version that will be published (e.g. 0.1.0). Note this is not the tag version." | ||
do_brew: | ||
required: false | ||
default: true | ||
type: boolean | ||
description: "Publish to brew repository" | ||
do_chocolatey: | ||
required: false | ||
default: true | ||
type: boolean | ||
description: "Publish to Chocolatey repository" | ||
do_winget: | ||
required: false | ||
default: true | ||
type: boolean | ||
description: "Publish to Winget repository" | ||
do_snap: | ||
required: false | ||
default: true | ||
type: boolean | ||
description: "Publish to snap repository" | ||
|
||
jobs: | ||
publish-brew: | ||
|
@@ -66,84 +35,24 @@ jobs: | |
- name: Checkout source code | ||
uses: actions/checkout@v4 | ||
|
||
# Download either via release or provided artifact | ||
- name: Download wheel from release | ||
if: ${{ github.event_name == 'workflow_dispatch' }} | ||
run: gh release download v${{ inputs.release_version }} --pattern "*.whl" --dir dist | ||
env: | ||
GH_TOKEN: ${{ github.token }} | ||
|
||
- name: Download wheel from artifact | ||
if: ${{ github.event_name == 'workflow_call' }} | ||
uses: actions/download-artifact@v4 | ||
with: | ||
name: ${{ inputs.wheelArtifactName }} | ||
path: dist | ||
|
||
- name: Download macOS binary from release | ||
if: ${{ github.event_name == 'workflow_dispatch' }} | ||
run: gh release download ${{ inputs.release }} --pattern "*-brew.tar.gz" --dir dist | ||
- name: Download binary artifact from release | ||
run: gh release download v${{ inputs.release_version }} --pattern "*-brew.tar.gz" --dir dist | ||
env: | ||
GH_TOKEN: ${{ github.token }} | ||
|
||
- name: Download macOS binary from artifact | ||
uses: actions/download-artifact@v4 | ||
if: ${{ github.event_name == 'workflow_call' }} | ||
with: | ||
name: ${{ inputs.binaryArtifactName }} | ||
path: dist | ||
|
||
- name: Set Git user as GitHub actions | ||
run: git config --global user.email "[email protected]" && git config --global user.name "github-actions" | ||
|
||
- name: ls dist folder | ||
run: ls -la dist | ||
|
||
- name: Update homebrew cask | ||
run: scripts/update-brew-cask.sh "dist/algokit*-py3-none-any.whl" "dist/algokit*-macos_arm64-brew.tar.gz" "dist/algokit*-macos_x64-brew.tar.gz" "algorandfoundation/homebrew-tap" | ||
env: | ||
TAP_GITHUB_TOKEN: ${{ secrets.TAP_GITHUB_TOKEN }} | ||
|
||
publish-chocolatey: | ||
runs-on: windows-latest | ||
if: ${{ inputs.do_chocolatey }} | ||
steps: | ||
- name: Checkout source code | ||
uses: actions/checkout@v4 | ||
|
||
# Download either via release or provided artifact | ||
- name: Download release | ||
if: ${{ github.event_name == 'workflow_dispatch' }} | ||
run: gh release download v${{ inputs.release_version }} --pattern "*.whl" --dir dist | ||
env: | ||
GH_TOKEN: ${{ github.token }} | ||
|
||
- name: Download artifact | ||
if: ${{ github.event_name == 'workflow_call' }} | ||
uses: actions/download-artifact@v4 | ||
with: | ||
name: ${{ inputs.artifactName }} | ||
path: dist | ||
|
||
- name: Update chocolatey files | ||
id: update_chocolatey_files | ||
run: scripts/update-chocolatey-package.ps1 | ||
|
||
- name: Build package | ||
uses: crazy-max/ghaction-chocolatey@v2 | ||
with: | ||
args: pack --version ${{ steps.update_chocolatey_files.outputs.version }} .\scripts\chocolatey\algokit\algokit.nuspec | ||
|
||
- name: Set API key | ||
uses: crazy-max/ghaction-chocolatey@v2 | ||
with: | ||
args: apikey --api-key ${{ secrets.CHOCOLATEY_API_KEY }} -source https://push.chocolatey.org/ | ||
|
||
- name: Push package | ||
uses: crazy-max/ghaction-chocolatey@v2 | ||
with: | ||
args: push --source https://push.chocolatey.org/ | ||
|
||
publish-winget: | ||
runs-on: windows-latest | ||
if: ${{ inputs.do_winget }} | ||
|
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
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
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Binary file not shown.
Oops, something went wrong.
3f13704
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverage Report