-
Notifications
You must be signed in to change notification settings - Fork 1
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
fae1446
commit fae15dc
Showing
4 changed files
with
20 additions
and
13 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: Release | |
on: | ||
push: | ||
tags: | ||
- '[0-9]+.[0-9]+.[0-9]+' | ||
- '[0-9]+.[0-9]+.[0-9]+(-rc[0-9]+)?' | ||
|
||
env: | ||
CARGO_TERM_COLOR: always | ||
|
@@ -12,9 +12,12 @@ jobs: | |
prepare-env: | ||
name: Prepare environment | ||
runs-on: ubuntu-latest | ||
outputs: | ||
release_version: ${{ steps.prepare-env.outputs.RELEASE_VERSION }} | ||
steps: | ||
- name: Get the release version from the tag | ||
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV | ||
id: prepare-env | ||
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT | ||
|
||
build-release: | ||
strategy: | ||
|
@@ -85,15 +88,19 @@ jobs: | |
needs: ['build-release'] | ||
runs-on: ubuntu-latest | ||
steps: | ||
# checkout code | ||
- uses: actions/checkout@v4 | ||
# install rust | ||
- run: rustup show | ||
# publish crate | ||
- shell: bash | ||
env: | ||
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }} | ||
run: cargo publish | ||
|
||
release-aur: | ||
name: Update AUR(i3stat) | ||
needs: ['release-crates'] | ||
needs: ['release-crates', 'prepare-env'] | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: extractions/setup-just@v1 | ||
|
@@ -107,7 +114,7 @@ jobs: | |
echo "${{ vars.SSH_KNOWN_HOSTS }}" >> $HOME/.ssh/known_hosts | ||
chmod 0600 $HOME/.ssh/* | ||
- run: | | ||
git clone ssh://[email protected]/i3stat.git aur && cd "$_" | ||
git clone ssh://[email protected]/i3stat.git aur && cd "$_" && git checkout master | ||
sudo chown -R 1000:1000 "$PWD" | ||
docker run \ | ||
--rm \ | ||
|
@@ -116,13 +123,13 @@ jobs: | |
--env "GIT_COMMITTER_NAME=acheronfail" \ | ||
--env "[email protected]" \ | ||
--env "[email protected]" \ | ||
acheronfail/makepkg just update ${{ env.RELEASE_VERSION }} | ||
acheronfail/makepkg just update ${{ needs.prepare-env.outputs.release_version }} | ||
sudo chown -R $USER:$USER "$PWD" | ||
git push | ||
release-aur-bin: | ||
name: Update AUR(i3stat-bin) | ||
needs: ['release-github'] | ||
needs: ['release-github', 'prepare-env'] | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: extractions/setup-just@v1 | ||
|
@@ -136,7 +143,7 @@ jobs: | |
echo "${{ vars.SSH_KNOWN_HOSTS }}" >> $HOME/.ssh/known_hosts | ||
chmod 0600 $HOME/.ssh/* | ||
- run: | | ||
git clone ssh://[email protected]/i3stat-bin.git aur && cd "$_" | ||
git clone ssh://[email protected]/i3stat-bin.git aur && cd "$_" && git checkout master | ||
sudo chown -R 1000:1000 "$PWD" | ||
docker run \ | ||
--rm \ | ||
|
@@ -145,13 +152,13 @@ jobs: | |
--env "GIT_COMMITTER_NAME=acheronfail" \ | ||
--env "[email protected]" \ | ||
--env "[email protected]" \ | ||
acheronfail/makepkg just update ${{ env.RELEASE_VERSION }} | ||
acheronfail/makepkg just update ${{ needs.prepare-env.outputs.release_version }} | ||
sudo chown -R $USER:$USER "$PWD" | ||
git push | ||
release-github: | ||
name: GitHub Release | ||
needs: ['build-release'] | ||
needs: ['build-release', 'prepare-env'] | ||
runs-on: ubuntu-latest | ||
steps: | ||
# downloads artifacts (this downloads the folder called `artifacts` defined in the `build-release` step) | ||
|
@@ -165,7 +172,7 @@ jobs: | |
with: | ||
files: | | ||
artifacts/i3stat-x86_64-unknown-linux-gnu.zip | ||
tag_name: ${{ env.RELEASE_VERSION }} | ||
tag_name: ${{ needs.prepare-env.outputs.release_version }} | ||
prerelease: true | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
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 |
---|---|---|
|
@@ -59,7 +59,7 @@ jobs: | |
echo "${{ vars.SSH_KNOWN_HOSTS }}" >> $HOME/.ssh/known_hosts | ||
chmod 0600 $HOME/.ssh/* | ||
- run: | | ||
git clone ssh://[email protected]/i3stat-git.git aur && cd "$_" | ||
git clone ssh://[email protected]/i3stat-git.git aur && cd "$_" && git checkout master | ||
sudo chown -R 1000:1000 "$PWD" | ||
docker run \ | ||
--rm \ | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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 |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[package] | ||
name = "i3stat" | ||
version = "0.10.3" | ||
version = "0.10.4-rc1" | ||
edition = "2021" | ||
authors = ["acheronfail <[email protected]>"] | ||
description = "A lightweight and batteries-included status_command for i3 and sway" | ||
|