-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathhome.nix
More file actions
183 lines (159 loc) · 4.11 KB
/
home.nix
File metadata and controls
183 lines (159 loc) · 4.11 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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
{ config, pkgs, inputs, ... }:
{
home.username = "chksky";
home.homeDirectory = "/home/chksky";
home.stateVersion = "25.11";
nixpkgs.config = {
allowUnfree = true;
};
home.packages = [
pkgs.htop
pkgs.btop
pkgs.neofetch
pkgs.deno
# archives
pkgs.zip
pkgs.xz
pkgs.unzip
pkgs.gnumake
# JSON processing
pkgs.jq
# `sensors` command
pkgs.lm_sensors
pkgs.wmctrl
pkgs.obsidian
pkgs.libsecret
pkgs.polkit
pkgs.xdg-utils
pkgs.shared-mime-info
];
home.file.".config/obsidian/.keep".text = "";
xdg.desktopEntries.obsidian = {
name = "Obsidian";
exec = "obsidian --no-sandbox %u";
icon = "obsidian";
type = "Application";
categories = [ "Office" "TextEditor" ];
mimeType = [ "x-scheme-handler/obsidian" ];
};
services = {
copyq.enable = true;
};
programs = {
ripgrep.enable = true;
helix = {
enable = true;
defaultEditor = true;
settings = {
theme = "ayu_dark";
};
};
starship = {
enable = true;
enableFishIntegration = true;
};
atuin = {
enable = true;
settings = {
enter_accept = false;
};
};
git = {
enable = true;
userName = "Dima Ochkivskyi";
userEmail = "github@chksky.com";
difftastic.enable = true;
};
};
programs.zsh = {
enable = true;
enableCompletion = true;
autosuggestion = {
enable = true;
};
initExtra = ''
# fnm
FNM_PATH="/home/chksky/.local/share/fnm"
if [ -d "$FNM_PATH" ]; then
export PATH="$FNM_PATH:$PATH"
eval "`fnm env`"
fi
# ghcup-env
[ -f "/home/chksky/.ghcup/env" ] && . "/home/chksky/.ghcup/env"
# rust toolchain
. "$HOME/.cargo/env"
# pnpm
export PNPM_HOME="/home/chksky/.local/share/pnpm"
case ":$PATH:" in
*":$PNPM_HOME:"*) ;;
*) export PATH="$PNPM_HOME:$PATH" ;;
esac
# pnpm end
'';
shellAliases = {
hms = "home-manager -f ~/.dotfiles/home.nix switch";
f = "wmctrl -r :ACTIVE: -b add,fullscreen";
uf = "wmctrl -r :ACTIVE: -b remove,fullscreen";
pn = "pnpm";
pnx = "pnpx";
copy = "copyq copy";
mkcd = "mkdir -p $1 && cd $1";
};
oh-my-zsh = {
enable = true;
plugins = [ "git" "docker" ];
theme = "robbyrussell";
};
plugins = [
{
name = "you-should-use";
src = pkgs.fetchFromGitHub {
owner = "MichaelAquilina";
repo = "zsh-you-should-use";
rev = "1.9.0";
sha256 = "1kb11rqhmsnv3939prb9f00c1giqy3200sjnhh7cxcfjcncq0y7v";
};
}
{
name = "zsh-syntax-highlighting";
src = pkgs.fetchFromGitHub {
owner = "zsh-users";
repo = "zsh-syntax-highlighting";
rev = "0.8.0";
sha256 = "1yl8zdip1z9inp280sfa5byjbf2vqh2iazsycar987khjsi5d5w8";
};
}
];
};
home.file = {
".config/zed".source = config.lib.file.mkOutOfStoreSymlink "${config.home.homeDirectory}/.dotfiles/zed";
".config/ghostty".source = config.lib.file.mkOutOfStoreSymlink "${config.home.homeDirectory}/.dotfiles/ghostty";
# # You can also set the file content immediately.
# ".gradle/gradle.properties".text = ''
# org.gradle.console=verbose
# org.gradle.daemon.idletimeout=3600000
# '';
};
# Home Manager can also manage your environment variables through
# 'home.sessionVariables'. These will be explicitly sourced when using a
# shell provided by Home Manager. If you don't want to manage your shell
# through Home Manager then you have to manually source 'hm-session-vars.sh'
# located at either
#
# ~/.nix-profile/etc/profile.d/hm-session-vars.sh
#
# or
#
# ~/.local/state/nix/profiles/profile/etc/profile.d/hm-session-vars.sh
#
# or
#
# /etc/profiles/per-user/chksky/etc/profile.d/hm-session-vars.sh
dconf.settings = {
"org/gnome/desktop/input-sources" = {
xkb-options = ["ctrl:nocaps"];
};
};
# Let Home Manager install and manage itself.
programs.home-manager.enable = true;
}