mirror of
https://github.com/sajenim/javascript-template.git
synced 2025-12-16 11:30:38 +08:00
Remove root devshell - templates are self-contained
The root flake only defines templates. Each template (templates/vanilla/ and templates/nextjs/) contains its own complete Nix configuration with devshell, so root-level development environment is unnecessary.
This commit is contained in:
parent
2b228ebd52
commit
1413b1b10d
3 changed files with 0 additions and 47 deletions
1
.envrc
1
.envrc
|
|
@ -1 +0,0 @@
|
|||
use flake
|
||||
|
|
@ -11,7 +11,6 @@
|
|||
inputs.flake-parts.lib.mkFlake {inherit inputs;} {
|
||||
systems = import inputs.systems;
|
||||
imports = [
|
||||
./nix/modules/devshell.nix
|
||||
./nix/modules/template.nix
|
||||
];
|
||||
};
|
||||
|
|
|
|||
|
|
@ -1,45 +0,0 @@
|
|||
{inputs, lib, ...}: let
|
||||
# FHS compatibility for NixOS (steam-run wrapper)
|
||||
# Enable if bun-installed binaries fail to find system libraries
|
||||
fhs = false;
|
||||
in {
|
||||
perSystem = {system, ...}: let
|
||||
pkgs = import inputs.nixpkgs {
|
||||
inherit system;
|
||||
config.allowUnfree = fhs;
|
||||
};
|
||||
|
||||
fhsPackages = lib.optionals fhs [
|
||||
pkgs.steam-run
|
||||
];
|
||||
|
||||
fhsSetup = lib.optionalString fhs ''
|
||||
alias bun="steam-run bun"
|
||||
'';
|
||||
in {
|
||||
devShells.default = pkgs.mkShell {
|
||||
nativeBuildInputs = with pkgs;
|
||||
[
|
||||
bun
|
||||
nodejs
|
||||
typescript
|
||||
eslint
|
||||
just
|
||||
prettierd
|
||||
]
|
||||
++ fhsPackages;
|
||||
|
||||
shellHook = ''
|
||||
${fhsSetup}
|
||||
|
||||
if [ -f package.json ]; then
|
||||
echo "Installing dependencies..."
|
||||
bun install
|
||||
fi
|
||||
|
||||
echo ""
|
||||
echo "💡 Run 'just' to see available commands"
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue