Skip to content

Commit

Permalink
release homebrew
Browse files Browse the repository at this point in the history
  • Loading branch information
xasopheno committed Oct 29, 2022
1 parent 159755d commit 8169792
Showing 1 changed file with 26 additions and 27 deletions.
53 changes: 26 additions & 27 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,36 +55,35 @@ jobs:
run: |
printf "::set-output name=%s::%s\n" tag-name "${GITHUB_REF#refs/tags/}"
- name: Setup publish to crates.io
run: |
git config --global user.email "weresocool_bot@xasopheno.com"
git config --global user.name "WereSoCool Bot"
cargo login ${{ secrets.CARGO_API_KEY }}
# - name: Setup publish to crates.io
# run: |
# git config --global user.email "weresocool_bot@xasopheno.com"
# git config --global user.name "WereSoCool Bot"
# cargo login ${{ secrets.CARGO_API_KEY }}

- name: publish to crates.io
run:
publish-cool-workspace smart-release --bump "${GITHUB_REF#refs/tags/}" --no-changelog --update-crates-index --execute
- name: squash bump commit
run: |
git reset --soft HEAD~1
git commit --amend --no-edit
git push --force
# - name: publish to crates.io
# run:
# publish-cool-workspace smart-release --bump "${GITHUB_REF#refs/tags/}" --no-changelog --update-crates-index --execute
# - name: squash bump commit
# run: |
# git reset --soft HEAD~1
# git commit --amend --no-edit
# git push --force

- name: Package MacOS Binary
run: ./scripts/package_macos.sh ${{ steps.extract-version.outputs.tag-name }}
# - name: Package MacOS Binary
# run: ./scripts/package_macos.sh ${{ steps.extract-version.outputs.tag-name }}

- name: Releasing MacOS Binary
uses: softprops/action-gh-release@cd28b0f5ee8571b76cfdaa62a30d51d752317477
with:
files: |
target/release/weresocool-mac-${{ steps.extract-version.outputs.tag-name }}.tar.gz
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# - name: Releasing MacOS Binary
# uses: "marvinpinto/action-automatic-releases@latest"
# with:
# repo_token: "${{ secrets.GITHUB_TOKEN }}"
# files: |
# target/release/weresocool-mac-${{ steps.extract-version.outputs.tag-name }}.tar.gz

- name: Set SHA
id: shasum
run: |
echo ::set-output name=sha::"$(shasum -a 256 ./target/release/weresocool-mac-${{ steps.extract-version.outputs.tag-name }}.tar.gz | awk '{printf $1}')"
# - name: Set SHA
# id: shasum
# run: |
# echo ::set-output name=sha::"$(shasum -a 256 ./target/release/weresocool-mac-${{ steps.extract-version.outputs.tag-name }}.tar.gz | awk '{printf $1}')"

- name: Bump Homebrew formula
uses: xasopheno/weresocool-bump-homebrew-formula@v0.0.1
Expand All @@ -94,7 +93,7 @@ jobs:
with:
base-branch: main
formula-name: weresocool
create-pullrequest: true
create-pullrequest: false
homebrew-tap: xasopheno/homebrew-weresocool
tag-name: ${{ steps.extract-version.outputs.tag-name }}
download-url: https://github.com/xasopheno/weresocool/releases/latest/download/weresocool-mac-${{ steps.extract-version.outputs.tag-name }}.tar.gz
Expand Down

0 comments on commit 8169792

Please sign in to comment.