-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathshell.nix
More file actions
59 lines (58 loc) · 1.38 KB
/
shell.nix
File metadata and controls
59 lines (58 loc) · 1.38 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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
let
pkgs = import <nixpkgs> { };
in
pkgs.mkShell {
packages = with pkgs; [
# corepack
# Add AppImage dependencies
xdg-utils
fuse
appimage-run
# appimagekit
jdk
# rust tools
rustup
cargo
# node stuff
nodejs_22
corepack_22
typeshare
];
nativeBuildInputs =
with pkgs;
[
# Rust toolchain
rustc
cargo
rustup
pkg-config
# java
jdk
]
# Brings in most of our GTK stuff for Linux
++ lib.optionals stdenv.hostPlatform.isLinux [ wrapGAppsHook4 ];
buildInputs =
with pkgs;
[
openssl
# Add these dependencies for bundling
xdg-utils # Make sure it's here too for visibility
]
++ lib.optionals stdenv.hostPlatform.isLinux [
# Required for most applications
glib-networking
webkitgtk_4_1
# AppImage dependencies
squashfsTools
]
++ lib.optionals stdenv.hostPlatform.isDarwin [
darwin.apple_sdk.frameworks.WebKit
];
# Add this shellHook to ensure XDG-related environment variables are set
shellHook = ''
rustup default 1.85.0
rustup component add rust-src
export PATH=/home/$(whoami)/.cargo/bin:$PATH
export XDG_DATA_DIRS=${pkgs.gsettings-desktop-schemas}/share/gsettings-schemas/${pkgs.gsettings-desktop-schemas.name}:${pkgs.gtk3}/share/gsettings-schemas/${pkgs.gtk3.name}:$XDG_DATA_DIRS
'';
}