Use niv out of nixpkgs (#195)
* Use `niv` out of `nixpkgs` * Update CI tests and add one for Nix formatting
This commit is contained in:
parent
42bf4475e0
commit
2286472305
27
.github/workflows/check.yaml
vendored
27
.github/workflows/check.yaml
vendored
@ -12,7 +12,7 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Check out codebase
|
- name: Check out codebase
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
- name: Install nix
|
- name: Install nix
|
||||||
uses: cachix/install-nix-action@v15
|
uses: cachix/install-nix-action@v15
|
||||||
@ -28,11 +28,11 @@ jobs:
|
|||||||
- name: Test
|
- name: Test
|
||||||
run: nix-shell --run check-code
|
run: nix-shell --run check-code
|
||||||
|
|
||||||
Validate_Format:
|
Validate_Purescript_Format:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Check out codebase
|
- name: Check out codebase
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
- name: Install nix
|
- name: Install nix
|
||||||
uses: cachix/install-nix-action@v15
|
uses: cachix/install-nix-action@v15
|
||||||
@ -43,13 +43,30 @@ jobs:
|
|||||||
run: nix-shell
|
run: nix-shell
|
||||||
|
|
||||||
- name: Validate Format
|
- name: Validate Format
|
||||||
run: nix-shell --run check-format
|
run: nix-shell --run check-format-purescript
|
||||||
|
|
||||||
|
Validate_Nix_Format:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Check out codebase
|
||||||
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
|
- name: Install nix
|
||||||
|
uses: cachix/install-nix-action@v15
|
||||||
|
with:
|
||||||
|
nix_path: nixpkgs=channel:nixpkgs-unstable
|
||||||
|
|
||||||
|
- name: Install environment
|
||||||
|
run: nix-shell
|
||||||
|
|
||||||
|
- name: Validate Format
|
||||||
|
run: nix-shell --run check-format-nix
|
||||||
|
|
||||||
Validate_Pulp:
|
Validate_Pulp:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Check out codebase
|
- name: Check out codebase
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
- name: Install nix
|
- name: Install nix
|
||||||
uses: cachix/install-nix-action@v15
|
uses: cachix/install-nix-action@v15
|
||||||
|
@ -2,13 +2,12 @@
|
|||||||
sources ? import ./sources.nix,
|
sources ? import ./sources.nix,
|
||||||
nixpkgs ? sources.nixpkgs,
|
nixpkgs ? sources.nixpkgs,
|
||||||
easy-purescript-nix ? sources.easy-purescript-nix,
|
easy-purescript-nix ? sources.easy-purescript-nix,
|
||||||
niv ? sources.niv,
|
|
||||||
alejandra ? sources.alejandra,
|
alejandra ? sources.alejandra,
|
||||||
}: let
|
}: let
|
||||||
niv-overlay = self: _: {
|
niv-overlay = self: super: {
|
||||||
niv = self.symlinkJoin {
|
niv = self.symlinkJoin {
|
||||||
name = "niv";
|
name = "niv";
|
||||||
paths = [niv];
|
paths = [super.niv];
|
||||||
buildInputs = [self.makeWrapper];
|
buildInputs = [self.makeWrapper];
|
||||||
postBuild = ''
|
postBuild = ''
|
||||||
wrapProgram $out/bin/niv \
|
wrapProgram $out/bin/niv \
|
||||||
|
@ -3,9 +3,7 @@ let
|
|||||||
url = "https://github.com/nmattia/niv/tarball/df49d53b71ad5b6b5847b32e5254924d60703c46";
|
url = "https://github.com/nmattia/niv/tarball/df49d53b71ad5b6b5847b32e5254924d60703c46";
|
||||||
sha256 = "1j5p8mi1wi3pdcq0lfb881p97i232si07nb605dl92cjwnira88c";
|
sha256 = "1j5p8mi1wi3pdcq0lfb881p97i232si07nb605dl92cjwnira88c";
|
||||||
};
|
};
|
||||||
sources = import "${nivSrc}/nix/sources.nix" {
|
|
||||||
sourcesFile = ./sources.json;
|
|
||||||
};
|
|
||||||
niv = import nivSrc {};
|
|
||||||
in
|
in
|
||||||
niv // sources
|
import "${nivSrc}/nix/sources.nix" {
|
||||||
|
sourcesFile = ./sources.json;
|
||||||
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user