-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdev.nix
55 lines (51 loc) · 1.47 KB
/
dev.nix
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
# To learn more about how to use Nix to configure your environment
# see: https://developers.google.com/idx/guides/customize-idx-env
{ pkgs, ... }: {
# Which nixpkgs channel to use.
channel = "stable-23.11"; # or "unstable"
# Use https://search.nixos.org/packages to find packages
packages = [
pkgs.nodejs_20
pkgs.corepack_20
];
env = {};
idx = {
# Search for the extensions you want on https://open-vsx.org/ and use "publisher.id"
extensions = [
"ms-vscode.vscode-js-profile-flame"
"vitest.explorer"
"yzhang.markdown-all-in-one"
"unifiedjs.vscode-mdx"
"stylelint.vscode-stylelint"
"pflannery.vscode-versionlens"
];
# Enable previews
previews = {
enable = true;
previews = [
# {
# # Example: run "npm run dev" with PORT set to IDX's defined port for previews,
# # and show it in IDX's web preview panel
# command = ["npm" "run" "dev"];
# manager = "web";
# id = "web";
# env = {
# # Environment variables to set for your server
# PORT = "$PORT";
# };
# }
];
};
# Workspace lifecycle hooks
workspace = {
# Runs when a workspace is first created
onCreate = {
npm-install = "pnpm install";
};
onStart = {
# Example: start a background task to watch and re-build backend code
# watch-backend = "npm run watch-backend";
};
};
};
}