build(flake.lock,flake.nix): add git-hooks and dedupe_gitignore
This commit is contained in:
parent
295f5daba9
commit
63609ffa14
3 changed files with 66 additions and 0 deletions
48
flake.lock
generated
48
flake.lock
generated
|
@ -15,6 +15,26 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"dedupe_gitignore": {
|
||||||
|
"inputs": {
|
||||||
|
"nixpkgs": [
|
||||||
|
"nixpkgs"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1709087332,
|
||||||
|
"narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=",
|
||||||
|
"owner": "hercules-ci",
|
||||||
|
"repo": "gitignore.nix",
|
||||||
|
"rev": "637db329424fd7e46cf4185293b9cc8c88c95394",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "hercules-ci",
|
||||||
|
"repo": "gitignore.nix",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
"files": {
|
"files": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1750263550,
|
"lastModified": 1750263550,
|
||||||
|
@ -50,6 +70,32 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"git-hooks": {
|
||||||
|
"inputs": {
|
||||||
|
"flake-compat": [
|
||||||
|
"dedupe_flake-compat"
|
||||||
|
],
|
||||||
|
"gitignore": [
|
||||||
|
"dedupe_gitignore"
|
||||||
|
],
|
||||||
|
"nixpkgs": [
|
||||||
|
"nixpkgs"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1750779888,
|
||||||
|
"narHash": "sha256-wibppH3g/E2lxU43ZQHC5yA/7kIKLGxVEnsnVK1BtRg=",
|
||||||
|
"owner": "cachix",
|
||||||
|
"repo": "git-hooks.nix",
|
||||||
|
"rev": "16ec914f6fb6f599ce988427d9d94efddf25fe6d",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "cachix",
|
||||||
|
"repo": "git-hooks.nix",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
"import-tree": {
|
"import-tree": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1751399845,
|
"lastModified": 1751399845,
|
||||||
|
@ -104,8 +150,10 @@
|
||||||
"root": {
|
"root": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"dedupe_flake-compat": "dedupe_flake-compat",
|
"dedupe_flake-compat": "dedupe_flake-compat",
|
||||||
|
"dedupe_gitignore": "dedupe_gitignore",
|
||||||
"files": "files",
|
"files": "files",
|
||||||
"flake-parts": "flake-parts",
|
"flake-parts": "flake-parts",
|
||||||
|
"git-hooks": "git-hooks",
|
||||||
"import-tree": "import-tree",
|
"import-tree": "import-tree",
|
||||||
"make-shell": "make-shell",
|
"make-shell": "make-shell",
|
||||||
"nixpkgs": "nixpkgs"
|
"nixpkgs": "nixpkgs"
|
||||||
|
|
13
flake.nix
13
flake.nix
|
@ -16,9 +16,22 @@
|
||||||
url = "github:nicknovitski/make-shell";
|
url = "github:nicknovitski/make-shell";
|
||||||
inputs.flake-compat.follows = "dedupe_flake-compat";
|
inputs.flake-compat.follows = "dedupe_flake-compat";
|
||||||
};
|
};
|
||||||
|
# git-hooks ensures nix flake check is ran before commits
|
||||||
|
git-hooks = {
|
||||||
|
url = "github:cachix/git-hooks.nix";
|
||||||
|
inputs = {
|
||||||
|
flake-compat.follows = "dedupe_flake-compat";
|
||||||
|
nixpkgs.follows = "nixpkgs";
|
||||||
|
gitignore.follows = "dedupe_gitignore";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
# The following are not used but are here for deduplication.
|
# The following are not used but are here for deduplication.
|
||||||
dedupe_flake-compat.url = "github:edolstra/flake-compat";
|
dedupe_flake-compat.url = "github:edolstra/flake-compat";
|
||||||
|
dedupe_gitignore = {
|
||||||
|
url = "github:hercules-ci/gitignore.nix";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = inputs: inputs.flake-parts.lib.mkFlake { inherit inputs; } (inputs.import-tree ./modules);
|
outputs = inputs: inputs.flake-parts.lib.mkFlake { inherit inputs; } (inputs.import-tree ./modules);
|
||||||
|
|
5
modules/flake-parts/git-hooks.nix
Normal file
5
modules/flake-parts/git-hooks.nix
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
{ inputs, ... }:
|
||||||
|
{
|
||||||
|
# TODO: add to readme
|
||||||
|
imports = [ inputs.git-hooks.flakeModule ];
|
||||||
|
}
|
Loading…
Add table
Add a link
Reference in a new issue