This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
# yaml-language-server: $schema=https://raw.githubusercontent.com/SchemaStore/schemastore/master/src/schemas/json/github-workflow.json
|
||||
name: Cache
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
build-and-push:
|
||||
runs-on: nix
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
|
||||
- name: Write niks3 auth token
|
||||
run: |
|
||||
umask 077
|
||||
printf '%s' "${{ secrets.NIKS3_AUTH_TOKEN }}" > "$RUNNER_TEMP/niks3-auth-token"
|
||||
|
||||
- name: Build all packages
|
||||
run: |
|
||||
nix-build --no-out-link | tee "$RUNNER_TEMP/built-paths"
|
||||
|
||||
- name: Push to niks3 cache
|
||||
env:
|
||||
NIKS3_SERVER_URL: https://cache.ekman.oceanbox.io
|
||||
NIKS3_AUTH_TOKEN_FILE: ${{ runner.temp }}/niks3-auth-token
|
||||
run: |
|
||||
niks3="$(nix --extra-experimental-features 'nix-command flakes' \
|
||||
build --no-link --print-out-paths 'github:Mic92/niks3/v1.6.1#niks3')/bin/niks3"
|
||||
xargs -r "$niks3" push < "$RUNNER_TEMP/built-paths"
|
||||
@@ -6,3 +6,5 @@ result-*
|
||||
# Ignore automatically generated direnv output
|
||||
.direnv
|
||||
|
||||
.env
|
||||
niks3-token
|
||||
|
||||
@@ -46,5 +46,7 @@ python3Packages.buildPythonPackage {
|
||||
|
||||
"test_repo_shallow"
|
||||
"test_repo_shallow_without_warning"
|
||||
|
||||
"test_exclude_patterns_deps_dates" # broken at this rev: exclude pattern on deps doesn't fall back correctly
|
||||
];
|
||||
}
|
||||
|
||||
+1
-1
@@ -18,7 +18,7 @@ let
|
||||
|
||||
mkPackages =
|
||||
fun: dir:
|
||||
builtins.map (name: {
|
||||
map (name: {
|
||||
inherit name;
|
||||
value = fun (dir + "/${name}") { };
|
||||
}) (listDirs dir);
|
||||
|
||||
Reference in New Issue
Block a user