-
Notifications
You must be signed in to change notification settings - Fork 1
/
home.nix
141 lines (127 loc) · 3.18 KB
/
home.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
{ pkgs, config, inputs, ... }:
{
home.sessionVariables = {
EDITOR = "nvim";
TIG_EDITOR = "nvim";
DIRENV_LOG_FORMAT = "";
OVERCOMMIT_COLOR = 0;
};
home.packages = with pkgs; [
asciinema
asciinema-agg
android-tools
bat
cargo
clojure
fd
fx
go
htop
imagemagick
jdk
jq
lazygit
leiningen
lsd
lua51Packages.luarocks-nix
nodejs_22
(yarn.override { nodejs = nodejs_22; })
pass
postgresql_16
selene
silver-searcher
ripgrep
tig
ueberzug
unstable.ast-grep
unstable.gh
unstable.git-absorb
unstable.gnupg
unstable.neovim
unstable.nixpkgs-fmt
(unstable.nerdfonts.override { fonts = [ "Hasklig" ]; })
wezterm
];
programs.home-manager.enable = true;
programs.direnv.enable = true;
programs.starship.enable = true;
programs.zsh = {
enable = true;
autocd = true;
history.ignoreSpace = true;
antidote = {
enable = true;
plugins = [
"zsh-users/zsh-completions kind:fpath"
"zsh-users/zsh-autosuggestions kind:defer"
"zdharma-continuum/fast-syntax-highlighting kind:defer"
# OMZ
"getantidote/use-omz" # handle OMZ dependencies
"ohmyzsh/ohmyzsh path:lib" # load OMZ's library
"ohmyzsh/ohmyzsh path:plugins/git"
"ohmyzsh/ohmyzsh path:plugins/dirhistory"
];
};
shellAliases = {
v = "nvim";
vim = "nvim";
ll = "lsd -l";
};
};
programs.git = {
enable = true;
userName = "David Mejorado";
userEmail = "[email protected]";
aliases = {
current-branch = "rev-parse --abbrev-ref HEAD";
default-branch = "!git rev-parse --abbrev-ref origin/HEAD | awk -F/ '{print $2}'";
fresh = "!git switch $(git default-branch) && git pull origin $(git default-branch) && git fetch";
pushc = "!git push origin $(git current-branch)";
pullc = "!git pull origin $(git current-branch)";
amend-date = ''!LC_ALL=C GIT_COMMITTER_DATE="$(date)" git commit -n --amend --no-edit --date "$(date)"'';
};
extraConfig = {
init.defaultBranch = "main";
rebase.autosquash = true;
fetch.writeCommitGraph = true;
push.autoSetupRemote = true;
commit.gpgsign = true;
user.signingkey = "86C60D761EB5F758";
delta.side-by-side = true;
delta.line-numbers = false;
};
delta.enable = true;
lfs.enable = true;
};
programs.tmux = {
enable = true;
keyMode = "vi";
extraConfig = ''set -ag terminal-overrides ",xterm*:Tc"'';
plugins = [
pkgs.tmuxPlugins.sensible
pkgs.tmuxPlugins.vim-tmux-navigator
pkgs.tmuxPlugins.yank
{
plugin = pkgs.tmuxPlugins.dracula;
extraConfig = ''
set -g @dracula-show-left-icon session
set -g @dracula-show-flags true
set -g @dracula-military-time true
set -g @dracula-plugins "time"
'';
}
];
};
programs.zellij = {
enable = true;
settings = {
theme = "catppuccin-frappe";
};
};
services.gpg-agent = {
enable = true;
defaultCacheTtl = 28800;
enableSshSupport = true;
pinentryPackage = pkgs.pinentry_mac;
};
}