-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmy-packages.nix
390 lines (342 loc) · 11.4 KB
/
my-packages.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
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
# Author: Viacheslav Lotsmanov
# License: MIT https://raw.githubusercontent.com/unclechu/nixos-config/master/LICENSE
args@{ pkgs, lib, config, systemConfig ? config, ... }:
let
sources = import nix/sources.nix;
inherit (import ./constants.nix) wenzelUserName;
nix-utils = pkgs.callPackage sources.nix-utils {};
inherit (nix-utils) wrapExecutable;
unstable = let
pkgs-unstable = import <nixos-unstable> {};
in {
inherit (pkgs-unstable.python3Packages) yt-dlp;
inherit (pkgs-unstable) freetube;
};
# *** apps ***
wenzels-bash = pkgs.callPackage apps/wenzels-bash.nix {};
tmux-config = pkgs.callPackage sources.tmuxrc {};
xlib-keys-hack = pkgs.callPackage sources.xlib-keys-hack {};
gnome-screenshot = pkgs.callPackage apps/gnome-screenshot.nix {};
unclechu-i3-status = pkgs.callPackage sources.unclechu-i3-status {};
gpaste-gui = pkgs.callPackage sources.gpaste-gui {
# “gpaste-gui” is built against NixOS 24.11 but this NixOS config is made
# for NixOS 24.05 (24.11 is broken for me at the moment, can’t update yet).
# There were breaking changes, like this “pkgs.gnome3.gpaste” as moved to
# top-level “gpaste”, so this fixes this incompatibility.
gpaste = pkgs.gnome3.gpaste;
};
vims = import ./vims.nix {
inherit pkgs lib;
bashEnvFile = "${wenzels-bash.dir}/.bash_aliases";
};
terminal-emulators = import ./terminal-emulators.nix { inherit pkgs lib; };
wenzels-xlib-keys-hack = pkgs.callPackage apps/wenzels-xlib-keys-hack {};
wenzels-keyboard-script = pkgs.callPackage scripts/wenzels-keyboard {};
wenzels-xbindkeys = pkgs.callPackage apps/wenzels-xbindkeys.nix {};
firefox = pkgs.callPackage apps/firefox.nix {};
nheko = pkgs.callPackage apps/nheko {};
hell = pkgs.callPackage apps/hell.nix {};
midi-trigger = pkgs.callPackage sources.MIDI-Trigger {
src = sources.MIDI-Trigger;
};
pspg = pkgs.callPackage apps/pspg.nix {};
polybar = pkgs.callPackage gui/polybar/polybar.nix {};
run-polybar = pkgs.callPackage gui/polybar/run-polybar.nix { inherit polybar; };
# *** scripts ***
autolock = pkgs.callPackage scripts/autolock.nix {};
cursor-to-display = pkgs.callPackage "${sources.i3rc}/nix/apps/cursor-to-display.nix" {};
invert-window-colors = pkgs.callPackage "${sources.i3rc}/nix/apps/invert-window-colors-nim.nix" {
inherit (pkgs) nim;
};
hsc2hs-pipe = wenzels-bash.hsc2hs-pipe;
timer = wenzels-bash.timer;
dzen-box = pkgs.callPackage scripts/dzen-box {};
screen-backlight = pkgs.callPackage scripts/screen-backlight.nix {};
locktop = pkgs.callPackage scripts/locktop.nix {};
pamng = pkgs.callPackage scripts/pamng.nix {};
pa-add-mono-sink = pkgs.callPackage scripts/pa-add-mono-sink.nix {};
autostart-setup = pkgs.callPackage scripts/autostart-setup.nix { inherit systemConfig; };
input-setup = pkgs.callPackage scripts/input-setup.nix {};
picom = pkgs.callPackage scripts/picom.nix {};
genpass = pkgs.callPackage scripts/genpass.nix {};
pointers = pkgs.callPackage scripts/pointers.nix {};
pulseaudio-share-server = pkgs.callPackage scripts/pulseaudio-share-server.nix {};
rt-audio = pkgs.callPackage scripts/rt-audio {};
screen-saver = pkgs.callPackage scripts/screen-saver {};
render-kicad-schematic-pdf-to-png = pkgs.callPackage scripts/render-kicad-schematic-pdf-to-png {};
clunky-toml-json-converter = pkgs.callPackage apps/clunky-toml-json-converter {};
in
{
my-apps = {
inherit
autostart-setup input-setup
cursor-to-display invert-window-colors gpaste-gui pamng screen-backlight
;
inherit (wenzels-bash) wenzels-bash;
};
configuration = {
imports = [
vims.configuration
terminal-emulators.configuration
];
environment.shells = [
pkgs.bash
pkgs.dash
pkgs.zsh
wenzels-bash.wenzels-bash
];
environment.systemPackages = [
# shell stuff
pkgs.wget pkgs.curl pkgs.ripgrep pkgs.dash pkgs.newt
pkgs.killall pkgs.lsof pkgs.inetutils pkgs.acl
pkgs.inotify-tools
pkgs.bindfs
pkgs.skim pkgs.fzf # fuzzy search
pkgs.eza
pkgs.tree
pkgs.bat
pkgs.lf
pkgs.silver-searcher
pkgs.zip pkgs.unzip pkgs.p7zip
pkgs.parallel
pkgs.entr
pkgs.file
pkgs.socat
pkgs.pandoc
tmux-config.tmuxsh
pspg
# Fix file names extracted from a Windows ZIP archive with cyrillic chars:
# unzip archive.zip
# convmv --notest -f iso8859-1 -t cp850 *
# convmv --notest -f cp866 -t utf8 *
# TODO: Maybe make a more universal script out of this.
pkgs.convmv
# dealing with json/yaml/toml from shell
pkgs.jq
pkgs.jo # json creator. see https://github.com/jpmens/jo
pkgs.gron # json to greppable format converter. see https://github.com/tomnomnom/gron
pkgs.remarshal # Convert between TOML, YAML and JSON
clunky-toml-json-converter # Convert between TOML and JSON
pkgs.pv # monitoring progress of data transfer through a pipeline
# nix stuff
pkgs.nix-index
pkgs.niv
pkgs.direnv
# system stuff
pkgs.htop
pkgs.dbus pkgs.upower
pkgs.parted pkgs.gparted
pkgs.pciutils
pkgs.wally-cli
pkgs.sshfs
pkgs.curlftpfs
pkgs.jmtpfs
pkgs.glib # for “gio”
pkgs.usbutils
pkgs.dnsutils
pkgs.lm_sensors
# programming languages
## haskell
pkgs.haskellPackages.ghc
pkgs.hlint
(pkgs.haskell.lib.justStaticExecutables pkgs.haskellPackages.hoogle)
hell
## perls
pkgs.perl pkgs.rakudo
## c
pkgs.gcc
## bash
pkgs.shellcheck
## etc
pkgs.gnumake
# file managers
pkgs.mc
pkgs.xfce.thunar
# audio
pkgs.qastools # GUI tools for ALSA configuration
pkgs.pavucontrol
pkgs.pulsemixer
pkgs.jack2
(pkgs.jack-example-tools.overrideAttrs (old: {
patches = (old.patches or []) ++ [
# Big fix for “jack_lsp” “--server” argument buffer overflow.
# Track the bug fixing progress here:
# https://github.com/jackaudio/jack-example-tools/issues/88
(pkgs.fetchpatch {
name = "jack_lsp-fix-jack-server-argument-buffer-overflow.patch";
url = "https://github.com/jackaudio/jack-example-tools/pull/89/commits/62aeea4c432c8f91b14888c4dc4c310ef762a865.patch";
hash = "sha256-TbgJdwsxo9K6wTQ46yHLYDbIJkINNARlb332qC8TWlM=";
})
];
}))
pkgs.jack_capture
pkgs.qjackctl
pkgs.patchage
pkgs.patchance
pkgs.audacious
pkgs.audacity
pkgs.ardour
pkgs.guitarix
pkgs.normalize
pkgs.sonic-visualiser
pkgs.zita-njbridge # JACK in/out bridge over UDP
pkgs.espeak
pkgs.flac # FLAC compression/decompression utility
pkgs.ffmpeg-normalize # audio normalization utility built on top of FFMPEG
pkgs.lame # MP3 encoder utility
# lv2 plugins
pkgs.calf
pkgs.artyFX
pkgs.drumgizmo
pkgs.eq10q
pkgs.fmsynth
pkgs.fomp
pkgs.infamousPlugins
pkgs.mda_lv2
pkgs.metersLv2
pkgs.mod-distortion
pkgs.noise-repellent
pkgs.rkrlv2
pkgs.sorcer
pkgs.speech-denoiser
pkgs.swh_lv2
pkgs.x42-plugins
pkgs.zam-plugins
midi-trigger
pkgs.CHOWTapeModel
pkgs.lilv # Provides useful tools like “lv2ls”
pkgs.jalv
pkgs.lsp-plugins
# graphics
pkgs.glxinfo # debugging opengl system setup
pkgs.libva-utils
pkgs.picom # x11/xorg compositing manager
pkgs.arandr # simple gui for display/xinerama configuration
pkgs.autorandr # automatic display configuration based on connected devices
pkgs.feh # image viewer (for setting desktop background)
pkgs.gimp # raster graphics editor
pkgs.inkscape # vector graphics editor
pkgs.optipng # optimize/compress *.png files
pkgs.graphviz # draw block-schemes from *.dot files
pkgs.imagemagick # “convert" for image processing from command-line
pkgs.ghostscript # converting .pdf into .png using ImageMagick
# video
pkgs.vlc
pkgs.smplayer
pkgs.mplayer
(pkgs.wrapMpv (pkgs.mpv-unwrapped.override { jackaudioSupport = true; }) {})
pkgs.mpvc
pkgs.ffmpeg-full
unstable.yt-dlp
# electronics
pkgs.kicad # schematics designing tool
# documents
pkgs.libreoffice-fresh
# desktop environment
pkgs.tk
pkgs.xorg.xev
pkgs.gmrun pkgs.dmenu pkgs.dzen2 pkgs.rofi
pkgs.xsel pkgs.xdotool pkgs.numlockx pkgs.xkb-switch
pkgs.xbindkeys
xlib-keys-hack
pkgs.place-cursor-at
pkgs.xautolock
pkgs.termite
pkgs.networkmanagerapplet
pkgs.gnome3.gnome-system-monitor
pkgs.gnome3.gnome-power-manager
pkgs.gnome3.gnome-calendar
pkgs.gnome3.gnome-calculator
pkgs.gnome3.eog # Image viewer
pkgs.gnome3.evince # Document (e.g. PDF) viwer
pkgs.d-spy # DBus inspector GUI (a C rewrite of “dfeet”)
pkgs.obs-studio
pkgs.kitty # TODO: configure
pkgs.piper # GUI for “ratbagd” service
pkgs.libnotify
polybar
run-polybar
# camera
pkgs.v4l-utils
pkgs.gnome3.cheese
# instant messaging/communication
(pkgs.callPackage apps/psi-plus.nix {})
pkgs.hexchat
pkgs.weechat
nheko
(pkgs.callPackage apps/dino.nix {})
pkgs.thunderbird
# clipboard management
pkgs.gnome3.gpaste
gpaste-gui
pkgs.clipmenu
# screenshots
gnome-screenshot
pkgs.scrot # An alternative to "gnome-screenshot" (just in case, usually I don't use it)
pkgs.shutter # Advanced screenshot taking&editing tool with GUI (written in Perl)
# web browsers
firefox
pkgs.chromium
unstable.freetube
# task management
pkgs.hledger pkgs.hledger-ui pkgs.hledger-web
# FIXME: In the 23.11 nixpkgs it is marked a broken.
# pkgs.taskell # Kanban board TUI written in Haskell
# version control
pkgs.git
# encryption
pkgs.gnupg
pkgs.pass
pkgs.monkeysphere
pkgs.keepassxc
# antivirus
pkgs.clamav
pkgs.lynis
pkgs.vulnix
# extra utils
pkgs.mat2
];
programs.tmux = {
enable = true;
extraConfig = tmux-config.config;
};
# Some plugins for Thunar file manager.
# Thunar itself is added to “environment.systemPackages”.
programs.thunar.plugins = [
pkgs.xfce.thunar-archive-plugin
pkgs.xfce.thunar-volman
];
services.xserver.windowManager.i3.extraPackages = [
pkgs.i3status
pkgs.i3lock
unclechu-i3-status
pkgs.gnome3.adwaita-icon-theme
];
users.users.${wenzelUserName}.packages = [
wenzels-bash.wenzels-bash
wenzels-xlib-keys-hack
wenzels-xbindkeys
wenzels-keyboard-script
input-setup
autostart-setup
autolock
cursor-to-display
# FIXME: Fails to compile after migrated to 23.11
# invert-window-colors
dzen-box
locktop
pamng
screen-backlight
hsc2hs-pipe
timer
genpass
pa-add-mono-sink
picom.run-picom
picom.no-picom
pulseaudio-share-server
rt-audio
screen-saver
render-kicad-schematic-pdf-to-png
] ++ builtins.filter lib.isDerivation (builtins.attrValues pointers);
};
}