This commit is contained in:
parent
43fc67ded6
commit
a1f22433a0
17
.github/actions/init.yaml
vendored
Normal file
17
.github/actions/init.yaml
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
name: "Initialize"
|
||||
runs:
|
||||
using: "composite"
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Install Nix
|
||||
uses: cachix/install-nix-action@v31
|
||||
with:
|
||||
nix_path: nixpkgs=channel:nixos-unstable
|
||||
|
||||
- name: Use Cachix
|
||||
uses: cachix/cachix-action@v16
|
||||
with:
|
||||
name: trevstack
|
||||
authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}"
|
14
.github/workflows/check.yaml
vendored
14
.github/workflows/check.yaml
vendored
@ -15,19 +15,7 @@ jobs:
|
||||
contains(github.event.head_commit.message, 'bump:') == false &&
|
||||
contains(github.event.head_commit.message, 'Merge pull request') == false
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Install Nix
|
||||
uses: cachix/install-nix-action@v31
|
||||
with:
|
||||
nix_path: nixpkgs=channel:nixos-unstable
|
||||
|
||||
- name: Use Cachix
|
||||
uses: cachix/cachix-action@v16
|
||||
with:
|
||||
name: trevstack
|
||||
authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}"
|
||||
- uses: ./.github/actions/init
|
||||
|
||||
- name: Check
|
||||
run: nix flake check
|
||||
|
83
.github/workflows/release.yaml
vendored
83
.github/workflows/release.yaml
vendored
@ -13,76 +13,39 @@ jobs:
|
||||
check:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Install Nix
|
||||
uses: cachix/install-nix-action@v31
|
||||
with:
|
||||
nix_path: nixpkgs=channel:nixos-unstable
|
||||
|
||||
- name: Use Cachix
|
||||
uses: cachix/cachix-action@v16
|
||||
with:
|
||||
name: trevstack
|
||||
authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}"
|
||||
- uses: ./.github/actions/init
|
||||
|
||||
- name: Check
|
||||
run: nix flake check
|
||||
|
||||
# release:
|
||||
# runs-on: ubuntu-latest
|
||||
# needs: check
|
||||
# steps:
|
||||
# - name: Checkout
|
||||
# uses: actions/checkout@v4
|
||||
release:
|
||||
runs-on: ubuntu-latest
|
||||
needs: check
|
||||
steps:
|
||||
- uses: ./.github/actions/init
|
||||
|
||||
# - name: Install Nix
|
||||
# uses: cachix/install-nix-action@v31
|
||||
# with:
|
||||
# nix_path: nixpkgs=channel:nixos-unstable
|
||||
- name: Build
|
||||
run: >
|
||||
nix build
|
||||
.#trevstack-linux-amd64
|
||||
.#trevstack-linux-arm64
|
||||
.#trevstack-linux-arm
|
||||
.#trevstack-windows-amd64
|
||||
.#trevstack-darwin-amd64
|
||||
.#trevstack-darwin-arm64
|
||||
|
||||
# - name: Use Cachix
|
||||
# uses: cachix/cachix-action@v16
|
||||
# with:
|
||||
# name: trevstack
|
||||
# authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}"
|
||||
- name: Release
|
||||
uses: softprops/action-gh-release@v2
|
||||
with:
|
||||
generate_release_notes: true
|
||||
files: |-
|
||||
result*/bin/*
|
||||
|
||||
# - name: Build
|
||||
# run: >
|
||||
# nix build
|
||||
# .#trevstack-linux-amd64
|
||||
# .#trevstack-linux-arm64
|
||||
# .#trevstack-linux-arm
|
||||
# .#trevstack-windows-amd64
|
||||
# .#trevstack-darwin-amd64
|
||||
# .#trevstack-darwin-arm64
|
||||
|
||||
# - name: Release
|
||||
# uses: softprops/action-gh-release@v2
|
||||
# with:
|
||||
# generate_release_notes: true
|
||||
# files: |-
|
||||
# result*/bin/*
|
||||
|
||||
# https://docs.docker.com/build/ci/github-actions/manage-tags-labels/
|
||||
package:
|
||||
runs-on: ubuntu-latest
|
||||
needs: check # Wait for binary cache to propagate
|
||||
needs: release
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Install Nix
|
||||
uses: cachix/install-nix-action@v31
|
||||
with:
|
||||
nix_path: nixpkgs=channel:nixos-unstable
|
||||
|
||||
- name: Use Cachix
|
||||
uses: cachix/cachix-action@v16
|
||||
with:
|
||||
name: trevstack
|
||||
authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}"
|
||||
- uses: ./.github/actions/init
|
||||
|
||||
- name: Set env
|
||||
run: |
|
||||
|
14
.github/workflows/update.yaml
vendored
14
.github/workflows/update.yaml
vendored
@ -13,19 +13,7 @@ jobs:
|
||||
update:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Install Nix
|
||||
uses: cachix/install-nix-action@v31
|
||||
with:
|
||||
nix_path: nixpkgs=channel:nixos-unstable
|
||||
|
||||
- name: Use Cachix
|
||||
uses: cachix/cachix-action@v16
|
||||
with:
|
||||
name: trevstack
|
||||
authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}"
|
||||
- uses: ./.github/actions/init
|
||||
|
||||
# https://github.com/actions/checkout/issues/13
|
||||
- name: Set Git Config
|
||||
|
Loading…
x
Reference in New Issue
Block a user