try nix for ci

This commit is contained in:
adueck 2023-11-29 11:18:47 +04:00
parent 417011ba77
commit 08500aa06c
3 changed files with 30 additions and 0 deletions

18
.github/workflows/test-nix.yml vendored Normal file
View File

@ -0,0 +1,18 @@
name: "Test Nix"
on:
pull_request:
push:
jobs:
tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: cachix/install-nix-action@v18
with:
nix_path: nixpkgs = fetchTarball "https://github.com/NixOS/nixpkgs/tarball/nixos-23.05"
- uses: workflow/nix-shell-action@v3
with:
packages: nodejs_20,pandoc
script: |
node --version
pandoc --version

2
dev Executable file
View File

@ -0,0 +1,2 @@
nix-shell --command return
node --version

10
shell.nix Normal file
View File

@ -0,0 +1,10 @@
let
nixpkgs = fetchTarball "https://github.com/NixOS/nixpkgs/tarball/nixos-23.05";
pkgs = import nixpkgs { config = {}; overlays = []; };
in
pkgs.mkShell {
packages = with pkgs; [
nodejs_20
];
}