forked from CorentinTh/it-tools
-
Notifications
You must be signed in to change notification settings - Fork 101
Expand file tree
/
Copy pathflake.nix
More file actions
40 lines (38 loc) · 1.13 KB
/
flake.nix
File metadata and controls
40 lines (38 loc) · 1.13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
};
outputs = { nixpkgs, ... }:
let
eachSystem = f:
nixpkgs.lib.genAttrs nixpkgs.lib.systems.flakeExposed (system: f nixpkgs.legacyPackages.${system});
in
{
devShells = eachSystem (pkgs:
let
playwright-browsers = pkgs.playwright-driver.browsers.override {
withFirefox = true;
withWebkit = true;
withFfmpeg = false;
};
in
{
default = pkgs.mkShell {
packages = [
pkgs.nodejs_22
pkgs.pnpm
pkgs.nodePackages.typescript
pkgs.nodePackages.typescript-language-server
playwright-browsers
pkgs.playwright-test
];
shellHook = ''
export PLAYWRIGHT_NODEJS_PATH="${pkgs.nodejs_22}/bin/node";
export PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD=1
export PLAYWRIGHT_BROWSERS_PATH="${playwright-browsers}"
export PLAYWRIGHT_HOST_PLATFORM_OVERRIDE="ubuntu-24.04"
'';
};
});
};
}