2022-10-20 14:11:53 +00:00
|
|
|
{
|
2024-03-06 15:34:00 +00:00
|
|
|
description = "pub.solar website";
|
2022-10-20 14:11:53 +00:00
|
|
|
|
|
|
|
inputs = {
|
|
|
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
2023-10-28 14:19:53 +00:00
|
|
|
flake-parts.url = "github:hercules-ci/flake-parts";
|
2022-10-20 14:11:53 +00:00
|
|
|
};
|
|
|
|
|
2023-10-28 14:19:53 +00:00
|
|
|
outputs = inputs@{ self, ... }:
|
|
|
|
inputs.flake-parts.lib.mkFlake { inherit inputs; } {
|
|
|
|
systems = [ "x86_64-linux" "aarch64-linux" ];
|
2022-10-20 14:11:53 +00:00
|
|
|
|
2023-10-28 14:19:53 +00:00
|
|
|
perSystem = { system, pkgs, config, ... }: {
|
|
|
|
_module.args = {
|
|
|
|
inherit inputs;
|
|
|
|
pkgs = import inputs.nixpkgs { inherit system; };
|
|
|
|
};
|
|
|
|
|
|
|
|
devShells.default = let
|
|
|
|
google-font-downloader = pkgs.writeShellScriptBin "google-font-downloader" ''
|
|
|
|
echo "Attempting to fetch $1"
|
|
|
|
${pkgs.nodejs}/bin/npx google-font-downloader -- $1
|
|
|
|
rm ./_includes/styles/typography.scss || true
|
|
|
|
echo "/* To regenerate this file, run $ google-font-downloader '$1' */" >> ./_includes/styles/typography.scss
|
2024-04-14 14:34:56 +00:00
|
|
|
echo "" >> ./_includes/styles/typography.scss
|
2023-10-28 14:19:53 +00:00
|
|
|
cat ./google-fonts-*.css >> ./_includes/styles/typography.scss
|
|
|
|
rm ./google-fonts-*.css || true
|
|
|
|
'';
|
|
|
|
in pkgs.mkShell {
|
|
|
|
buildInputs = with pkgs; [
|
2022-10-20 14:11:53 +00:00
|
|
|
deno
|
|
|
|
google-font-downloader
|
|
|
|
];
|
2023-10-28 14:19:53 +00:00
|
|
|
|
2023-10-28 14:25:27 +00:00
|
|
|
shellHook = ''
|
2022-10-20 14:11:53 +00:00
|
|
|
export NVIM_USE_DENOLS=1
|
|
|
|
'';
|
|
|
|
};
|
2023-10-28 14:19:53 +00:00
|
|
|
};
|
2022-10-20 14:11:53 +00:00
|
|
|
};
|
|
|
|
}
|