mirror of
https://github.com/RGBCube/alejandra
synced 2025-07-31 12:37:45 +00:00
feat: release workflow
This commit is contained in:
parent
874c3e7e51
commit
ed40bba5e6
2 changed files with 64 additions and 13 deletions
43
.github/workflows/pr.yaml
vendored
43
.github/workflows/pr.yaml
vendored
|
@ -15,6 +15,10 @@ jobs:
|
|||
- name: Clone
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- uses: cachix/cachix-action@v10
|
||||
with:
|
||||
name: alejandra
|
||||
|
||||
- name: Build
|
||||
uses: docker://nixos/nix
|
||||
with:
|
||||
|
@ -26,20 +30,33 @@ jobs:
|
|||
build
|
||||
--print-build-logs
|
||||
|
||||
- name: Test
|
||||
- name: Check
|
||||
uses: docker://nixos/nix
|
||||
with:
|
||||
args: >
|
||||
bash -ec "
|
||||
source <( \
|
||||
nix \
|
||||
--extra-experimental-features flakes \
|
||||
--extra-experimental-features nix-command \
|
||||
--extra-substituters http://172.17.0.1:5000?trusted=1 \
|
||||
print-dev-env \
|
||||
--no-update-lock-file \
|
||||
--no-write-lock-file \
|
||||
)
|
||||
nix
|
||||
--extra-experimental-features flakes
|
||||
--extra-experimental-features nix-command
|
||||
--extra-substituters http://172.17.0.1:5000?trusted=1
|
||||
flake
|
||||
check
|
||||
--print-build-logs
|
||||
|
||||
cargo tarpaulin
|
||||
"
|
||||
# ERROR cargo_tarpaulin: Failed to run tests: ASLR disable failed: EPERM: Operation not permitted
|
||||
# - name: Test
|
||||
# uses: docker://nixos/nix
|
||||
# with:
|
||||
# args: >
|
||||
# bash -ec "
|
||||
# source <( \
|
||||
# nix \
|
||||
# --extra-experimental-features flakes \
|
||||
# --extra-experimental-features nix-command \
|
||||
# --extra-substituters http://172.17.0.1:5000?trusted=1 \
|
||||
# print-dev-env \
|
||||
# --no-update-lock-file \
|
||||
# --no-write-lock-file \
|
||||
# )
|
||||
|
||||
# cargo tarpaulin
|
||||
# "
|
||||
|
|
34
.github/workflows/release.yaml
vendored
Normal file
34
.github/workflows/release.yaml
vendored
Normal file
|
@ -0,0 +1,34 @@
|
|||
name: Release
|
||||
on:
|
||||
push:
|
||||
branches: [ main ]
|
||||
concurrency:
|
||||
cancel-in-progress: true
|
||||
group: ${{ github.actor }}
|
||||
jobs:
|
||||
release:
|
||||
name: Release
|
||||
runs-on: self-hosted
|
||||
steps:
|
||||
- name: Clone
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- uses: cachix/cachix-action@v10
|
||||
with:
|
||||
name: alejandra
|
||||
authToken: ${{ secrets.CACHIX_AUTH_TOKEN }}
|
||||
|
||||
- name: Build
|
||||
uses: docker://nixos/nix
|
||||
with:
|
||||
args: >
|
||||
nix
|
||||
--extra-experimental-features flakes
|
||||
--extra-experimental-features nix-command
|
||||
--extra-substituters http://172.17.0.1:5000?trusted=1
|
||||
build
|
||||
--print-build-logs
|
||||
|
||||
- name: Push
|
||||
run: |
|
||||
cachix push result
|
Loading…
Add table
Add a link
Reference in a new issue