ci: add woodpecker workflow for checking flake files
Signed-off-by: Christoph Heiss <christoph@c8h4.io>
This commit is contained in:
parent
ebdc89c63f
commit
2730987623
23
.woodpecker/check-flake-files.yaml
Normal file
23
.woodpecker/check-flake-files.yaml
Normal file
|
@ -0,0 +1,23 @@
|
|||
---
|
||||
when:
|
||||
- event: push
|
||||
- event: pull_request
|
||||
path:
|
||||
'flakes/**/*.toml'
|
||||
|
||||
steps:
|
||||
- name: build
|
||||
image: docker.io/nixos/nix
|
||||
environment:
|
||||
NIX_CONFIG: 'experimental-features = nix-command flakes'
|
||||
RUST_LOG: debug
|
||||
commands:
|
||||
- |
|
||||
for f in flakes/**/*.toml; do
|
||||
echo "checking flake info for $f"
|
||||
nix run --accept-flake-config .#flake-info -- --json group "$f" "$(basename "$f" .toml)" --report
|
||||
if [[ -f report.txt ]]; then
|
||||
cat report.txt
|
||||
exit 1
|
||||
fi
|
||||
done
|
Loading…
Reference in a new issue