-
-
Notifications
You must be signed in to change notification settings - Fork 606
Added Nightly Release Workflow + Tag #2091
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
Closed
Changes from all commits
Commits
Show all changes
23 commits
Select commit
Hold shift + click to select a range
dd389bc
Create nightly.yml
Concelare 5ba810b
Update nightly.yml
Concelare 25b1526
Update nightly.yml
Concelare 678d947
Update nightly.yml
Concelare fbcbe53
Update nightly.yml
Concelare 08d8d1a
Update nightly.yml
Concelare 6b60ef5
Update nightly.yml
Concelare d1ecf15
Update nightly.yml
Concelare c2e7c0a
Update nightly.yml
Concelare e8db808
Update nightly.yml
Concelare 3b58e7d
Update nightly.yml
Concelare 8d39ef7
Update nightly.yml
Concelare 24e6f90
Update nightly.yml
Concelare 94090f8
Update nightly.yml
Concelare 1d342f4
Update nightly.yml
Concelare 0755f93
Update nightly.yml
Concelare 3aa1030
Merge branch 'extrawurst:master' into master
Concelare 7340686
Update nightly.yml
Concelare 646424d
Update nightly.yml
Concelare 939a832
Update nightly.yml
Concelare 9089db7
Merge branch 'extrawurst:master' into master
Concelare 7d14e87
Merge branch 'extrawurst:master' into master
Concelare af33062
Merge branch 'extrawurst:master' into master
Concelare File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 |
---|---|---|
@@ -0,0 +1,132 @@ | ||
name: Build Nightly Releases | ||
on: | ||
workflow_dispatch: | ||
schedule: | ||
- cron: '0 0 * * *' # run at 0 AM UTC | ||
|
||
env: | ||
CARGO_TERM_COLOR: always | ||
|
||
jobs: | ||
release: | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ubuntu-latest, macos-latest, windows-latest, ubuntu-22.04] | ||
runs-on: ${{ matrix.os }} | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Get version | ||
id: get_version | ||
run: echo "version=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_OUTPUT | ||
|
||
- name: Restore cargo cache | ||
uses: Swatinem/rust-cache@v2 | ||
env: | ||
cache-name: ci | ||
with: | ||
shared-key: ${{ matrix.os }}-${{ env.cache-name }}-stable | ||
|
||
- name: Install Rust | ||
uses: dtolnay/rust-toolchain@stable | ||
with: | ||
components: clippy | ||
|
||
- name: Build | ||
if: matrix.os != 'ubuntu-22.04' | ||
run: cargo build | ||
- name: Run tests | ||
if: matrix.os != 'ubuntu-22.04' | ||
run: make test | ||
- name: Run clippy | ||
if: matrix.os != 'ubuntu-22.04' | ||
run: | | ||
cargo clean | ||
make clippy | ||
|
||
- name: Setup MUSL | ||
if: matrix.os == 'ubuntu-latest' | ||
run: | | ||
rustup target add x86_64-unknown-linux-musl | ||
sudo apt-get -qq install musl-tools | ||
|
||
- name: Setup ARM toolchain | ||
if: matrix.os == 'ubuntu-22.04' | ||
run: | | ||
rustup target add aarch64-unknown-linux-gnu | ||
rustup target add armv7-unknown-linux-gnueabihf | ||
rustup target add arm-unknown-linux-gnueabihf | ||
|
||
curl -o $GITHUB_WORKSPACE/aarch64.tar.xz https://armkeil.blob.core.windows.net/developer/Files/downloads/gnu-a/8.2-2018.08/gcc-arm-8.2-2018.08-x86_64-aarch64-linux-gnu.tar.xz | ||
curl -o $GITHUB_WORKSPACE/arm.tar.xz https://armkeil.blob.core.windows.net/developer/Files/downloads/gnu-a/8.2-2018.08/gcc-arm-8.2-2018.08-x86_64-arm-linux-gnueabihf.tar.xz | ||
|
||
tar xf $GITHUB_WORKSPACE/aarch64.tar.xz | ||
tar xf $GITHUB_WORKSPACE/arm.tar.xz | ||
|
||
echo "$GITHUB_WORKSPACE/gcc-arm-8.2-2018.08-x86_64-aarch64-linux-gnu/bin" >> $GITHUB_PATH | ||
echo "$GITHUB_WORKSPACE/gcc-arm-8.2-2018.08-x86_64-arm-linux-gnueabihf/bin" >> $GITHUB_PATH | ||
|
||
- name: Build Release Mac | ||
if: matrix.os == 'macos-latest' | ||
run: make release-mac | ||
- name: Build Release Linux | ||
if: matrix.os == 'ubuntu-latest' | ||
run: make release-linux-musl | ||
- name: Build Release Win | ||
if: matrix.os == 'windows-latest' | ||
run: make release-win | ||
- name: Build Release Linux ARM | ||
if: matrix.os == 'ubuntu-22.04' | ||
run: make release-linux-arm | ||
|
||
- name: Set SHA | ||
if: matrix.os == 'macos-latest' | ||
id: shasum | ||
run: | | ||
echo sha="$(shasum -a 256 ./release/gitui-mac.tar.gz | awk '{printf $1}')" >> $GITHUB_OUTPUT | ||
|
||
- name: Ubuntu 22.04 Upload Artifact | ||
if: matrix.os == 'ubuntu-22.04' | ||
env: | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_KEY_SECRET }} | ||
AWS_DEFAULT_REGION: ${{ secrets.AWS_DEFAULT_REGION }} | ||
AWS_BUCKET_NAME: ${{ secrets.AWS_BUCKET_NAME }} | ||
run: | | ||
aws s3 cp ./release/gitui-linux-armv7.tar.gz s3://"$AWS_BUCKET_NAME"/nightly-builds/ | ||
aws s3 cp ./release/gitui-linux-arm.tar.gz s3://"$AWS_BUCKET_NAME"/nightly-builds/ | ||
aws s3 cp ./release/gitui-linux-aarch64.tar.gz s3://"$AWS_BUCKET_NAME"/nightly-builds/ | ||
|
||
- name: Ubuntu Latest Upload Artifact | ||
if: matrix.os == 'ubuntu-latest' | ||
env: | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_KEY_SECRET }} | ||
AWS_DEFAULT_REGION: ${{ secrets.AWS_DEFAULT_REGION }} | ||
AWS_BUCKET_NAME: ${{ secrets.AWS_BUCKET_NAME }} | ||
run: | | ||
aws s3 cp ./release/gitui-linux-musl.tar.gz s3://"$AWS_BUCKET_NAME"/nightly-builds/ | ||
|
||
|
||
- name: MacOS Upload Artifact | ||
if: matrix.os == 'macos-latest' | ||
env: | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_KEY_SECRET }} | ||
AWS_DEFAULT_REGION: ${{ secrets.AWS_DEFAULT_REGION }} | ||
AWS_BUCKET_NAME: ${{ secrets.AWS_BUCKET_NAME }} | ||
run: | | ||
aws s3 cp ./release/gitui-mac.tar.gz s3://"$AWS_BUCKET_NAME"/nightly-builds/ | ||
|
||
- name: Windows Upload Artifact | ||
if: matrix.os == 'windows-latest' | ||
env: | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_KEY_SECRET }} | ||
AWS_DEFAULT_REGION: ${{ secrets.AWS_DEFAULT_REGION }} | ||
AWS_BUCKET_NAME: ${{ secrets.AWS_BUCKET_NAME }} | ||
run: | | ||
aws s3 cp ./release/gitui.msi s3://"$env:AWS_BUCKET_NAME"/nightly-builds/ | ||
aws s3 cp ./release/gitui-win.tar.gz s3://"$env:AWS_BUCKET_NAME"/nightly-builds/ |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
what is this
$env
?