-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
1,402 additions
and
2,027 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,38 @@ | ||
{ | ||
description = "Dev environment for strato-db"; | ||
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-23.05"; | ||
inputs.flake-utils.url = "github:numtide/flake-utils"; | ||
|
||
outputs = { self, nixpkgs, flake-utils }: | ||
flake-utils.lib.eachDefaultSystem (system: | ||
let | ||
pkgs = nixpkgs.legacyPackages.${system}; | ||
in | ||
{ | ||
devShell = pkgs.mkShell { | ||
inputs = { | ||
# Make sure to use the same locked commits as the nix-infra deploys | ||
# That way the packages are shared | ||
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; | ||
}; | ||
|
||
nativeBuildInputs = with pkgs; [ | ||
sqlite-interactive | ||
outputs = { self, nixpkgs }: | ||
let | ||
b = builtins; | ||
# Make sure that this include runtime libs linked by npm builds | ||
deps = pkgs: with pkgs; [ | ||
bashInteractive | ||
sqlite-interactive | ||
# NodeJS | ||
nodejs_22 | ||
corepack_22 | ||
]; | ||
makeDevShell = system: pkgs: { | ||
default = pkgs.mkShell { | ||
nativeBuildInputs = (deps pkgs) ++ (with pkgs; [ | ||
gitMinimal | ||
|
||
nodejs-18_x | ||
]; | ||
# sqlite3 module | ||
sqlite-interactive.dev | ||
]); | ||
shellHook = '' | ||
export PATH=$PWD/node_modules/.bin:$PATH | ||
''; | ||
}; | ||
}); | ||
}; | ||
in | ||
{ | ||
devShells = b.mapAttrs (makeDevShell) nixpkgs.legacyPackages; | ||
}; | ||
} |
Oops, something went wrong.