Flake build

This commit is contained in:
Nox Sluijtman 2024-02-10 21:19:45 +01:00
parent bb3007d53f
commit 51328b664d
3 changed files with 32 additions and 10 deletions

1
.gitignore vendored
View file

@ -2,3 +2,4 @@
public public
voidcruiser.nl voidcruiser.nl
.direnv .direnv
result

View file

@ -20,16 +20,16 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1696983906, "lastModified": 1707347730,
"narHash": "sha256-L7GyeErguS7Pg4h8nK0wGlcUTbfUMDu+HMf1UcyP72k=", "narHash": "sha256-0etC/exQIaqC9vliKhc3eZE2Mm2wgLa0tj93ZF/egvM=",
"owner": "NixOs", "owner": "NixOs",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "bd1cde45c77891214131cbbea5b1203e485a9d51", "rev": "6832d0d99649db3d65a0e15fa51471537b2c56a6",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "NixOs", "owner": "NixOs",
"ref": "nixos-23.05", "ref": "nixos-23.11",
"repo": "nixpkgs", "repo": "nixpkgs",
"type": "github" "type": "github"
} }
@ -37,7 +37,8 @@
"root": { "root": {
"inputs": { "inputs": {
"flake-utils": "flake-utils", "flake-utils": "flake-utils",
"nixpkgs": "nixpkgs" "nixpkgs": "nixpkgs",
"themes": "themes"
} }
}, },
"systems": { "systems": {
@ -54,6 +55,22 @@
"repo": "default", "repo": "default",
"type": "github" "type": "github"
} }
},
"themes": {
"flake": false,
"locked": {
"lastModified": 1707594839,
"narHash": "sha256-VeoBv8LfsTLGSoGpiNlC8gd79xd4InG+bAC6TkBCSHw=",
"owner": "EternalWanderer",
"repo": "themes",
"rev": "53560c95d3bd33362e5552cb9efeaf8234724868",
"type": "gitlab"
},
"original": {
"owner": "EternalWanderer",
"repo": "themes",
"type": "gitlab"
}
} }
}, },
"root": "root", "root": "root",

View file

@ -1,9 +1,13 @@
{ description = "Website flake"; { description = "Voidcruiser website";
inputs = { inputs = {
nixpkgs.url = "github:NixOs/nixpkgs/nixos-23.05"; nixpkgs.url = "github:NixOs/nixpkgs/nixos-23.11";
flake-utils.url = "github:numtide/flake-utils"; flake-utils.url = "github:numtide/flake-utils";
themes = {
url = "gitlab:EternalWanderer/themes";
flake = false;
};
}; };
outputs = { self, nixpkgs, flake-utils }: outputs = { self, nixpkgs, flake-utils, themes }:
flake-utils.lib.eachDefaultSystem (system: flake-utils.lib.eachDefaultSystem (system:
let let
pkgs = import nixpkgs { inherit system; }; pkgs = import nixpkgs { inherit system; };
@ -13,12 +17,12 @@
pname = "voidcruiser"; pname = "voidcruiser";
version = "1.3"; version = "1.3";
src = ./.; src = ./src;
buildInputs = [ pkgs.hugo ]; buildInputs = [ pkgs.hugo ];
buildPhase = '' buildPhase = ''
hugo hugo --themesDir="${themes.outPath}"
''; '';
installPhase = '' installPhase = ''