chore(workflows): Use nix-shell helper
This commit is contained in:
parent
ea9f513459
commit
18137768ae
11 changed files with 38 additions and 9 deletions
|
@ -1,3 +1,5 @@
|
||||||
|
###
|
||||||
|
# This file was automatically generated with nix-actions.
|
||||||
jobs:
|
jobs:
|
||||||
check_dns:
|
check_dns:
|
||||||
runs-on: nix
|
runs-on: nix
|
||||||
|
|
|
@ -1,8 +1,11 @@
|
||||||
|
###
|
||||||
|
# This file was automatically generated with nix-actions.
|
||||||
jobs:
|
jobs:
|
||||||
check_workflows:
|
check_workflows:
|
||||||
runs-on: nix
|
runs-on: nix
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
|
with: {}
|
||||||
- name: Check that the workflows are up to date
|
- name: Check that the workflows are up to date
|
||||||
run: nix-shell -A check-workflows --run '[ $(git status --porcelain | wc -l)
|
run: nix-shell -A check-workflows --run '[ $(git status --porcelain | wc -l)
|
||||||
-eq 0 ]'
|
-eq 0 ]'
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
###
|
||||||
|
# This file was automatically generated with nix-actions.
|
||||||
jobs:
|
jobs:
|
||||||
ap01:
|
ap01:
|
||||||
runs-on: nix
|
runs-on: nix
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
###
|
||||||
|
# This file was automatically generated with nix-actions.
|
||||||
jobs:
|
jobs:
|
||||||
build-shell:
|
build-shell:
|
||||||
runs-on: nix
|
runs-on: nix
|
||||||
|
@ -8,7 +10,7 @@ jobs:
|
||||||
STORE_PASSWORD: ${{ secrets.STORE_PASSWORD }}
|
STORE_PASSWORD: ${{ secrets.STORE_PASSWORD }}
|
||||||
STORE_USER: admin
|
STORE_USER: admin
|
||||||
name: Build and cache shell
|
name: Build and cache shell
|
||||||
run: nix-shell -A eval-shell --run "nix-build-and-cache -A devShell"
|
run: nix-shell -A eval-shell --run 'nix-build-and-cache -A devShell'
|
||||||
name: Build the shell
|
name: Build the shell
|
||||||
on:
|
on:
|
||||||
pull_request:
|
pull_request:
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
###
|
||||||
|
# This file was automatically generated with nix-actions.
|
||||||
env:
|
env:
|
||||||
GIT_AUTHOR_EMAIL: chores@mail.hubrecht.ovh
|
GIT_AUTHOR_EMAIL: chores@mail.hubrecht.ovh
|
||||||
GIT_AUTHOR_NAME: HT Chores
|
GIT_AUTHOR_NAME: HT Chores
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
###
|
||||||
|
# This file was automatically generated with nix-actions.
|
||||||
jobs:
|
jobs:
|
||||||
pre-commit:
|
pre-commit:
|
||||||
runs-on: nix
|
runs-on: nix
|
||||||
|
|
|
@ -225,10 +225,10 @@
|
||||||
"pre_releases": false,
|
"pre_releases": false,
|
||||||
"version_upper_bound": null,
|
"version_upper_bound": null,
|
||||||
"release_prefix": null,
|
"release_prefix": null,
|
||||||
"version": "v0.3.0",
|
"version": "v0.4.2",
|
||||||
"revision": "15a5f4cd9909cad78c8be852d176def42d5ab3cd",
|
"revision": "6cf7970c0916cc3c05b5289d28ec89b4e35b6e5b",
|
||||||
"url": null,
|
"url": null,
|
||||||
"hash": "16gssfs2qxy1nqnfqpbn076i79zna295jzix897346ic3gy11610"
|
"hash": "0y9z1l1b6g1nj7l3xypbs1fnlad31ny7n8v23n35hd6nbwyslikf"
|
||||||
},
|
},
|
||||||
"nix-modules": {
|
"nix-modules": {
|
||||||
"type": "Git",
|
"type": "Git",
|
||||||
|
|
|
@ -2,6 +2,8 @@
|
||||||
#
|
#
|
||||||
# SPDX-License-Identifier: EUPL-1.2
|
# SPDX-License-Identifier: EUPL-1.2
|
||||||
|
|
||||||
|
{ nix-actions, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
name = "Check workflows";
|
name = "Check workflows";
|
||||||
on = {
|
on = {
|
||||||
|
@ -13,10 +15,13 @@
|
||||||
check_workflows = {
|
check_workflows = {
|
||||||
runs-on = "nix";
|
runs-on = "nix";
|
||||||
steps = [
|
steps = [
|
||||||
{ uses = "actions/checkout@v3"; }
|
(nix-actions.steps.checkout { })
|
||||||
{
|
{
|
||||||
name = "Check that the workflows are up to date";
|
name = "Check that the workflows are up to date";
|
||||||
run = "nix-shell -A check-workflows --run '[ $(git status --porcelain | wc -l) -eq 0 ]'";
|
run = nix-actions.lib.nix-shell {
|
||||||
|
script = "[ $(git status --porcelain | wc -l) -eq 0 ]";
|
||||||
|
shell = "check-workflows";
|
||||||
|
};
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
|
@ -23,7 +23,10 @@ in
|
||||||
{ uses = "actions/checkout@v3"; }
|
{ uses = "actions/checkout@v3"; }
|
||||||
{
|
{
|
||||||
name = "Build and cache ${node}";
|
name = "Build and cache ${node}";
|
||||||
run = "nix-shell -A eval-nodes --run cache-node";
|
run = nix-actions.lib.nix-shell {
|
||||||
|
script = "cache-node";
|
||||||
|
shell = "eval-nodes";
|
||||||
|
};
|
||||||
env = {
|
env = {
|
||||||
STORE_ENDPOINT = "https://tvix-store.dgnum.eu/infra-signing/";
|
STORE_ENDPOINT = "https://tvix-store.dgnum.eu/infra-signing/";
|
||||||
STORE_USER = "admin";
|
STORE_USER = "admin";
|
||||||
|
|
|
@ -18,7 +18,10 @@
|
||||||
{ uses = "actions/checkout@v3"; }
|
{ uses = "actions/checkout@v3"; }
|
||||||
{
|
{
|
||||||
name = "Build and cache shell";
|
name = "Build and cache shell";
|
||||||
run = ''nix-shell -A eval-shell --run "nix-build-and-cache -A devShell"'';
|
run = nix-actions.lib.nix-shell {
|
||||||
|
script = "nix-build-and-cache -A devShell";
|
||||||
|
shell = "eval-shell";
|
||||||
|
};
|
||||||
env = {
|
env = {
|
||||||
STORE_ENDPOINT = "https://tvix-store.dgnum.eu/infra-signing/";
|
STORE_ENDPOINT = "https://tvix-store.dgnum.eu/infra-signing/";
|
||||||
STORE_USER = "admin";
|
STORE_USER = "admin";
|
||||||
|
|
|
@ -2,6 +2,8 @@
|
||||||
#
|
#
|
||||||
# SPDX-License-Identifier: EUPL-1.2
|
# SPDX-License-Identifier: EUPL-1.2
|
||||||
|
|
||||||
|
{ nix-actions, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
name = "Run pre-commit on all files";
|
name = "Run pre-commit on all files";
|
||||||
on = [
|
on = [
|
||||||
|
@ -16,7 +18,10 @@
|
||||||
++ (builtins.map
|
++ (builtins.map
|
||||||
(stage: {
|
(stage: {
|
||||||
name = "Check stage ${stage}";
|
name = "Check stage ${stage}";
|
||||||
run = "nix-shell -A pre-commit --run 'pre-commit run --all-files --hook-stage ${stage} --show-diff-on-failure'";
|
run = nix-actions.lib.nix-shell {
|
||||||
|
script = "pre-commit run --all-files --hook-stage ${stage} --show-diff-on-failure";
|
||||||
|
shell = "pre-commit";
|
||||||
|
};
|
||||||
})
|
})
|
||||||
[
|
[
|
||||||
"pre-commit"
|
"pre-commit"
|
||||||
|
|
Loading…
Add table
Reference in a new issue