support nix flake for dev

This commit is contained in:
PCloud 2024-12-14 22:35:06 +00:00
parent 2349f8f660
commit bec0b54025
3 changed files with 65 additions and 4 deletions

View File

@ -107,7 +107,7 @@
}
/*
! tailwindcss v3.4.12 | MIT License | https://tailwindcss.com
! tailwindcss v3.4.15 | MIT License | https://tailwindcss.com
*/
/*
@ -550,7 +550,7 @@ video {
/* Make elements with the HTML hidden attribute stay hidden by default */
[hidden] {
[hidden]:where(:not([hidden="until-found"])) {
display: none;
}
@ -904,7 +904,7 @@ html.dark {
.tw-border-\[\#f0f0f0\] {
--tw-border-opacity: 1;
border-color: rgb(240 240 240 / var(--tw-border-opacity));
border-color: rgb(240 240 240 / var(--tw-border-opacity, 1));
}
.tw-bg-bgColor-secondary {
@ -1061,7 +1061,7 @@ html.dark {
.dark\:tw-border-\[\#363636\]:is(.tw-dark *) {
--tw-border-opacity: 1;
border-color: rgb(54 54 54 / var(--tw-border-opacity));
border-color: rgb(54 54 54 / var(--tw-border-opacity, 1));
}
@media print {

27
flake.lock generated Normal file
View File

@ -0,0 +1,27 @@
{
"nodes": {
"nixpkgs": {
"locked": {
"lastModified": 1733935885,
"narHash": "sha256-xyiHLs6KJ1fxeGmcCxKjJE4yJknVJxbC8Y/ZRYyC8WE=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "5a48e3c2e435e95103d56590188cfed7b70e108c",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixpkgs-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"root": {
"inputs": {
"nixpkgs": "nixpkgs"
}
}
},
"root": "root",
"version": 7
}

34
flake.nix Normal file
View File

@ -0,0 +1,34 @@
{
description = "Example JavaScript development environment for Zero to Nix";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
};
outputs = { self, nixpkgs }:
let
allSystems = [
"x86_64-linux"
"aarch64-linux"
"x86_64-darwin"
"aarch64-darwin"
];
forAllSystems = f: nixpkgs.lib.genAttrs allSystems (system: f {
pkgs = import nixpkgs { inherit system; };
});
in
{
devShells = forAllSystems ({ pkgs }: {
default = pkgs.mkShell {
packages = with pkgs; [
nodejs_23
hugo
];
shellHook = ''
npm install && npm run dev
'';
};
});
};
}