-
Notifications
You must be signed in to change notification settings - Fork 10
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
Showing
5 changed files
with
32 additions
and
10 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 |
---|---|---|
|
@@ -43,6 +43,8 @@ jobs: | |
runs-on: macos-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
- name: Get Release Version | ||
run: | | ||
echo GITHUB_REF=$GITHUB_REF | ||
|
@@ -103,13 +105,12 @@ jobs: | |
cat $HOME/tera.rb | ||
- name: Update Homebrew Formula | ||
if: github.ref == 'refs/heads/master' | ||
run: | | ||
cp -f $HOME/tera.rb Formula/tera.rb | ||
git config --global user.name 'TeraBot' | ||
git config --global user.email '[email protected]' | ||
git commit Formula/tera.rb -m "build: new homebrew formula for ${{ env.RELEASE_VERSION }}" | ||
git push | ||
git push origin HEAD:master | ||
create_draft: | ||
needs: ["linux", "macos"] | ||
|
@@ -149,9 +150,8 @@ jobs: | |
- name: Render release notes | ||
run: | | ||
export DEBIAN_URL="https://github.com/chevdor/tera-cli/releases/download/${{ env.RELEASE_VERSION }}/linux/tera-cli_linux_amd64.deb" | ||
export MACOS_TGZ_URL="https://github.com/chevdor/tera-cli/releases/download/${{ env.RELEASE_VERSION }}/macos/tera-macos-${{ env.RELEASE_VERSION }}.tar.gz" | ||
export MACOS_BIN_URL="https://github.com/chevdor/tera-cli/releases/download/${{ env.RELEASE_VERSION }}/macos/tera-macos-${{ env.RELEASE_VERSION }}" | ||
export DEBIAN_URL="https://github.com/chevdor/tera-cli/releases/download/${{ env.RELEASE_VERSION }}/tera-cli_linux_amd64.deb" | ||
export MACOS_TGZ_URL="https://github.com/chevdor/tera-cli/releases/download/${{ env.RELEASE_VERSION }}/tera-macos-${{ env.RELEASE_VERSION }}.tar.gz" | ||
export CHANGELOG=$(cat changelog.md) | ||
tera --env --env-only --template templates/release.md > RELEASE_NOTES.md | ||
|
@@ -178,7 +178,7 @@ jobs: | |
- uses: actions/download-artifact@v2 | ||
|
||
- name: Upload binaries | ||
- name: Upload Debian package | ||
uses: actions/upload-release-asset@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
@@ -187,3 +187,13 @@ jobs: | |
asset_path: "linux/tera-cli_linux_amd64.deb" | ||
asset_name: "tera-cli_linux_amd64.deb" | ||
asset_content_type: application/vnd.debian.binary-package | ||
|
||
- name: Upload MacOS archive | ||
uses: actions/upload-release-asset@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
upload_url: ${{ needs.create_draft.outputs.asset_upload_url }} | ||
asset_path: "macos/tera-macos-${{ env.RELEASE_VERSION }}.tar.gz" | ||
asset_name: "tera-macos-${{ env.RELEASE_VERSION }}.tar.gz" | ||
asset_content_type: application/gzip |
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 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,4 +11,4 @@ class {{ NAME }} < Formula | |
def install | ||
bin.install "{{ BIN }}" | ||
end | ||
end | ||
end |
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