-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfiguration.nix
247 lines (218 loc) · 6.33 KB
/
configuration.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
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
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
{ pkgs, ... }: {
system.stateVersion = 5;
# services.nix-daemon.enable = true;
programs.zsh.enable = true;
nix = {
package = pkgs.nix;
settings.trusted-users = [ "root" "anton" ];
};
fonts = {
packages = with pkgs; [
anonymousPro
nerd-fonts.fira-code
nerd-fonts.hack
nerd-fonts.jetbrains-mono
];
};
users.users.anton = {
name = "anton";
home = "/Users/anton";
};
#environment.pathsToLink = ["/share/qemu"]; # workaround https://discourse.nixos.org/t/out-share-linked-with-nix-profile-install-but-not-otherwise/27561
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.anton = { pkgs, ... }: {
home.stateVersion = "22.05";
home.sessionPath = [ "$HOME/.local/bin" "$HOME/.cargo/bin" ];
home.packages = with pkgs; [
cachix jq
tig gh
mc xz htop
wget curl
# graphviz
# rclone restic
# podman qemu
# (pkgs.callPackage ./vfkit.nix { })
python3 poetry ruff pyright
# #openscad #broken
gmailctl
# openssl
# (pkgs.callPackage ./ossl.nix { })
# llvm clang libiconv
# cmake
# nodejs
# hugo
# # Rust: https://github.com/nix-community/fenix
# (fenix.stable.withComponents [
# "cargo"
# "clippy"
# "rust-src"
# "rustc"
# "rustfmt"
# ])
# rust-analyzer
];
manual.manpages.enable = false;
manual.html.enable = false;
manual.json.enable = false;
programs.vscode = {
enable = false;
package = pkgs.vscodium;
extensions = (with pkgs.vscode-extensions; [
eamodio.gitlens
gruntfuggly.todo-tree
tamasfe.even-better-toml
stkb.rewrap
# nix
bbenoist.nix b4dm4n.vscode-nixpkgs-fmt
arrterian.nix-env-selector
# rust
rust-lang.rust-analyzer
vadimcn.vscode-lldb # is broken https://github.com/NixOS/nixpkgs/issues/148946
]) ++ pkgs.vscode-utils.extensionsFromVscodeMarketplace [
{
# adzero.vscode-sievehighlight
publisher = "adzero";
name = "vscode-sievehighlight";
version = "1.0.6";
sha256 = "sha256-8Ompv792eI2kIH+5+KPL9jAf88xsMGQewHEQwi8BhoQ=";
}
{
# EmilijanMB.sublime-text-4-theme
# https://marketplace.visualstudio.com/items?itemName=EmilijanMB.sublime-text-4-theme
publisher = "EmilijanMB";
name = "sublime-text-4-theme";
version = "1.1.2";
sha256 = "sha256-I1UO8IEq7HKxgH0gVyUN4cdBOouTvsyMgBjPIYQ6E5U=";
}
{
# bierner.github-markdown-preview
publisher = "bierner";
name = "github-markdown-preview";
version = "0.3.0";
sha256 = "sha256-7pbl5OgvJ6S0mtZWsEyUzlg+lkUhdq3rkCCpLsvTm4g=";
}
{
# bierner.markdown-preview-github-styles
publisher = "bierner";
name = "markdown-preview-github-styles";
version = "2.0.3";
sha256 = "sha256-yuF6TJSv0V2OvkBwqwAQKRcHCAXNL+NW8Q3s+dMFnLY=";
}
{
# bierner.markdown-footnotes
publisher = "bierner";
name = "markdown-footnotes";
version = "0.1.1";
sha256 = "sha256-h/Iyk8CKFr0M5ULXbEbjFsqplnlN7F+ZvnUTy1An5t4=";
}
{
# bierner.markdown-checkbox
publisher = "bierner";
name = "markdown-checkbox";
version = "0.4.0";
sha256 = "sha256-AoPcdN/67WOzarnF+GIx/nans38Jan8Z5D0StBWIbkk=";
}
{
# bierner.markdown-mermaid
publisher = "bierner";
name = "markdown-mermaid";
version = "1.21.0";
sha256 = "sha256-YyOdCegetz/K4Sev3njxgsDWjpI6MG2LsV6MFyCioMc=";
}
];
userSettings = {
"update.mode" = "none";
"window.titleBarStyle" = "custom";
"workbench.colorTheme" = "Sublime Text 4 Theme";
"editor.fontFamily" = "FiraCode Nerd Font, Hack Nerd Font, Anonymous Pro";
"editor.fontSize" = 13;
"editor.fontLigatures" = true;
"editor.rulers" = [80 120];
"rust-analyzer.trace.server" = "messages";
"editor.formatOnSave" = true;
"markdown-preview-github-styles.colorTheme" = "light";
"editor.minimap.enabled" = false;
"lldb.verboseLogging" = true;
"lldb.launch.terminal" = "external";
};
};
programs.git = {
enable = true;
lfs.enable = true;
userName = "Anton Arapov";
userEmail = "[email protected]";
ignores = [
".DS_Store"
];
signing = {
key = "134C02E813889057DA2F3FDBEDDD4C5DAA149BBE";
signByDefault = true;
gpgPath = "/usr/local/bin/gpg";
};
extraConfig = {
init.defaultBranch = "master";
core = {
editor = "vim";
whitespace = "trailing-space,space-before-tab";
};
url = {
"[email protected]:" = {
insteadOf = "https://github.com/";
};
};
url = { # makes rust's cargo happy again
"https://github.com/rust-lang/crates.io-index" = {
insteadOf = "https://github.com/rust-lang/crates.io-index";
};
};
pull = {
ff = "only";
};
};
};
programs.neovim = {
enable = true;
vimAlias = true;
plugins = with pkgs.vimPlugins; [
vim-nix vim-jsonnet
];
};
programs.starship = {
enable = true;
enableZshIntegration = true;
# Configuration written to ~/.config/starship.toml
settings = {
add_newline = false;
character = {
success_symbol = "[➜](bold green)";
error_symbol = "[➜](bold red)";
};
};
};
programs.zsh = {
enable = true;
autosuggestion.enable = true;
sessionVariables = {
EDITOR = "vim";
};
};
programs.ssh = {
enable = true;
matchBlocks = {
"github.com" = {
hostname = "github.com";
user = "git";
identityFile = [ "~/.ssh/id_rsa" ];
identitiesOnly = true;
};
"github.openssl.org" = {
hostname = "github.openssl.org";
user = "git";
identityFile = [ "~/.ssh/id_rsa" ];
identitiesOnly = true;
};
};
};
};
}