Compare commits

...

1022 commits

Author SHA1 Message Date
ab54d7b6ef WIP: home: vim: notify
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-08-07 10:22:22 +00:00
3ef71cc165 home: wm: i3bar: add 'quarks' bluetooth block
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-08-06 20:13:08 +02:00
424bb2e7b9 modules: services: woodpecker: simplify path
I'm not sure why it was written that way to begin with.
2023-08-06 20:13:08 +02:00
405965dc72 pkgs: add explicit 'meta.mainProgram'
Since upstream has decided to deprecate the implied value when using
`lib.getExe` (see [1]), we should set it explicitly.

[1]: https://github.com/NixOS/nixpkgs/pull/246386
2023-08-06 20:13:08 +02:00
761393205c pkgs: re-order 'meta'
This is (mostly) alphetically sorted.
2023-08-06 20:13:08 +02:00
1b960c7449 ci: use 'backend' tag 2023-08-06 20:13:08 +02:00
0cf6cfe39b pkgs: remove woodpecker
Now that v1.0.0 is on nixpkgs, no need for my custom packages.
2023-08-06 20:13:08 +02:00
7b6779f2b5 modules: services: woodpecker: default packages
Now that v1.0.0 is on nixpkgs, no need for my custom packages.
2023-08-06 20:13:08 +02:00
68118e8f93 flake: bump inputs 2023-08-06 20:13:08 +02:00
45c3b82606 modules: services: nginx-sso: use writeShellScript 2023-08-06 20:13:08 +02:00
58a94bdf1b pkgs: remove woodpecker-plugin-git
I have now upstreamed the package, so let's remove it.
2023-08-06 20:13:08 +02:00
868a9aa212 home: mail: accounts: use 'rbw-pass'
It should be more robust than the one based on bitwarden-cli.
2023-08-06 20:13:08 +02:00
9f7472222c treewide: use 'lib.getExe' when possible
Don't use it in wireguard to keep it consistent, as only half the
commands could use it.
2023-08-06 20:13:08 +02:00
8f818b8611 pkgs: add rbw-pass
This is honestly almost overkill, as the script doesn't really have any
logic in it, but it's good to have a common base with the bitwarden-cli
one.
2023-08-06 20:13:08 +02:00
2dfc788ed4 home: wm: i3: add 'rofi-rbw' mapping 2023-08-06 20:13:08 +02:00
4a9a46547e machine: aramis: home: set 'bitwarden.pinentry' 2023-08-06 20:13:08 +02:00
36c0590ae5 home: add bitwarden 2023-08-06 20:13:08 +02:00
e5a1105c59 home: wm: i3: remove 'pamixer'
This was left-over from the first version of my volume mappings.
2023-08-06 20:13:08 +02:00
850b9f792f flake: bump inputs 2023-08-06 20:13:08 +02:00
f363ae71a5 hosts: nixos: porthos: boot: use '/dev/disk/by-id'
Somehow `/dev/sda` and `/dev/sdb` switched around, so use a more stable
path.
2023-08-06 20:13:08 +02:00
ae8d8d75fd flake: bump inputs
Update `fail2ban` to accomodate for RFC-42 migration.
2023-08-06 20:13:08 +02:00
65de9c5a0e home: zsh: add fallback for all mappings
All checks were successful
ci/woodpecker/push/check Pipeline was successful
I don't actually think any of these are _necessary_, but you never know.
2023-07-21 10:20:08 +00:00
fc6b221ba1 overlays: make overlay import automatic
Some checks failed
ci/woodpecker/push/check Pipeline failed
Don't rely on nixpkgs' lib to make it easier to just `import` the
directory.
2023-07-20 22:17:16 +01:00
47533f119e modules: services: monitoring: add 'secretKeyFile'
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-07-17 10:59:58 +00:00
ae13ab0c86 nixos: porthos: secrets: add grafana secret-key
The secret will be used in the next commit.
2023-07-17 10:59:58 +00:00
caa8357db8 home: nixpkgs: define 'GITHUB_API_TOKEN'
All checks were successful
ci/woodpecker/push/check Pipeline was successful
Turns out the nixpkgs scripts are not consistent in which environment
variable they expect to be defined...
2023-07-17 09:57:24 +00:00
493636decb hosts: nixos: porthos: services: add tandoor
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-07-17 09:55:33 +00:00
5ff0b62af8 hosts: nixos: porthos: secrets: add tandoor 2023-07-17 11:53:49 +02:00
4bb1387376 modules: services: add tandoor-recipes
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-07-15 15:46:04 +02:00
5741421604 modules: services: nextcloud: enable 'notify_push' 2023-07-15 15:46:04 +02:00
c037d3844a modules: services: nextcloud: configure redis
All checks were successful
ci/woodpecker/push/check Pipeline was successful
I keep having some file-locking issues, and heard that using redis might
help alleviate those errant locks.

It's also necessary to use the `notify_push` app.
2023-07-15 14:01:14 +01:00
758e88e620 overlays: remove 'calibre-dedrm'
All checks were successful
ci/woodpecker/push/check Pipeline was successful
Turns out I didn't need it.

This reverts commit 89168324e7.
2023-07-05 20:14:52 +01:00
6100a092af hosts: homes: cloudtop: disable 'git' package
All checks were successful
ci/woodpecker/push/check Pipeline was successful
A recent update modified `ssh_config`, and nixpkgs' version of OpenSSH
does not know how to deal with those options.

The `git` package does not make use of the system-provided SSH client,
and errors-out.

Given that those patches are never going to be upstreamed, just override
the `git` package, and use the system-provided one instead...
2023-07-05 16:56:57 +00:00
737e9df202 home: tmux: make status left longer
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-07-04 14:58:03 +00:00
f73be2fc4e flake: bump inputs
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-06-30 22:44:25 +02:00
cbbe371ace hosts: nixos: aramis: home: remove 'quasselclient'
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-06-28 21:41:52 +01:00
b8f8c7cfa7 home: wm: i3bar: fix 'battery' block on empty
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-06-27 20:14:23 +01:00
950940e3c7 hosts: nixos: aramis: home: enable calibre
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-06-24 17:02:01 +01:00
ac725bd5e4 home: add calibre
Ideally I will extend this module to handle the plugin (and
dependencies) natively.
2023-06-24 17:02:01 +01:00
89168324e7 overlays: add 'calibre-dedrm' 2023-06-24 17:02:01 +01:00
3e5fbfeb7a modules: services: nextcloud: bump to 27
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-06-23 12:03:13 +02:00
b6ccc7a18d overlays: remove 'nix-serve-ng-initLibStore'
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-06-23 09:11:15 +00:00
0bc31619c8 flake: bump inputs 2023-06-23 09:10:24 +00:00
cecb7d9bb4 home: vim: lspconfig: configure diagnostics once
All checks were successful
ci/woodpecker/push/check Pipeline was successful
There's no need to configure it on each LSP attach, this is wasted work
and could change options that have since been changed.
2023-06-22 15:35:32 +00:00
2f03d92dd9 modules: services: woodpecker: use docker module
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-06-11 16:25:23 +01:00
e44dd4c6ea modules: services: drone: use docker module 2023-06-11 16:25:23 +01:00
df9b060947 modules: system: podman: check for docker conflict 2023-06-11 16:23:31 +01:00
73fdd4622b modules: system: add docker 2023-06-11 16:17:42 +01:00
8fcb7f42a6 home: wm: i3: assert name of 'i3status-rs' bar
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-06-11 16:13:42 +01:00
e5c27d7aa8 home: firefox: fix settings sort
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-06-10 22:57:19 +01:00
a846d19b1a flake: bump inputs
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-06-10 20:47:20 +01:00
1807b8b88c hosts: nixos: porthos: services: disable vikunja
All checks were successful
ci/woodpecker/push/check Pipeline was successful
I don't use it.
2023-06-10 13:35:02 +01:00
5aa136f796 modules: system: podman: fix removed option
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-06-08 15:43:46 +00:00
18c9458cfa modules: system: users: add 'docker' group 2023-06-08 15:43:46 +00:00
c0995929c4 modules: system: podman: add weekly purge 2023-06-08 15:43:46 +00:00
d69dbf8d62 home: wm: i3bar: fix 'net' block on non-wireless
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-06-06 20:01:07 +01:00
5d570dbf1e modules: programs: steam: use writeShellScriptBin
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-06-03 13:40:44 +01:00
4f6f483851 modules: programs: steam: simplify wrapper 2023-06-03 13:40:44 +01:00
39a512bc0a home: vim: unset 'splitkeep'
All checks were successful
ci/woodpecker/push/check Pipeline was successful
Turns out I do _not_ like this behaviour when it messes with the cursor
position.

If they had an option that kept my cursor correctly positioned, and only
then tried to move the buffer to keep it steady, I'd try it.

This reverts commit 4feee73b8e.
2023-06-01 11:34:09 +00:00
5de4ee93d5 home: vim: use smarter diagnostics float display
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-05-31 14:00:32 +00:00
7c4e0e31bc hosts: nixos: porthos: boot: remove 'grub.version'
Some checks failed
ci/woodpecker/push/check Pipeline failed
2023-05-28 14:49:40 +02:00
908c2e39b3 flake: bump inputs
Some checks failed
ci/woodpecker/push/check Pipeline failed
2023-05-28 14:44:18 +02:00
0321889d50 home: wm: i3bar: add 'muon' bluetooth block
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-05-27 09:24:09 +01:00
e26672494c flake: dev-shells: use 'mkShellNoCC'
All checks were successful
ci/woodpecker/push/check Pipeline was successful
We don't need compilers.
2023-05-25 09:31:41 +00:00
b80053d786 home: add nixpkgs
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-05-22 15:53:59 +00:00
b570cf227c home: secrets: add github
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-05-17 11:13:26 +00:00
c0a80c2503 home: secrets: fix public keys list 2023-05-17 11:12:18 +00:00
e68ae26609 hosts: nixos: porthos: services: enable vikunja
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-05-13 21:18:57 +02:00
30d01972b2 hosts: nixos: porthos: secrets: add vikunja 2023-05-13 21:18:57 +02:00
175a8acde2 modules: services: add vikunja 2023-05-13 21:18:57 +02:00
685c571018 modules: services: nginx: add 'socket' option 2023-05-13 21:18:57 +02:00
41df5c01ad home: vim: ftdetect: add kconfig
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-05-12 12:31:07 +00:00
153b6a43cc home: vim: ftdetect: add kbuild 2023-05-12 12:28:06 +00:00
527a85bf11 home: vim: ftdetect: switch to lua
It looks like `vim.filetype.add` is smarter about "local.am".

For some reason opening an *empty* Tiger file results in a backtrace...
2023-05-12 12:26:56 +00:00
f3e888dadc home: add secrets
All checks were successful
ci/woodpecker/push/check Pipeline was successful
Now that my module has been merged upstream!

Not that I have anything to use it with for now...
2023-05-12 11:03:49 +00:00
d60e26c617 flake: bump inputs
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-05-12 10:10:33 +00:00
c8019f84bb pkgs: wifi-qr: fix icon handling
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-05-09 20:33:05 +01:00
01059616bf home: vim: don't use 'nixpkgs-fmt' with 'nil'
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-05-09 20:25:15 +01:00
8a78ce8520 home: vim: null-ls: add 'buildifier' configuration 2023-05-09 20:23:07 +01:00
102dc4cc76 home: vim: null-ls: restrict POSIX to bare 'sh' 2023-05-09 20:22:12 +01:00
0b64c9caa7 hosts: nixos: porthos: services: disable grocy
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-05-08 19:01:11 +02:00
574634b64e modules: services: blog: use 302 redirection
All checks were successful
ci/woodpecker/push/check Pipeline was successful
That way the browser doesn't cache it, in case I do end up using that
domain after all.
2023-05-07 15:20:14 +01:00
b86d963a92 flake: checks: enable 'stylua'
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-05-07 13:36:10 +01:00
78c524e19d project: add stylua configuration 2023-05-07 13:36:10 +01:00
1e9f6fe957 home: vim: fix lua formatting 2023-05-07 13:36:10 +01:00
c2d231d3f1 home: vim: use actual lua files
Since most of the settings are actually just lua in a VimL file.
2023-05-07 13:36:10 +01:00
9530864b10 home: vim: fastfold: use lua configuration 2023-05-07 13:36:10 +01:00
e599a97e45 home: vim: abbreviations: use lua
This makes it less repetitive.
2023-05-07 13:36:10 +01:00
39c2e5db8c home: vim: signtoggle: use lua autocommands
A nice next step would be to use actual lua callbacks instead of the
VimL command.
2023-05-07 13:36:10 +01:00
dba8836381 home: vim: numbertoggle: use lua autocommands
A nice next step would be to use actual lua callbacks instead of the
VimL command.
2023-05-07 13:36:10 +01:00
36b0c67832 home: vim: completion: use lua settings 2023-05-07 13:33:02 +01:00
68b9c3b9b1 home: vim: remove 'vim-pandoc'
The tree-sitter code-block high-lighting is built-in and works better,
and I don't use any of the other features.
2023-05-07 13:04:37 +01:00
d8896a66c8 hosts: home: cloudtop: systemd session variable
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-05-05 09:05:51 +00:00
a1dd0bb792 modules: services: matrix: remove 'with lib'
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-05-04 12:19:31 +00:00
46d9e5c829 home: vim: lspconfig: add 'nil'
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-05-04 09:27:19 +00:00
b9d6115994 pkgs: unbound-zones-adblock: remove unused 'rec' 2023-05-04 09:27:19 +00:00
beeafe5e33 home: nix: remove unused 'options' 2023-05-04 09:27:19 +00:00
c19baeb19d modules: system: podman: remove unused 'options' 2023-05-04 09:27:19 +00:00
62d9359eb7 modules: services: matrix: clean-up formatting 2023-05-04 09:27:19 +00:00
85e31e5d6c home: zsh: remove unused 'with pkgs' 2023-05-04 09:27:19 +00:00
185b1d5490 flake: remove unused 'lib' 2023-05-04 09:27:19 +00:00
9f3a8ac2bd home: zsh: extract aliases
All checks were successful
ci/woodpecker/push/check Pipeline was successful
It doesn't (yet?) support nushell, if I ever end up switching to it.
2023-05-03 20:20:07 +01:00
4feee73b8e home: vim: set 'splitkeep' 2023-05-03 20:02:34 +01:00
c117d1caed flake: checks: enable 'deadnix'
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-05-03 15:22:52 +00:00
284b83b896 lib: ip: check range in 'nthInRange4' 2023-05-03 15:22:52 +00:00
dac80373a1 flake: nixos: use consistent module formatting 2023-05-03 15:15:31 +00:00
a868088cc9 treewide: rename unused overlay arguments
Now that `nix flake check` doesn't complain about it anymore, try to be
consistent about using that feature.
2023-05-03 15:15:31 +00:00
2f3989bba1 modules: services: wireguard: simplify 2023-05-03 15:15:31 +00:00
49b2cb9781 modules: secrets: remove unused 'options' 2023-05-03 15:15:31 +00:00
bd6b7ca9e2 flake: do not use explicit inputs
This ends up being more annoying than useful most of the time anyway...

Make a note that we can't just eta-reduce the outputs, due to a nix
limitation on flake outputs (see [1]).

[1]: https://github.com/NixOS/nix/issues/4384
2023-05-03 15:15:31 +00:00
debdadbd1a pkgs: woodpecker: do not name unused argument 2023-05-03 15:15:31 +00:00
6f3594b694 pkgs: woodpecker: remove unused inputs 2023-05-03 15:15:31 +00:00
0e7c0531f5 lib: string: remove unused 'let' block 2023-05-03 15:02:44 +00:00
7bd2e1504d home: vim: lua: lsp: customize diagnostics display 2023-05-03 15:02:44 +00:00
b0f054b1e6 home: vim: configure 'lsp_lines' 2023-05-03 15:02:44 +00:00
6cdbd6bb29 home: vim: lua: lsp: remove diagnostic on hover 2023-05-03 15:02:44 +00:00
29daa555a3 hosts: nixos: porthos: services: disable quassel
I don't use it anymore.
2023-05-03 15:02:44 +00:00
fadb8e96fc modules: system: nix: add 'cache.selfHosted' 2023-05-03 15:02:44 +00:00
20d19ed128 modules: system: nix: rename 'inputs' options 2023-05-03 15:02:44 +00:00
93bc5cbd01 nixos: porthos: services: enable nix-serve
Unfortunately, the priority cannot be changed and defaults to being
higher (by using a lower integer) than the NixOS cache...
2023-05-03 15:02:44 +00:00
f7df17686f nixos: porthos: secrets: add 'nix-serve/cache-key' 2023-05-03 15:02:44 +00:00
455a4e5431 modules: services: add nix-serve 2023-05-03 15:02:44 +00:00
872f045740 overlays: add 'nix-serve-ng-initLibStore' 2023-05-03 15:02:44 +00:00
fe8481292d flake: bump inputs 2023-05-03 15:02:44 +00:00
d9e115a876 modules: services: woodpecker: adapt gitea URL 2023-05-03 15:02:44 +00:00
e4e44dd8fa home: atuin: enable command line preview 2023-05-03 15:02:44 +00:00
f41fd5d42e home: atuin: use 'skim' engine 2023-05-03 15:02:44 +00:00
5a9e62d556 home: add atuin
I really like the `fzf` history widget, and this is not as good UI-wise.

However I like the fact that this uses a DB:

* It is more reliable when the history file gets messed up [1]
* It allows syncing between different hosts (not sure if I will use it)
* It adds more context to the search
    * The current directory
    * The shell _session_, I can *either* search all sessions or
      restrict to just the current one

I will be looking into whether or not I can hack something together to
get a better UI (by using `fzf` of course).
2023-05-03 15:02:44 +00:00
0ab56888bd home: extract dircolors configuration 2023-05-03 15:02:44 +00:00
1d7b9b99db home: extract fzf configuration 2023-05-03 15:02:44 +00:00
d8c841333b modules: services: gitea: migrate settings
Most of the settings are now RFC-42 compliant.
2023-05-03 15:02:44 +00:00
f47ac78370 flake: bump inputs 2023-05-03 15:02:44 +00:00
c82361f9e4 home: git: ignore neovim 'exrc' configuration 2023-05-03 15:02:44 +00:00
5c372cfa95 home: vim: use 'exrc'
Remove the home-grown "solution" that I had stolen from school (and
never used...) for project-local configuration.

Since [1], it is okay to use the built-in vim option for this, since it
only asks for user-input before trusting a file.

Since [2] they even support lua files!

[1]: https://github.com/neovim/neovim/pull/20956
[2]: https://github.com/neovim/neovim/pull/21436
2023-05-03 15:02:44 +00:00
0f385abf3c pkgs: fix 'nativeBuildInputs' usage 2023-05-03 15:02:44 +00:00
ce4e163193 pkgs: add wifi-qr 2023-05-03 15:02:44 +00:00
e9f07e67dc home: vim: add diff line matching
All checks were successful
ci/woodpecker/push/check Pipeline was successful
This should bring more readable diffs. See [1].

[1]: https://github.com/neovim/neovim/pull/14537
2023-04-19 08:36:40 +00:00
2375f88e56 home: vim: use patience diff
This brings it in line with my `git` configuration.
2023-04-19 08:34:39 +00:00
d424aaa4a1 templates: c++-meson: add '.envrc'
All checks were successful
ci/woodpecker/push/check Pipeline was successful
This was ignored when I added the initial commit.
2023-04-18 22:06:57 +01:00
638f4a7774 modules: system: boot: rename 'tmp' options
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-04-17 21:25:15 +02:00
f935126312 flake: bump inputs 2023-04-17 21:22:10 +02:00
af470f507b bootstrap: remove GPG setup step
All checks were successful
ci/woodpecker/push/check Pipeline was successful
I don't use `git-crypt` anymore, this is no longer useful.
2023-04-17 09:28:23 +00:00
98c77cb258 bootstrap: rename agenix SSH key
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-04-17 08:18:27 +00:00
04d92a29e3 hosts: nixos: aramis: secrets: rename SSH key 2023-04-17 08:18:27 +00:00
7cebaa3751 modules: secrets: move wireguard keys
This is a bit special, as some of the keys do not belong to NixOS hosts,
so store those in the module itself, and into host-specific directories
for the keys that are NixOS hosts.
2023-04-17 08:18:27 +00:00
ed745602a1 modules: secrets: move non-existent key workaround
Since this configuration was only there to accommodate `aramis`, make it
be host-specific instead, and rely on the default value otherwise.
2023-04-16 19:44:02 +01:00
6079485b50 modules: secrets: move host-specific secrets 2023-04-16 19:44:02 +01:00
57008bcb7c hosts: nixos: add host-specific secrets module
This is the same logic as the common module, but for secrets that don't
need to be shared to different hosts.
2023-04-16 19:44:02 +01:00
34a3f9a0d6 modules: secrets: centralize agenix keys
If I intend on splitting the keys depending on which host needs to have
access to it, I should have a singular spot to manage the keys.
2023-04-16 19:44:02 +01:00
68bf36c45c modules: secrets: wireguard: remove unused file
The peer definitions have been inlined into the Wireguard module a long
time ago.
2023-04-13 17:05:52 +00:00
54e9303319 modules: secrets: use diff-friendly formatting
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-04-13 15:55:34 +00:00
04f23976ee modules: services: woodpecker: remove unused env
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-04-13 15:24:34 +00:00
94141d53b8 modules: services: woodpecker: remove 'TODO' 2023-04-13 15:17:16 +00:00
81f930168a flake: use 'defaultSystems'
All checks were successful
ci/woodpecker/push/check Pipeline was successful
Instead of writing a list which amounts to the same thing.
2023-04-12 16:50:51 +00:00
520d799124 pkgs: remove 'pnpm-lock-export'
All checks were successful
ci/woodpecker/push/check Pipeline was successful
I don't need it now that it has been upstreamed.
2023-04-11 22:31:29 +01:00
0e5d40ef7f pkgs: woodpecker: add 'pnpm-lock-export' to update
Now that it has been upstreamed.
2023-04-11 22:31:28 +01:00
e8a31ddf8c flake: bump inputs 2023-04-11 22:31:28 +01:00
7b117d76de overlays: remove 'i3status-rust-main-program'
It is now included upstream.
2023-04-11 22:31:28 +01:00
b3e75b374a templates: add c++-meson 2023-04-11 22:31:28 +01:00
9822b034f7 templates: add c++-cmake 2023-04-11 16:26:56 +00:00
951770904f flake: add templates 2023-04-04 15:53:09 +00:00
9781ef06b0 home: wm: i3bar: better 'battery' formats
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-04-01 20:29:23 +01:00
72dd9ae834 home: wm: i3bar: fix 'battery' block icon 2023-04-01 20:29:23 +01:00
f15b3aa23d modules: services: woodpecker: allow setuid
All checks were successful
ci/woodpecker/push/check Pipeline was successful
I need it to be able to use `ssh-agent`, for some of my workflows.
2023-04-01 21:06:50 +02:00
0da267664c ci: remove Drone CI
All checks were successful
ci/woodpecker/push/check Pipeline was successful
2023-04-01 17:14:13 +01:00
85f7a34d85 ci: add Woodpecker CI workflow
Some checks failed
continuous-integration/drone/push Build is failing
ci/woodpecker/push/check Pipeline was successful
2023-04-01 16:41:00 +01:00
29a1a48d19 pkgs: matrix-notifier: 0.2.0 -> 0.3.0
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-01 16:33:43 +01:00
ffd3fb06bd pkgs: refactor 'sha256' -> 'hash' 2023-04-01 16:33:26 +01:00
eb34d23e3d pkgs: lohr: 0.4.0 -> 0.4.2 2023-04-01 16:32:04 +01:00
8fa1b9952c pkgs: remove 'rofi-bluetooth'
Now that it is packaged upstream.
2023-04-01 16:22:08 +01:00
f9ddcff5ee home: wm: i3: use upstream 'rofi-bluetooth' 2023-04-01 16:20:55 +01:00
f6d648a87a pkgs: remove 'nolimips'
Now that the CRI packages it.
2023-04-01 16:20:29 +01:00
1221d5b6d6 pkgs: remove 'havm'
Now that the CRI packages it.
2023-04-01 16:20:05 +01:00
7a5842f03a modules: services: matrix: remove obsolete comment
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-01 15:56:48 +01:00
8d0f29bd33 hosts: nixos: porthos: services: set matrix secret 2023-04-01 15:56:48 +01:00
d20e921e33 modules: secrets: fix 'matrix/secret' 2023-04-01 15:56:48 +01:00
f306cc84bc hosts: nixos: porthos: services: enable woodpecker 2023-04-01 15:56:48 +01:00
7e06f75a5d modules: secrets: add woodpecker 2023-04-01 15:56:48 +01:00
020a32b9e8 modules: services: add woodpecker 2023-04-01 15:56:48 +01:00
c857e4cd2e pkgs: add woodpecker-plugin-git 2023-04-01 15:56:48 +01:00
ea57ad3eb8 pkgs: add woodpecker
This is just the same version as upstream, but following the `next`
version.
2023-04-01 15:56:48 +01:00
281d98b295 pkgs: add pnpm-lock-export 2023-04-01 13:05:47 +02:00
5d9524dbdf modules: services: blog: better blog redirection 2023-04-01 13:05:47 +02:00
9c36d65d80 home: ssh: use canonical gitea subdomain 2023-04-01 13:05:47 +02:00
b3b115ee1d home: ssh: use canonical gitea subdomain 2023-04-01 13:05:47 +02:00
84bed03367 home: ssh: remove old 'work' host
I don't work there anymore.
2023-04-01 13:05:47 +02:00
a22fe4e636 modules: services: nextcloud: bump to 26 2023-04-01 13:05:47 +02:00
04681f6ee4 flake: bump inputs 2023-04-01 13:05:47 +02:00
f0a93f878b home: nix: add 'NIX_PATH' handling
All checks were successful
continuous-integration/drone/push Build is passing
Still waiting for the actual home-manager module option to be added [1].

In the meantime, just do it by hand.

[1]: https://github.com/nix-community/home-manager/pull/2677
2023-03-30 09:58:46 +00:00
b909f43269 modules: services: nginx: sort settings
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-28 15:31:05 +00:00
cae174b0f7 modules: services: nginx: all recommended settings 2023-03-28 15:31:05 +00:00
838cdeb598 flake: bump inputs 2023-03-28 15:31:05 +00:00
642e58fc22 modules: hardware: bluetooth: use 'wireplumber'
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-28 15:31:05 +00:00
4183f7b963 hosts: homes: cloudtop: enable GPG
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-27 08:25:22 +00:00
76edeffdc7 home: pager: use XDG-compliant history location
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-27 08:23:58 +00:00
83268e7db6 home: xdg: force more XDG compliance
Thanks a to a nifty tool [1] I learnt about some more easy fixes.

[1]: https://github.com/b3nj5m1n/xdg-ninja
2023-03-27 08:23:58 +00:00
677a5a11e6 pkgs: unified-hosts-lists: 3.11.16 -> 3.12.15
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-24 20:46:48 +00:00
ddc296138c home: move gpg-specific alias to 'gpg'
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-24 11:18:08 +00:00
ad0c99c6f0 modules: services: paperless: fix postgres order
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-23 12:16:40 +00:00
1751704ab3 modules: system: podman: remove unused arguments
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-22 10:46:10 +00:00
e799318a36 modules: hardware: firmware: remove unused 'pkgs' 2023-03-22 10:45:13 +00:00
359456fbc1 home: terminal: alacritty: remove unused arguments 2023-03-22 10:45:13 +00:00
1ff03e35f8 flake: dev-shells: remove unused arguments 2023-03-22 10:45:13 +00:00
31601f58b4 flake: remove unused arguments 2023-03-22 10:45:13 +00:00
d8c19d45ad flake: checks: remove unused arguments 2023-03-22 10:45:13 +00:00
606cd8cf84 hosts: homes: add work cloudtop
All checks were successful
continuous-integration/drone/push Build is passing
The unfortunate host naming can't be fixed at the moment...
2023-03-20 09:52:05 +00:00
a046569743 flake: home-manager: use a more modular design
This means I can easily add new hosts now.
2023-03-20 09:52:05 +00:00
2fb3d0f9cf machines: rename to 'hosts/nixos'
This will be more consistent in the future if I want to introduce darwin
or home-manager configurations.
2023-03-20 09:52:05 +00:00
eac628963a flake: dev-shell: use exposed pre-commit script 2023-03-20 09:52:05 +00:00
8657774d06 flake: checks: use 'pre-commit-hooks' module 2023-03-20 09:52:05 +00:00
c82eb57070 flake: home-manager: convert to 'flake-parts' 2023-03-20 09:52:05 +00:00
59b1ab59dd flake: apps: convert to 'flake-parts' 2023-03-20 09:52:05 +00:00
ec036255ad flake: packages: convert to 'flake-parts' 2023-03-20 09:52:05 +00:00
2b969f7726 flake: dev-shells: convert to 'flake-parts' 2023-03-20 09:52:05 +00:00
e1e6c39bf1 flake: checks: convert to 'flake-parts' 2023-03-20 09:52:05 +00:00
730e4abf17 flake: nixos: convert to 'flake-parts' 2023-03-20 09:52:05 +00:00
b2f3bc955c flake: lib: convert to 'flake-parts' 2023-03-20 09:52:05 +00:00
a88c99b9d7 flake: overlays: convert to 'flake-parts' 2023-03-20 09:52:05 +00:00
922c6e75ca flake: use 'flake-parts' 2023-03-20 09:52:05 +00:00
92438d35f6 flake: add 'flake-parts' 2023-03-20 09:52:05 +00:00
84fc1601c5 home: vim: 'unimpaired' mappings for formatting
All checks were successful
continuous-integration/drone/push Build is passing
I'll migrate to calling the lua API directly if they stop expecting a
non-nil argument.
2023-03-20 09:52:05 +00:00
0241bfc781 home: vim: modify 'unimpaired' quickfix mappings 2023-03-20 09:52:05 +00:00
a166a5b18b overlays: remove 'i3status-rust_0_22'
All checks were successful
continuous-integration/drone/push Build is passing
We don't need it now that we updated to the latest version.

This reverts commit 704df6b826.
2023-03-19 22:28:45 +00:00
2e9704ed1d home: wm: i3: simplify status command
The v0.30.0 of `i3status-rs` automatically resolves a configuration name
inside its configuration directory, making this much simpler.
2023-03-19 22:28:27 +00:00
7cec58e215 home: wm: i3bar: update to v0.30.X
This should be equivalent to the previous version's configuration, since
v0.30.0 introduced a lot of breaking changes.
2023-03-19 22:28:27 +00:00
176ff5d6e3 flake: bump inputs
Since the v0.30.0 version of `i3status-rust` was a breaking change, pin
the package to v0.22.0 for now.
2023-03-19 22:26:25 +00:00
887428fddd home: wm: i3: use explicit path to bar config
The v0.30.0 is about to change how it resolves the configuration path,
so make it explicit to ease the transition and simplify later.
2023-03-19 22:25:53 +00:00
704df6b826 overlays: add 'i3status-rust_0_22'
The latest version introduced breaking changes, let's do that correctly.
2023-03-19 22:21:53 +00:00
c3c2a34606 overlays: add 'i3status-rust-main-program' 2023-03-19 21:34:15 +00:00
70e235dfcc modules: secrets: drone: modify gitea domain
Since I've changed the official subdomain for my forge, let's update it.
2023-03-16 21:40:06 +01:00
89256fa29b pkgs: use 'git.*' subdomain
Since I've changed the official subdomain for my forge, let's update it.
2023-03-16 21:40:06 +01:00
e50b259a70 modules: services: gitea: change domain to 'git.*'
Because cool URLs don't change [1], setup a re-directed for it.

[1]: https://www.w3.org/Provider/Style/URI.html
2023-03-16 21:33:22 +01:00
b3d90be8b1 modules: services: nginx: add 'redirect' option 2023-03-16 21:33:22 +01:00
05973b93ff home: tmux: add 'enabledPassthrough'
All checks were successful
continuous-integration/drone/push Build is passing
This is useful for cases where some programs expect to be able to use
the tmux passthrough escape sequences by using the tmux passthrough
sequence.

One such example is `osc52` script I packaged.

However I like the idea of tmux filtering all escape sequences by
default, so it's not enabled by default.
2023-03-16 16:42:55 +00:00
20341a3129 refactor: 'with lib.my' -> 'with lib' 2023-03-16 16:42:55 +00:00
464ed92b00 pkgs: diff-flake: re-order functions
All checks were successful
continuous-integration/drone/push Build is passing
This makes it more consistent across the entire file, and follows
alphabetical order (home -> host -> shell).
2023-03-16 11:49:26 +00:00
08740e846f pkgs: diff-flake: quote attribute names
Since we don't know if they contain `.` or other characters that might
need quoting.
2023-03-16 11:49:26 +00:00
66fc43f7ca pkgs: diff-flake: 0.3.1 -> 0.4.0
Add home-manager configurations.
2023-03-16 11:49:26 +00:00
a5da0abbc2 pkgs: diff-flake: 0.3.0 -> 0.3.1
Add all dev shells when run without any arguments.
2023-03-16 11:49:26 +00:00
b56674728f pkgs: diff-flake: 0.2.0 -> 0.3.0
Change how `devShells` is handled: always build for the current system
and instead query for the name of the shell that should be built.
2023-03-16 11:49:26 +00:00
5413bf7fbb flake: bump inputs
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-15 18:20:23 +00:00
1db162f272 home: zsh: add ctrl-{left,right} mapping 2023-03-15 18:20:23 +00:00
4f0a619921 home: zsh: add ctrl-delete mapping 2023-03-15 18:20:23 +00:00
69fbc438c1 home: zsh: add {home,end} mapping 2023-03-15 18:20:23 +00:00
c48f6261be home: zsh: add page{up,down} mapping 2023-03-15 18:20:23 +00:00
af8f3c814b home: zsh: ensure application mode with zle 2023-03-15 18:20:23 +00:00
2431f8f207 home: zsh: refactor 'terminfo' handling
This is more readable.

Largely inspired by oh-my-zsh.
2023-03-15 18:20:23 +00:00
bc5fa3f679 home: zsh: use terminfo for mappings 2023-03-15 17:40:05 +00:00
ca047bfe97 home: zsh: use more readable option names
All checks were successful
continuous-integration/drone/push Build is passing
Since they ignore underscores, this is more readable.
2023-03-15 15:20:14 +00:00
eb75fcfa3f home: zsh: enable slash squeezing 2023-03-15 15:20:14 +00:00
e8c52175b6 home: git: add 'root' alias
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-14 17:00:45 +00:00
623bb6c893 home: vim: git: attach to untracked buffers
All checks were successful
continuous-integration/drone/push Build is passing
Turns outs it looks way more discreet now. Whether that's due to an
update to the plug-in or my changing colorscheme, I don't know.
2023-03-13 15:49:07 +00:00
1e4d4650e2 home: zsh: disable shared history
All checks were successful
continuous-integration/drone/push Build is passing
I know I just activated it, but I can't get used to it...

I would like to have a mixture of it:
* Be able to search across *all* shell histories when using Ctrl-r.
* Only go up/down my session's shell history when using Ctrl-n/Ctrl-p.

Enabling shared history gets me the first one, but means I can't limit
my up/down history to just the one session.

Disabling shared history means that I can't search across all shell
histories, but keeps my up/down history tidier.

All-in-all I like the second one better.
2023-03-11 22:01:47 +00:00
fafbb93ea9 modules: home: use named 'nixosModules'
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-11 20:44:04 +00:00
2d2f729138 home: zsh: don't hard-code '$XDG_CONFIG_HOME'
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-08 14:42:54 +00:00
f1a7e9fd93 home: zsh: enable history sharing 2023-03-08 14:37:37 +00:00
7dd221cc93 home: zsh: expire duplicates first 2023-03-08 14:37:37 +00:00
ff66361f65 home: zsh: use extended history
I have `inc_append_history_time` set, so I should use extended
history...
2023-03-08 14:37:37 +00:00
4786552e8c home: zsh: verify history expansion
This helps when I absentmindedly run a command which contains
exclamation points.
2023-03-08 14:37:37 +00:00
9f6a9d2ff7 flake: move ouputs logic to 'flake/' 2023-03-08 14:37:37 +00:00
d14f96d584 flake: move 'nixosConfigurations' to 'flake/'
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-07 12:34:46 +00:00
40fff4b13a flake: move 'packages' to 'flake/' 2023-03-07 12:34:46 +00:00
1ae2bca445 flake: move 'devShells' to 'flake/' 2023-03-07 12:34:46 +00:00
fc02519c4f flake: move 'checks' to 'flake/' 2023-03-07 12:34:46 +00:00
90d1d81983 flake: move 'lib' to 'flake/' 2023-03-07 12:34:46 +00:00
819ce1a320 flake: move 'overlays' to 'flake/' 2023-03-07 12:34:46 +00:00
b9083244ed flake: add 'aarch64-darwin' again
I don't get an error during `nix flake check` anymore.

This reverts commit 8a556585af.
2023-03-07 12:34:46 +00:00
04734c8bd2 pkgs: ff2mpv-go: fix 'vendorHash' 2023-03-07 12:34:46 +00:00
8b7198d7e7 direnv: always use 'nix-direnv' 2023-03-07 11:51:04 +00:00
453e5a925a direnv: remove nix evaluation hack 2023-03-07 11:50:34 +00:00
3ed5e40285 flake: expose 'lib' attribute
This exposes `lib.my` which contains my custom library functions, as
well as the entirety of the nixpkgs library.
2023-03-07 11:05:07 +00:00
068faea1e2 home: zsh: extra-mappings: use single quotes
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-07 11:05:07 +00:00
41bd17e3ca home: vim: migrate to 'gruvbox-nvim'
I think this one will be more up-to-date with NeoVim evolutions, like
LSP semantic tokens.
2023-03-07 11:05:07 +00:00
a29deaa9bc home: vim: use 'lsp-formatting.nvim'
A few things that are different:
* Async by default.
* Takes care of the order of formatters, if I ever need to do that.
* Allows for easily disabling formatting (unfortunately this is global
  state, not buffer-local).
* Gets rid of the formatting pause when doing `:wq`.
2023-03-07 11:05:07 +00:00
3122db6536 home: vim: disable mouse integration 2023-03-07 11:05:07 +00:00
2a7e6197f5 flake: system-specific 'homeConfigurations' 2023-03-07 11:05:07 +00:00
4a6677b024 modules: system: nix: add 'linkInputs' option
All checks were successful
continuous-integration/drone/push Build is passing
Once again, mirroring the work done in the NixOS module.
2023-02-25 01:43:07 +00:00
ca1e2df1e9 home: nix: refactor module
This keeps it in line with the NixOS one.
2023-02-25 01:43:07 +00:00
58d03d5892 home: nix: add explanatory comment 2023-02-25 01:43:07 +00:00
8b9a01a0ef modules: system: nix: DRY inputs handling 2023-02-25 01:43:07 +00:00
3c6e8933a1 lib: attrs: add 'merge' 2023-02-25 01:43:07 +00:00
ae23f05a33 flake: bump inputs 2023-02-25 01:43:07 +00:00
54a6be70c8 modules: system: nix: simplify 'NIX_PATH'
Since we now have an explicit 'pkgs' link, we can just add the folder
with all linked inputs directly instead of adding them all manually.
2023-02-25 01:43:07 +00:00
a99954b12a modules: system: nix: add explicit 'pkgs' link 2023-02-25 01:43:07 +00:00
6eb87c21b7 modules: system: nix: use stable 'NIX_PATH'
All checks were successful
continuous-integration/drone/push Build is passing
Since the links are updated on system switch, NIX_PATH will
automatically point to the actual system version of the inputs at all
times
2023-02-23 21:03:22 +00:00
c1214547da modules: system: nix: add '/etc/nix/inputs' links 2023-02-23 20:58:05 +00:00
607d11bbad home: zsh: disable tmux auto-launch by default
All checks were successful
continuous-integration/drone/push Build is passing
2023-02-22 16:12:30 +00:00
06989facc2 machines: porthos: home: enable tmux auto-launch
I'm about to flip the default to always disabled, so enable it
explicitly.
2023-02-22 16:12:07 +00:00
55b828cba9 machines: porthos: add home configuration 2023-02-22 16:12:07 +00:00
34c13b077f home: zsh: refactor tmux auto-launch configuration
Introduce an actual option for this behaviour.
2023-02-22 16:11:18 +00:00
0bbf522c03 home: tmux: change 'use lib.my' to 'use libs' 2023-02-22 16:00:26 +00:00
737747f8f5 flake: add 'homeConfigurations.ambroisie'
All checks were successful
continuous-integration/drone/push Build is passing
2023-02-21 17:53:09 +00:00
ee6a735a2c home: add nix
This is basically the same thing as the NixOS module, except for
NIX_PATH handling [1].

[1]: https://github.com/nix-community/home-manager/pull/2677
2023-02-21 17:52:39 +00:00
3505b4d7f0 modules: services: sabnzbd: add fail2ban jail
All checks were successful
continuous-integration/drone/push Build is passing
2023-02-20 23:01:50 +01:00
86aa156fc0 home: tmux: fix 'hasGui' logic
All checks were successful
continuous-integration/drone/push Build is passing
Take advantage of this fix to make the code more extensible.
2023-02-20 11:19:20 +00:00
54f335d984 home: tmux: always use tmux-yank
This plugin does have some useful binds.

Since it still sends the OSC52 escape sequence when copying, I don't
have a problem with remote hosts.
2023-02-20 11:19:13 +00:00
9965c3846f pkgs: add osc52
All checks were successful
continuous-integration/drone/push Build is passing
2023-02-20 10:44:28 +00:00
2485a60d62 modules: services: calibre-web: add fail2ban jail
All checks were successful
continuous-integration/drone/push Build is passing
2023-02-20 09:04:50 +00:00
b9f6c5d534 modules: services: gitea: add fail2ban jail 2023-02-20 09:04:50 +00:00
d647830911 modules: services: order imports 2023-02-20 09:04:50 +00:00
b2ce0530dc machines: porthos: services: enable fail2ban 2023-02-20 09:04:50 +00:00
13aa8abfaf modules: services: add fail2ban 2023-02-20 09:04:50 +00:00
4e59c0d551 home: firefox: tridactyl: fix DDG mapping
All checks were successful
continuous-integration/drone/push Build is passing
They broke, once again...
2023-02-19 14:16:13 +00:00
75396c4c4c home: firefox: tridactyl: use more private editor
All checks were successful
continuous-integration/drone/push Build is passing
2023-02-19 14:12:09 +00:00
5d42f55fc6 home: firefox: tridactyl: fix 'editorcmd'
All checks were successful
continuous-integration/drone/push Build is passing
Turns out `alacritty` is smarter than `termit` with its handling of
command execution (i.e: actually expects multiple arguments to exec(2)).

So account for the difference in the module.
2023-02-19 14:02:57 +00:00
e667c042cb home: zsh: add colorful aliases
All checks were successful
continuous-integration/drone/push Build is passing
2023-02-19 12:25:40 +00:00
225e8f236e home: vim: ftdetect: add direnv
All checks were successful
continuous-integration/drone/push Build is passing
2023-02-17 15:53:55 +00:00
2ec9aae6b7 home: pager: remove colored man pages
All checks were successful
continuous-integration/drone/push Build is passing
It seems to have broken at some point, and I didn't notice.

Might as well remove it since I do not care for it.
2023-02-16 12:06:28 +00:00
a61a602bd2 home: ssh: include local-only config file
Useful for configuration options that should remain secret.
2023-02-15 15:02:15 +00:00
b4d050a5f8 machines: aramis: home: migrate to 'alacritty'
All checks were successful
continuous-integration/drone/push Build is passing
2023-02-12 17:35:14 +00:00
e8a46ae248 home: firefox: tridactyl: use preferred terminal
Thankfully, alacritty and termite both use the same command line
arguments for this. If I ever want to use another one, I might have to
make the logic a bit more robust.
2023-02-12 17:33:45 +00:00
4f883b0198 home: terminal: remove DPI workaround
And instead change the font size to be *about* right.
2023-02-12 17:32:48 +00:00
f89e10fdca home: terminal: add alacritty 2023-02-12 16:57:54 +00:00
b6bbe5a01e home: firefox: tridactyl: move cursor in editor
This means that the cursor in vim will be in the same position as the
one in the input form.
2023-02-12 16:57:54 +00:00
d25922ef15 home: packages: remove 'termite.terminfo' 2023-02-12 16:46:18 +00:00
c1c3146311 home: zsh: always enable VTE integration 2023-02-12 16:43:55 +00:00
70f5e46860 home: tmux: fix OSC52 forwarding
All checks were successful
continuous-integration/drone/push Build is passing
I want neovim to be able to set my clipboard, and don't care for the
potential security issues of letting any program be able to do such a
thing.
2023-02-12 12:03:10 +00:00
2ffb8e6ee6 home: vim: add 'nvim-osc52'
All checks were successful
continuous-integration/drone/push Build is passing
I do get the message when copying into the clipboard while ssh-ing.

But trying to paste from my system clipboard shows that it did *not* get
copied. This seems to only happen inside tmux.

However tmux itself *does* copy to the clipboard correctly through OSC52.
2023-02-12 11:55:58 +00:00
fe73a304aa flake: bump inputs 2023-02-12 12:40:03 +01:00
e04fa74412 home: vim: lua: utils: add 'is_ssh'
All checks were successful
continuous-integration/drone/push Build is passing
2023-02-11 22:17:22 +00:00
5bce2fafde modules: system: nix: override '<nixpkgs>'
All checks were successful
continuous-integration/drone/push Build is passing
2023-02-11 11:04:10 +00:00
26bf4e3631 modules: system: nix: preprend to 'NIX_PATH'
Instead of appending to the default value.

This makes overriding some values that are defined as the default value easier.
2023-02-11 11:04:10 +00:00
8dcc59d481 flake: bump inputs
All checks were successful
continuous-integration/drone/push Build is passing
And migrate firefox extensions configuration to the profile-specific
format.
2023-02-08 22:02:40 +00:00
0a71548419 flake: bump inputs 2023-02-08 21:06:18 +00:00
2a26f65a51 flake: futils has renamed its branch to 'main' 2023-02-08 21:05:52 +00:00
699b6b8e33 home: zsh: include local-only config file
All checks were successful
continuous-integration/drone/push Build is passing
Useful for configuration options that should remain secret.
2023-02-08 14:44:23 +00:00
3a0fa3398d home: zsh: modify 'initExtra' inclusion style 2023-02-08 14:43:39 +00:00
938fb71f9c home: git: include local-only config file
Useful for configuration options that should remain secret.
2023-02-08 14:31:32 +00:00
5a07dda93b home: git: setup work identity
Now that I am at Google, gotta make sure I use the correct identity.
2023-02-08 14:24:05 +00:00
2b3fb4fa5a home: vim: use shorter tree-sitter alias 2023-02-08 14:03:23 +00:00
0e4a4df544 home: zsh: add usual aliases
I forgot to add them, since on NixOS they are defined at the system
level by default.
2023-02-08 10:36:10 +00:00
4971634115 home: vim: make it the default editor explicitly 2023-02-07 14:19:50 +00:00
6b4c01a242 modules: services: ssh-server: use 'settings' 2023-01-28 22:51:18 +01:00
0821334a0a flake: bump inputs 2023-01-28 22:51:18 +01:00
b4d745c50e home: vim: add 'cmp_luasnip'
I had forgotten to add it even though I configured it as a source...
2023-01-20 19:16:20 +00:00
19e42cdc26 home: vim: reorder snippet plugins 2023-01-20 19:15:31 +00:00
5f3299e383 home: vim: luasnip: use lazy-loading 2023-01-20 19:10:14 +00:00
c45b8c7618 machines: aramis: change timezone
I'm in London now :').
2023-01-17 01:11:53 +01:00
dc429b5491 machines: aramis: home: remove 'teams' 2023-01-14 20:12:51 +01:00
280593b9c0 flake: bump inputs 2023-01-14 20:11:10 +01:00
92e63eae25 home: firefox: remove 'https-everywhere'
It's been made redundant.
2023-01-14 20:10:56 +01:00
0ff4d2de01 flake: bump inputs 2023-01-04 12:39:30 +01:00
aeb3245327 modules: services: blog: GNU T.P. 2022-12-18 12:59:42 +01:00
c961bdbfc4 modules: services: transmission: remove MemoryHigh
The service does not actively try to reduce its memory usage, so to make
sure we do reach `MemoryMax` let's remove the `MemoryHigh`
configuration.
2022-12-16 21:43:49 +01:00
c6b3325269 profiles: printing: setup default paper size 2022-12-16 12:56:16 +01:00
0b7257cfb9 machines: aramis: use 'printing' profile 2022-12-16 12:56:16 +01:00
5f8ffe5af9 profiles: add printing 2022-12-16 12:56:16 +01:00
18f81a05eb home: mail: disable himalaya
I don't actually use it, should circle back to it in the future.
2022-12-16 12:56:16 +01:00
6913e0f896 flake: bump inputs
Some new options were needed for `himalaya`.
2022-12-16 12:55:01 +01:00
1e10c6630b modules: services: nginx: fix SSL renewal
See this issue [1].

[1]: https://github.com/go-acme/lego/issues/1772.
2022-11-29 17:19:24 +01:00
b85a98c377 modules: services: nextcloud: disable broken SSE
I don't use server-side encryption anyway.
2022-11-28 10:18:50 +01:00
072511a091 flake: bump inputs
And reduce the closure size of 'pre-commit-hooks.nix' by making it
follow my 'nixpkgs' input.
2022-11-28 10:17:37 +01:00
a73a05e0ac profiles: devices: enable gvfs 2022-11-23 11:23:54 +01:00
122eaf3a5c profiles: wm: enable 'udisks2' 2022-11-21 14:50:09 +01:00
1967c8ef79 modules: services: transmission: limit memory use 2022-11-20 13:15:58 +01:00
7ce0a4ad5c flake: bump inputs 2022-11-17 12:51:02 +01:00
16d4147321 home: vim: lspconfig: update deprecated call 2022-11-03 18:07:00 +01:00
236d48befb home: vim: lua: lsp: update for nvim 0.8
Two big changes:

* Making use of the lua API for creating autocmds.
* Using `client.supports_method`.
2022-11-03 18:07:00 +01:00
f6a00ec838 modules: services: paperless: require postgres 2022-11-03 18:06:36 +01:00
05be340b7e modules: services: nextcloud: bump to 25 2022-11-03 16:59:19 +01:00
30ce88f42f flake: bump inputs
And migrate to the new RFC42 grafana options.
2022-11-03 16:58:47 +01:00
3c3e56002f home: vim: add 'nix' ftplugin 2022-10-26 14:14:01 +02:00
e0b7103c8d home: wm: i3: add floating-related mappings 2022-10-04 11:40:44 +02:00
d0394bd149 flake: bump inputs 2022-09-30 08:59:27 +02:00
4c0c6a75b2 modules: system: packages: configure aliases
Disallow them by default, but make it configurable.
2022-09-30 08:59:27 +02:00
5e021e6436 all: remove package aliases 2022-09-30 08:59:27 +02:00
84217afd07 pkgs: remove 'psst'
It has been included in nixpkgs.
2022-09-30 08:59:27 +02:00
ad57052317 pkgs: unified-hosts-lists: 3.10.1 -> 3.11.16 2022-09-14 14:36:26 +02:00
aed2e8c581 flake: bump inputs 2022-09-14 13:41:07 +02:00
4216c654e7 home: vim: migrate to 'nvim-surround'
It's potentially more customizable, and integrates with tree-sitter. It
also allows for buffer/filetype specific pairs.
2022-09-02 09:56:20 +02:00
e1e5a7c900 flake: bump inputs 2022-09-02 09:49:35 +02:00
c05fafefe8 modules: services: gitea: migrate to 'settings' 2022-08-31 17:19:58 +02:00
6748b5b5e6 home: mail: accounts: use 'outlook' flavor 2022-08-31 17:16:44 +02:00
235ab4794e flake: bump inputs 2022-08-31 17:16:44 +02:00
3efba75169 home: gdb: fix auto-load safe path 2022-08-10 15:23:21 +02:00
48495851ba modules: services: grocy: fix SSL configuration 2022-07-28 18:29:10 +02:00
58971246e7 machines: porthos: services: enable grocy 2022-07-28 18:29:10 +02:00
2ba9c63f2e modules: services: add grocy 2022-07-28 18:29:10 +02:00
914b064f72 modules: services: paperless: fix DB dependency 2022-07-28 17:54:02 +02:00
cde010a5f2 flake: bump inputs 2022-07-12 13:48:25 +02:00
468fbdd69a home: xdg: do not set 'WGETRC'
I don't use it...
2022-07-11 14:11:43 +02:00
9f82981602 home: vim: add 'nvim-lspconfig'
For some reason I had not added it to my plug-in list, but it still
worked until I bumped my inputs.
2022-06-23 10:02:32 +02:00
3eb1dc086b lib: fix formatting 2022-06-22 16:06:58 +02:00
8a556585af flake: remove 'aarch64-darwin'
'pyopenssl' has been marked as broken on this sytem, so remove it from
my supported systems to avoid breaking 'nix flake check'.
2022-06-22 16:05:28 +02:00
c3706ff537 flake: bump inputs 2022-06-22 16:04:01 +02:00
7ab49dbeab pkgs: remove 'shellcheck' as a 'buildPhase'
I already verify those scripts with my pre-commit hook. And that way
avoid spurious build failures in case a (transitive) dependency is
broken.
2022-06-22 16:04:01 +02:00
9c80bc07b9 pkgs: add drone-rsync
A very simple wrapper script that I will migrate to, since 'drone-scp'
does not work for me anymore.
2022-06-20 14:34:37 +02:00
7e4e41a07f home: vim: add 'tiger' file-type configuration 2022-06-20 14:33:44 +02:00
a8093bd621 pkgs: drone-scp: 1.6.2 -> 1.6.3 2022-06-15 11:27:03 +02:00
530fb66e19 home: migrate 'cursor' module to new option
Make it part of 'home.wm' now, since that makes more sense.

Not sure about making it related to 'i3' being activated though, will
need to think about this in the future.
2022-06-15 11:27:03 +02:00
341450db5c home: vim: ftdetect: add tiger 2022-06-15 11:27:03 +02:00
37d272fcfb modules: services: lohr: add 'openssh'
The git binary is not wrapped to add it in PATH anymore.
2022-05-31 13:54:34 +02:00
9f2bbaeff9 machines: aramis: home: add 'element-desktop'
It's less buggy than the web version...
2022-05-31 13:50:27 +02:00
eb0f923b46 flake: bump inputs 2022-05-31 13:48:18 +02:00
7689df40a4 pkgs: diff-flake: 0.1.0 -> 0.2.0
Use the new flake attributes conventions.
2022-05-31 13:42:57 +02:00
e35a4a1bd3 flake: use new default app convention 2022-05-31 13:41:49 +02:00
e2098358ae overlays: remove 'sabnzbd-fix-missing-packages'
The upstream nixpkgs version has been fixed.
2022-05-31 11:07:32 +02:00
7fe49890be overlays: remove 'transgui-fix-duplicate-status'
It has been patched in upstream nixpkgs.
2022-05-31 11:06:58 +02:00
052d5a3df7 modules: services: nextcloud: bump to 24 2022-05-23 15:49:22 +02:00
641254614c flake: bump inputs 2022-05-23 15:46:07 +02:00
6fbacb8e59 pkgs: unified-hosts-lists: 3.9.11 -> 3.10.1 2022-05-23 11:07:05 +02:00
489b79f078 home: vim: completion: activate 'ghost_text'
I'm still thinking whether I would want to use one of those signature
helper windows to go with this/replace this feature.

Could be especially useful in C++.
2022-05-19 14:53:09 +02:00
50bf8b036b pkgs: dragger: fix meta information 2022-05-15 19:07:49 +02:00
80c5748122 home: packages: remove 'rr'
No need for this, now that I have a dedicated option for the package.
2022-05-10 13:51:49 +02:00
a625f5b741 home: wm: i3: simplify 'htop' rule
Turns out you can chain commands with `,` in a `for_window` statement.

Of course this is inconsistent with `bindsym` which uses `;`...
2022-05-03 10:01:42 +02:00
46affd5057 modules: hardware: bluetooth: remove wireplumber
This configuration file completely breaks my sound setup.

Will investigate more at a later time, in the mean time, since this is
basically the default options, I will just remove the configuration
file.

This reverts commit c987206bc5.
2022-05-02 11:18:23 +02:00
ea5e1042b4 flake: bump inputs 2022-04-28 13:45:55 +02:00
9e9c7faf0d machines: aramis: hardware: use 'hardware' module 2022-04-27 14:03:18 +02:00
43cb3ae582 modules: hardware: add firmware 2022-04-27 14:03:18 +02:00
cb84b49438 modules: hardware: bluetooth: add wireplumber conf
Now that `media-session` is deprecated, I should at least replicate this
configuration for `wireplumber`.
2022-04-27 14:03:10 +02:00
93e50508c9 home: vim: lua: lsp: add signature help mapping 2022-04-27 14:02:17 +02:00
70fc01d5df home: firefox: tridactyl: fix comment toggle
Ignore javascript event, like the upstream binding.
2022-04-27 14:02:17 +02:00
e514389a3d home: firefox: tridactyl: add 'Nitter' redirect 2022-04-27 14:02:17 +02:00
5c7c89519b profiles: gtk: remove typo 2022-04-27 14:02:17 +02:00
e591344eb3 home: vim: git: map keys on start
Instead of mapping those keys when `gitsigns` attaches to a buffer...
2022-04-27 14:02:17 +02:00
481d5f6f53 home: vim: lualine: use 'FugitiveHead'
The built-in `branch` indicator does not handle git worktrees quite
correctly.

It shows the wrong branch when used in `git commit`.
2022-04-27 14:02:17 +02:00
0caa78af10 flake: bump inputs
And ensure that the renamed `paperless` services are configured
correctly.
2022-04-27 14:02:17 +02:00
223f09b655 flake: update from deprecated flake attributes 2022-04-18 14:11:46 +02:00
ed8aae565e home: direnv: allow specifying default flake 2022-04-13 10:06:26 +02:00
9a57ba02b7 home: direnv: add 'nix' library file 2022-04-13 10:04:54 +02:00
90053e52e1 home: direnv: add 'python' library file 2022-04-13 09:20:52 +02:00
8ec992cbe3 home: direnv: add 'postgres' library file 2022-04-12 17:34:36 +02:00
e3f021e832 flake: only use subset of systems
Turns out pre-commit pulls dotnet in its closure, which is not supported
on i686...
2022-04-12 10:45:04 +02:00
b6ca6b28b9 overlays: remove vim-plugins-overrides 2022-04-12 10:45:04 +02:00
f637401cd6 home: zsh: use packaged 'agkozak-zsh-prompt' 2022-04-11 18:33:15 +02:00
13a218f2db flake: bump inputs 2022-04-11 18:33:15 +02:00
e2e11d08bd machines: aramis: networking: disable DHCP
Let NetworkManager take care of it, this avoids the "waiting for dhcpd"
message when shutting down my laptop.
2022-04-09 15:27:27 +02:00
676281d18b machines: porthos: services: set-up gitea mail 2022-04-08 21:34:44 +02:00
a9e004f7c1 modules: secrets: gitea: add 'mail-password' 2022-04-08 21:34:44 +02:00
94143f9d33 modules: services: gitea: add 'mail' configuration 2022-04-08 21:34:44 +02:00
d1f6a4933f flake: bump inputs 2022-04-04 16:20:55 +02:00
7334a84a77 home: wm: i3: bigger 'htop' window
It seems like one cannot use multiple commands in a `for_window`
directive. So use two different ones.
2022-03-29 15:49:08 +02:00
15602412c8 home: gdb: remove HOME pollution
Now that the version in nixpkgs contains the patch to look at
XDG_CONFIG_HOME, use only that one.
2022-03-25 15:49:05 +01:00
581aa1b4e3 machines: aramis: hardware: fix trackpoint device
My trackpoint, and its buttons, had stopped working a while ago. Before
that, I regularly had problems where the cursor jumped around randomly,
or the buttons stopped working.

This seems to have fixed it.
2022-03-14 14:33:12 +01:00
bab317e2f4 home: vim: null-ls: prefer 'pflake8' if available 2022-03-11 14:30:27 +01:00
1801d008d9 overlays: add vim-plugins-overrides 2022-03-11 14:28:09 +01:00
b71be091a2 home: git: use 'zdiff3' merge conflict markers
See GitHub's presentation about this feature [1].

[1]: https://github.blog/2022-01-24-highlights-from-git-2-35/
2022-03-11 14:11:32 +01:00
20e0a96e65 home: vim: telescope: add 'which-key' mapping
This opens a little preview window with different mappings for
telescope.
2022-03-11 14:11:07 +01:00
fda1b235bc home: vim: telescope: disable scrolling up 2022-03-11 14:03:18 +01:00
7060891b2d home: vim: set 'termguicolors'
For once, I like the look *with* 24-bit colors better on this current
color-scheme.
2022-03-11 14:02:01 +01:00
6417b5f4ba home: vim: sort plugin list 2022-03-11 10:08:25 +01:00
d103cbbb0e home: wm: i3bar: show microphone status 2022-03-09 12:09:43 +01:00
8d4a1e61b4 home: vim: telescope: add LSP handler 2022-03-08 20:57:28 +01:00
4c5c9deaae home: vim: move 'on_attach' to 'ambroisie.lsp' 2022-03-08 20:20:22 +01:00
fc35502141 home: vim: lspconfig: use actual 'lspconfig' name 2022-03-08 20:18:02 +01:00
0db2c0a13c modules: services: matrix: use 'settings'
The unstructured attributes are hard-deprecated.
2022-03-08 11:56:32 +01:00
ba6c8bff2e flake: bump inputs 2022-03-08 10:41:35 +01:00
32890d6cf2 home: vim: completion: do not use tab to select
I would rather have my actual preferred mappings, <C-n> and <C-p>, for
that.
2022-03-08 10:41:35 +01:00
3673ec604a home: vim: lualine: remove 'fzf' integration
I do not use 'fzf' anymore.
2022-03-08 10:41:35 +01:00
1f8882b415 home: vim: configure 'luasnip' 2022-03-08 10:41:35 +01:00
a923c2c30e home: vim: add 'friendly-snippets' 2022-03-08 10:41:35 +01:00
37552d6508 home: vim: completion: remove up/down mappings
I do not use arrow keys, why bother with them.
2022-03-08 10:41:35 +01:00
85a7e200ad home: vim: add 'nvim-ts-context-commentstring' 2022-03-08 10:41:35 +01:00
fa8961c9d9 home: vim: comparison: stronger priority hint 2022-03-08 10:41:35 +01:00
01f2dfd028 home: vim: completion: configure snippets 2022-03-08 10:41:35 +01:00
551ef640fc home: vim: sort plugin list 2022-03-08 10:41:35 +01:00
fb3b773249 home: vim: add 'luasnip' 2022-03-08 10:41:35 +01:00
975f8687fc home: vim: completion: add mapping to scroll docs 2022-03-08 10:41:35 +01:00
506c52fb83 home: vim: completion: add 'cmp-under-comparator' 2022-03-08 10:41:35 +01:00
0f140bbc9d home: vim: completion: explicit mappings
This is basically a copy-paste of the default mappings, with some small
amount of customization.
2022-03-08 10:41:35 +01:00
d35c675ace home: vim: configure 'dressing-nvim' 2022-03-08 10:41:35 +01:00
0b2911e49e home: vim: add 'dressing-nvim' 2022-03-08 10:41:35 +01:00
9364fe546d home: vim: telescope: set-up 'fzf' matching 2022-03-08 10:41:35 +01:00
8b4da72c84 home: vim: add 'telescope' grep mappings 2022-03-08 10:41:35 +01:00
7fec5f870a home: vim: replace 'fzf' with 'telescope'
I like the fact that it uses built-in buffers to preview files.

It also has more inertia behind it, tighter integrations in the
ecosystem.
2022-03-08 10:41:35 +01:00
5e3bd82f8b home: packages: add 'fd' 2022-03-08 10:41:35 +01:00
62e29fc622 home: packages: add 'ripgrep' 2022-03-08 10:41:35 +01:00
b8bd1ef2b4 home: vim: completion: limit 'buffer' suggestions
Otherwise it gets overwhelming, and most are useless.
2022-03-08 10:41:35 +01:00
5b8e410596 home: vim: completion: use better order 2022-03-08 10:41:35 +01:00
aac464c9a2 home: vim: completion: use native menu 2022-03-08 10:41:35 +01:00
8bcd40633a home: vim: configure 'nvim-cmp' for LSP 2022-03-08 10:41:35 +01:00
bceb531518 home: vim: add 'cmp-nvim-lsp' 2022-03-08 10:41:35 +01:00
15b3766aef home: vim: configure 'nvim-cmp' 2022-03-08 10:41:35 +01:00
02225dcb93 home: vim: add 'nvim-cmp' 2022-03-04 17:40:30 +01:00
d006ba4611 home: vim: git: more visual mappings
I cannot use the functions directly, as I would need to calculate the
current selections begin and end points and use them as arguments.

To be investigated.
2022-03-04 17:40:30 +01:00
714eb8ca2d home: vim: git: 'gitsigns' mappings are per buffer 2022-03-04 17:40:30 +01:00
10635e0888 home: vim: git: use more appropriate mapping names 2022-03-04 17:40:30 +01:00
f374a4f78c home: vim: lsp: add diagnostic mappings 2022-03-04 17:40:30 +01:00
ac0df2552a home: vim: lsp: add workspace mappings 2022-03-04 17:40:30 +01:00
eaeb9db76f home: vim: add 'dump' utility function 2022-03-04 17:40:30 +01:00
2ad4ba563d home: vim: remove 'fastfold'
I don't think I need it anymore, neovim improves the native performance
well enough.
2022-03-04 17:40:30 +01:00
f10d3f7310 home: vim: add mappings for LSP functionality 2022-03-04 17:40:30 +01:00
bde9bef1c9 home: vim: don't use 'nixpkgs-fmt' with 'rnix' 2022-03-04 17:40:30 +01:00
8b4a5e174f home: vim: add 'rnix' LSP configuration 2022-03-04 17:40:30 +01:00
997b98f49b home: vim: add 'clang-tools' to vim package
It includes both `clangd` and `clang-format`, even though I'm mostly
looking for the later.
2022-03-04 17:40:30 +01:00
03564813af home: vim: add linters & formatters to vim package
I use them so often, I basically always want them available.
2022-03-04 17:40:30 +01:00
7546417782 home: vim: add 'shellcheck' code actions 2022-03-04 17:40:30 +01:00
c28710773b home: vim: rename 'git'-related settings file
Now that it contains more settings than just 'gitsigns'.
2022-03-04 17:40:30 +01:00
b6435f0d57 home: vim: centralise 'git'-related mappings 2022-03-04 17:40:30 +01:00
03e412b2f0 home: vim: configure 'gitsigns'
And remove some unused mappings, or adapt them to 'gitsigns'.
2022-03-04 17:40:30 +01:00
267b82393f home: vim: add 'gitsigns-nvim' 2022-03-04 17:40:30 +01:00
8a6a18732a home: bat: use 'gruvbox-dark' theme
To match my `vim` configuration.
2022-03-04 17:40:30 +01:00
2eb1f5cc44 home: vim: prefer 'clangd' to 'clang-format'
Only use `clang-format` if `clangd` is not available, as its formatting
is otherwise built into the LSP server.
2022-03-04 17:40:30 +01:00
12d2436713 home: vim: use 'unimpaired' mappings for quickfix 2022-03-04 17:40:30 +01:00
b6d1702726 home: zsh: add 'zsh-completions' when enabled
Notably useful for `git-revise`.
2022-03-04 17:40:30 +01:00
4356ae0f36 home: zsh: refactor 'mkIf' block 2022-03-04 17:40:30 +01:00
e2be5f6139 home: zsh: use packaged 'fast-syntax-highlighting' 2022-03-04 17:40:30 +01:00
bce9855da1 home: vim: show LSP progress in status line 2022-03-04 17:40:30 +01:00
2152f9dd1e home: vim: switch to 'lualine' 2022-03-04 17:40:30 +01:00
9c3daae2b8 home: vim: add function to list LSP client names 2022-03-04 17:40:30 +01:00
ea9a0d835b home: vim: remove unused 'gruvbox' configuration 2022-03-04 17:40:30 +01:00
d3c04107bf home: vim: move diagnostics config to 'on_attach' 2022-03-04 17:40:30 +01:00
336d86d2d8 home: vim: add 'clangd' LSP configuration 2022-03-04 17:40:30 +01:00
ae94693540 home: vim: add 'rust-analyzer' LSP configuration 2022-03-04 17:40:30 +01:00
84188cb7fa home: vim: add basic LSP configuration
Trying it out with `pyright` for now.
2022-03-04 17:40:30 +01:00
53d84b884d home: vim: move LSP-related 'on_attach' to 'utils'
As it will be shared between `null-ls` and `lspconfig`, it makes sense
to put it there.
2022-03-04 14:54:14 +01:00
9dc910eae3 home: vim: add diagnostic navigation mappings 2022-03-04 14:51:44 +01:00
260f5cd66a home: vim: do not use 'ftplugin' for 'null-ls'
Unfortunately, this registers the sources many times...

I fear that I will have to settle for a centralised configuration for
LSP-related options.
2022-03-04 14:14:30 +01:00
fb49a1df14 home: vim: only use 'null-ls' sources if available
This avoids the big red warning on each file that tries to use those
sources...
2022-03-03 18:15:28 +01:00
8155f6be4c home: vim: add 'ambroisie.utils' lua module 2022-03-03 18:15:28 +01:00
8b84ab8625 home: vim: add statement objects/moves
And document it.
2022-03-03 18:15:28 +01:00
56554f1a7a home: vim: document 'tree-sitter' moves 2022-03-03 18:15:28 +01:00
8ad5327c89 home: vim: add 'tree-sitter' moves 2022-03-03 18:15:28 +01:00
063686433f home: vim: document 'treesitter-textobjects' maps
By using 'which-key'.
2022-03-03 18:15:28 +01:00
a5ec91088d home: vim: add 'treesitter-textobjects' 2022-03-03 18:15:28 +01:00
e81aee50e3 home: vim: remove mapping to run 'make' 2022-03-03 18:15:28 +01:00
1408d7735a home: vim: document 'commentary' mappings
By using 'which-key'.
2022-03-03 18:15:28 +01:00
2713270378 home: vim: document 'unimpaired' mappings
By using 'which-key'.
2022-03-03 18:15:28 +01:00
4fec4d499d home: vim: use 'which-key' 2022-03-03 18:15:28 +01:00
9e7f7ed736 home: vim: add 'which-key-nvim' 2022-03-02 12:30:53 +01:00
b76af022bd home: vim: move leader mappings to 'init.vim' 2022-03-02 12:30:53 +01:00
8b570694cd home: vim: remove unused mappings
The beancount mappings are absolutely unused.

The `Y` mapping is built in NeoVim nowadays.
2022-03-02 12:30:53 +01:00
d15bc59b74 home: vim: remove unimpaired mappings
I do not use `azerty` anymore, no need for those.
2022-03-02 12:30:53 +01:00
875c3c8886 home: vim: remove 'lsp_lines'
I like the hovering behaviour better, it's less "in your face".

I might revisit the idea in the future, as a toggled mapping.
2022-03-02 12:30:53 +01:00
9caf296d52 home: vim: show diagnostics on hover
Ideally, I want the following features:
* diagnostic icons in the sign column always,
* virtual text on the current line only
* switch to hover window and/or lsp_lines display through a mapping
2022-03-02 12:30:53 +01:00
fba2403bf3 home: vim: configure short 'CursorHold' timeout 2022-03-02 12:30:53 +01:00
5437b45a02 home: vim: configure diagnostics further
This is not only 'lsp_lines' configuration anymore, but the whole
display of diagnostics.
2022-03-02 12:30:53 +01:00
bbc32d6030 home: vim: add 'nvim-treesitter'
IMHO, this is *very* colorful, I might not end up using the highlighting
after all.

Let's see if I get used to it after a little while.
2022-03-02 12:30:53 +01:00
c3b0b9c607 home: vim: make python formatting faster 2022-03-02 12:30:53 +01:00
58de8106a1 home: vim: add 'lsp_lines'
I dislike the diagnostics *next* to affected lines.

This looks neater, though the best look would be a simple hover window
or status line message instead, like ALE used to do.

It might grow on me however.
2022-03-02 12:30:53 +01:00
54ad5d9282 home: vim: configure 'null-ls' for 'nix' 2022-03-02 12:30:53 +01:00
300ce25c8e home: vim: keep space after shell redirections 2022-03-02 12:30:53 +01:00
7d361023bc home: vim: show error codes from 'shellcheck' 2022-03-02 12:30:53 +01:00
3e60cb5be1 home: vim: configure 'null-ls' for 'python' 2022-03-02 12:30:53 +01:00
9a9e50f7a8 home: vim: configure 'null-ls' for 'cpp' 2022-03-02 12:30:53 +01:00
a59884b59c home: vim: configure 'null-ls' for 'c' 2022-03-02 12:30:53 +01:00
d52833f3a3 home: vim: add formatting on save with 'null-ls' 2022-03-02 12:30:53 +01:00
ccbf73385e home: vim: configure 'null-ls' for 'haskell' 2022-03-02 12:30:53 +01:00
0b4d39c771 home: vim: configure 'null-ls' for 'zsh' 2022-03-02 12:30:53 +01:00
ba3ab14ac3 home: vim: configure 'null-ls' for 'sh' 2022-03-02 12:30:53 +01:00
e760f5aeaa home: vim: configure 'null-ls' for 'bash' 2022-03-02 12:30:53 +01:00
e1a8c9e563 home: vim: add 'null-ls' 2022-03-02 12:30:53 +01:00
6f57a03940 home: vim: configure 'lightline-lsp'
This pretty much replace 'lightline-ale' for me now.

At least it will, once I have configured some LSP clients.
2022-03-02 12:30:53 +01:00
ad7b9a574d home: vim: add 'lightline-lsp' 2022-03-02 12:30:53 +01:00
039c6390a3 home: vim: remove 'quickfixed' functionality
I never use it anymore...
2022-03-02 12:13:13 +01:00
5c3d3f5f1c home: vim: remove 'ALE' configuration
First step to modernising my configuration to use the native LSP client
instead.
2022-03-02 12:13:13 +01:00
cc91b88b28 flake: bump inputs
And do not use 'pipewire-media-session' which is deprecated.
2022-03-02 12:13:13 +01:00
ef36a100af home: vim: fix icon for read-only files 2022-02-23 21:06:12 +01:00
1b829076f8 flake: bump inputs 2022-02-21 18:53:56 +01:00
a6a64047de home: wm: i3: only boost volume on 'Shift' mapping 2022-02-18 12:22:51 +01:00
cc12148dac pkgs: change-audio: 0.2.0 -> 0.3.0
Only boost audio beyond 100% if specifically asked for.
2022-02-18 12:22:51 +01:00
8d4bbaf886 home: tmux: fix yanking configuration
Use `tmux-yank` when a GUI is enabled, otherwise use the internal tmux
buffer.

In both cases, stay in copy mode after yanking.
2022-02-08 17:25:44 +01:00
39431c2656 modules: system: nix: use structural 'settings'
Instead of a stringly-typed `extraOptions`.
2022-02-08 14:32:00 +01:00
7e8936fc55 home: firefox: tridactyl: fix HN comment folding 2022-02-07 17:00:18 +01:00
44efea17b5 home: firefox: tridactyl: fix DDG mapping
Taken straight from upstream's sample configuration.
2022-02-07 15:51:56 +01:00
af25f555ac home: packages: add 'mosh' 2022-02-07 15:00:52 +01:00
b4796947db flake: bump inputs 2022-02-07 14:49:06 +01:00
dbc808ce50 home: wm: i3bar: show volume when muted 2022-02-03 11:40:24 +01:00
ef875f881f home: ssh: add 'work' host 2022-01-25 15:53:01 +01:00
b33cefde63 home: firefox: remove 'i-dont-care-about-cookies'
Should be superseded by Consent-O-Matic now.
2022-01-25 15:53:01 +01:00
7229eaca21 home: firefox: add 'consent-o-matic' 2022-01-25 15:53:01 +01:00
1987711fce flake: bump inputs
Also change a removed package alias' name.
2022-01-25 15:53:01 +01:00
ba5782e748 modules: system: packages: remove some packages
They either belong in a nix shell or are taken care of by other
configurations.
2022-01-14 15:06:55 +01:00
8151b28527 modules: services: nginx: use 'acme.default.email'
The option `security.acme.email` has been deprecated.
2022-01-14 13:30:22 +01:00
f86a04f888 pkgs: add psst 2022-01-14 13:27:17 +01:00
ce25ed6445 home: firefox: trydactyl: ignore prime video 2022-01-14 13:24:09 +01:00
36728068bd machines: porthos: services: disable nzbhydra
Same deal as jackett: prowlarr has been working perfectly adequately for
a while now.
2022-01-14 13:24:09 +01:00
5b130951fb machines: porthos: services: disable jackett
Prowlarr has been humming along just fine, and works even better than
jackett.
2022-01-14 13:24:09 +01:00
e6fe5e57c9 modules: system: add podman 2022-01-14 13:24:09 +01:00
1908897abc machines: aramis: home: enable discord 2022-01-09 22:19:28 +01:00
607872753d home: add discord 2022-01-09 22:19:07 +01:00
f386149550 home: wm: change default screen-lock timeout
5 minutes is too short.
2022-01-07 08:55:58 +01:00
923227f371 flake: bump inputs 2022-01-07 08:55:58 +01:00
4003e98457 machines: aramis: home: add teams package
Unfortunately, it is the preferred communication method at $WORK.
2022-01-07 08:55:58 +01:00
5c7ef3232e modules: system: nix: add inputs to NIX_PATH 2022-01-07 08:55:58 +01:00
0435a50675 home: vim: cut back on fzf mappings
I only ever use the buffer and files regularly.
2021-12-22 23:34:46 +01:00
4d5d662913 modules: services: nextcloud: upgrade version 2021-12-07 19:11:32 +01:00
070a929f88 flake: bump inputs
And use renamed option for agenix identities.
2021-12-07 19:11:32 +01:00
c492774baa home: git: do not change metadata color 2021-12-06 21:24:31 +01:00
07b60f8f52 flake: bump inputs
And make my configuration build after the removed option from
`programs.direnv` in home-manager.
2021-11-30 15:41:14 +01:00
eb89d7feb3 home: restart services automatically (again)
I think my issue was *not* related to this, so I might as well keep
using it since it does seem useful in the long run.

This reverts commit a94f349dde.
2021-11-30 15:41:14 +01:00
281edd4eac home: git: switch to 'delta'
Now that my issue with it has been resolved [1], let's switch to the
more mature tool.

This also solves a small issue that I had with `diff-highlight` which is
that non-highlighted text should not be boldened.

[1]: https://github.com/dandavison/delta/issues/544
2021-11-29 17:50:07 +01:00
48a9f9b11e home: git: use diff-highlight in interactive diffs
Now even `git log -p` and `git add -p` can use the more readable diffs.
2021-11-29 13:13:48 +01:00
d86ff6192c modules: system: nix: don't change daemon niceness
This option doesn't really work the way it should anyway [1].

This reverts commit cbf6ea9ac9.

[1]: https://github.com/NixOS/nixpkgs/pull/138741
2021-11-23 18:53:11 +01:00
de54779775 flake: agenix has renamed its branch to 'main' 2021-11-23 17:08:46 +01:00
d42eaeb362 home: wm: i3: show notification on toggling mute 2021-11-12 10:21:25 +01:00
dab44c6052 pkgs: change-audio: 0.1.2 -> 0.2.0
Allow muting microphone and speakers, with refactor to make it DRY.
2021-11-12 10:17:42 +01:00
ce0c634a05 pkgs: change-audio: 0.1.1 -> 0.1.2
Show if volume is currently muted.
2021-11-12 09:52:22 +01:00
e295a60cf5 flake: enable shellcheck pre-commit hook 2021-11-12 09:42:39 +01:00
d0e6e03c23 pkgs: change-audio: 0.1.0 -> 0.1.1
Fix issue with not showing notification at 0% volume.
2021-11-12 09:40:37 +01:00
f020338056 home: tmux: remove tmux service
Turns out it is more trouble than it is worth trying to make this work:
with the secure socket problem etc...

The first start up is fast enough for me in the end.

This reverts commit cc21d84808.
2021-11-09 15:32:59 +01:00
4749e9b561 flake: bump inputs 2021-11-09 15:16:20 +01:00
d490a7de78 modules: services: nginx-sso: always rewrite conf 2021-11-06 15:43:00 +01:00
a36eae4e66 modules: services: paperless: backup 'dataDir' 2021-11-05 17:03:52 +01:00
dd0c110f71 modules: services: calibre-web: use 'dataDir' 2021-11-05 17:03:52 +01:00
e2638728e3 modules: services: pirate: sort 'ports' values 2021-11-05 17:03:52 +01:00
8759039187 machines: porthos: services: use 'lohr.sshKeyFile' 2021-11-05 16:59:11 +01:00
62e62c70e1 modules: services: lohr: declarative ssh key 2021-11-05 16:59:11 +01:00
b5b8f83e71 modules: secrets: lohr: add 'ssh-key' 2021-11-05 15:31:59 +01:00
cbae0ef1da profiles: wm: remove unused argument 2021-11-05 14:58:58 +01:00
cf37d3172a profiles: gtk: remove unused argument 2021-11-05 14:58:58 +01:00
986aed79fb pkgs: dragger: remove unused argument 2021-11-05 14:58:58 +01:00
5fdc390411 modules: services: nginx: remove unused argument 2021-11-05 14:58:58 +01:00
67ea6d9f95 modules: services: drone: remove unused arguments 2021-11-05 14:58:58 +01:00
eb9fffd7b4 machines: porthos: users: remove unused let block 2021-11-05 14:58:58 +01:00
c11b3a2fa6 home: wm: dunst: replace deprecated 'geometry' 2021-11-04 16:35:06 +01:00
99e300bbc4 home: wm: i3: use packaged scripts
Instead of inlining them in the configuration, use an actual package for
those.
2021-11-04 16:35:06 +01:00
f987e79d17 pkgs: add change-audio 2021-11-04 16:35:06 +01:00
10b8ee50c1 pkgs: add change-backlight 2021-11-04 16:35:06 +01:00
d724c205ea home: wm: i3: avoid loading icon on notifications
Because my script are obviously not startup id aware, hovering on the
notification leads to having a loading cursor.
2021-11-03 17:57:33 +01:00
751af91c2c home: wm: i3: notify when changing audio volume 2021-11-03 17:50:28 +01:00
335454ee16 home: wm: i3: extract 'notify-send' variable
It is used in multiple scripts, might as well centralise it.
2021-11-03 17:49:47 +01:00
450ab4b07b modules: services: backup: remove deprecated name 2021-11-03 17:16:40 +01:00
28d8f0bf06 flake: bump inputs 2021-11-03 14:10:18 +01:00
a5fe7a41e6 flake: remove gnupg from devShell 2021-11-03 14:10:18 +01:00
72310d4047 home: do not restart services automatically
Turns out it is *not* ideal when modifying my WM configuration in any
way... Having i3 restart due to changing a keybinding is not great.

This reverts commit 6bec62073b.
2021-11-03 14:10:18 +01:00
548484d918 home: wm: i3: use 'i3status-rust.package' value 2021-11-03 14:10:18 +01:00
1633d6b3bc flake: bump inputs 2021-11-03 14:10:18 +01:00
66c3b70997 home: wm: screen-lock: rename changed option 2021-10-22 13:15:22 +02:00
9b184f94ac modules: home: forward inputs to home-manager
This will be useful if and when I end up adding inputs with home-manager
modules defined.
2021-10-22 13:06:53 +02:00
36d6b2828e home: start services when switching
As I use home-manager with its NixOS module, I do not see the message
suggesting to start the services otherwise.
2021-10-21 16:42:15 +02:00
9e229a6bb8 project: readme: mention manual prowlarr step 2021-10-18 19:48:50 +02:00
d0ad9982ce machines: porthos: services: enable prowlarr 2021-10-18 19:48:50 +02:00
7ca32d8b05 modules: services: indexers: add prowlarr 2021-10-18 19:48:50 +02:00
731793bb6e flake: bump inputs 2021-10-18 19:48:50 +02:00
af5103803b modules: services: indexers: refactor
This is cleaner and more correct.
2021-10-18 19:48:50 +02:00
f5e26526da modules: services: indexers: fix typo 2021-10-18 19:48:50 +02:00
353848ec73 pkgs: unified-hosts-lists: 3.8.5 -> 3.9.11 2021-10-18 19:28:46 +02:00
69d7fd5d7c modules: system: nix: change nix build niceness
19 is the lowest priority.
2021-10-18 18:49:03 +02:00
d353e2557c home: wm: i3bar: add bluetooth blocks
I have decided that the potential security and privacy risk of exposing
my MAC addresses is fine by me.

My earphones and headphones do not seem to expose their battery level,
would need more investigation.
2021-10-18 15:51:15 +02:00
ae06ccac4a home: git: rewrite gitlab URLs to use ssh 2021-10-18 14:45:23 +02:00
a8cf45a9f7 home: git: rewrite github URLs to use ssh 2021-10-18 14:44:19 +02:00
6a18be1d0a home: git: rewrite personal gitea URLs to use ssh 2021-10-18 14:44:08 +02:00
a9f751f0ed home: wm: i3bar: use dynamic width on music block 2021-10-16 18:07:07 +02:00
cf7ba65c30 machines: aramis: networking: remove 'domain'
Now that services handle subdomains through my Nginx abstraction, we can
remove this.
2021-10-16 14:56:15 +02:00
0d87934ee0 home: wm: i3: add 'rofi-bluetooth' binding 2021-10-15 17:19:12 +02:00
645a602cc1 home: tmux: add binding for block selection 2021-10-15 17:13:02 +02:00
8b763099e3 home: wm: i3: don't add 'dragger' through profile 2021-10-15 17:12:24 +02:00
52fb5500be pkgs: add rofi-bluetooth 2021-10-15 17:09:03 +02:00
5059835e97 pkgs: sort packages alphabetically 2021-10-15 17:01:40 +02:00
7b7041e5b5 home: git: add git-related packages when enabled
Instead of adding them in the general packages section.
2021-10-13 15:36:28 +02:00
0bfc92b09c home: git: inline EPITA configuration include 2021-10-13 15:36:28 +02:00
dd48089a82 modules: services: nginx: use 'mkMailAccount' 2021-10-13 15:36:28 +02:00
f76803c9bb home: git: use 'mkMailAccount' 2021-10-13 15:36:28 +02:00
7b6af91642 home: mail: accounts: use 'mkMailAccount' 2021-10-12 17:55:37 +02:00
8bf601a6aa lib: strings: add 'mkMailAddress' 2021-10-12 17:53:23 +02:00
62adfd5055 lib: add strings 2021-10-12 17:53:10 +02:00
3e6c467816 home: git: add 'git' alias 2021-10-12 16:33:33 +02:00
2cd56e133f modules: services: wireguard: add 'milady' 2021-10-10 17:16:29 +02:00
d43831cbf1 modules: secrets: wireguard: add 'milady' 2021-10-10 17:16:29 +02:00
0aa2f59530 pkgs: dragger: change platforms to linux
I haven't tested it on darwin, and it just so happens that some
dependency is broken on that system (breaking `nix flake check`)...

Will revisit this later in case I ever happen to use a darwin system.
2021-10-08 19:39:43 +02:00
09140b0170 profiles: wm: add 'dragger' when a WM is set up 2021-10-08 15:06:33 +02:00
152df1501a home: gammastep: fix typo 2021-10-08 15:03:45 +02:00
4f558a1ebd flake: use 'recurseIntoAttrs' in 'pkgs' overlay 2021-10-08 15:00:46 +02:00
f8f7fb06a7 pkgs: add dragger 2021-10-08 14:59:03 +02:00
cf47817b34 home: xdg: make gdb store history in XDG_DATA_HOME 2021-10-08 12:46:00 +02:00
02263141c4 home: firefox: add 'reddit-comment-collapser' 2021-10-06 09:48:20 +02:00
f494c3cba7 home: firefox: re-organise module 2021-10-06 09:48:20 +02:00
c746d7d3ba home: firefox: add 'refined-github' 2021-10-06 09:48:20 +02:00
b66e46e241 overlays: add sabnzbd-fix-missing-dependencies
While waiting for my PR to fix this [1].

[1]: https://github.com/NixOS/nixpkgs/pull/140478
2021-10-04 15:01:39 +02:00
b3aa737e28 flake: bump inputs 2021-10-04 14:45:41 +02:00
ac76d8ae68 home: tmux: add tmux service
The service definition is pretty awful, but it deals with the secure
socket correctly...

This avoids having a small lapse when starting the very first shell of a
session, which must first launch the server.
2021-09-30 16:58:44 +02:00
3ec99d4c0e home: tmux: make history longer
We got tons of RAM!
2021-09-30 16:47:52 +02:00
e4bd59b82b home: wm: i3: launch tmux when starting terminal
Similarly to the `zsh` snippet, launch tmux unless I explicitly do not
want it.

The reason I also add it in `i3` is to make the launch happen sooner,
and to avoid doing double work on some shell startup shenanigans if I
can.
2021-09-30 15:38:43 +02:00
3d0a73fffd home: zsh: launch tmux when starting a shell 2021-09-30 15:34:16 +02:00
cdabd4fb5d home: vim: switch back to gruvbox theme
Onedark is too annoying to deal with, and I still like gruvbox's colors
best.
2021-09-29 18:50:33 +02:00
4be248ee22 flake: bump inputs 2021-09-29 17:37:15 +02:00
88ae4abca0 profiles: gtk: new best practices for dconf 2021-09-27 17:07:47 +02:00
55541abd17 modules: secrets: fix permission for grafana 2021-09-26 23:09:33 +02:00
b9786398a7 modules: secrets: fix permission of 'matrix/mail' 2021-09-26 23:09:33 +02:00
5fd82472bf modules: secrets: add 'owner' logic 2021-09-26 23:09:33 +02:00
8968e30e62 modules: secrets: remove 'with lib;' 2021-09-26 23:09:33 +02:00
0b580b61e7 secrets: move into 'modules' 2021-09-26 23:09:33 +02:00
c32be8ac02 project: bootstrap: retrieve agenix key 2021-09-26 23:09:33 +02:00
8eef7c260e ci: use 'nix flake check'
Now that I am using agenix, secrets stays encrypted at rest.
2021-09-26 23:09:33 +02:00
172e29db69 flake: remove 'git-crypt' 2021-09-26 23:09:33 +02:00
3d0d19d9a1 secrets: remove git-crypt 2021-09-26 23:09:33 +02:00
e64fdcf38b secrets: remove git-crypt secrets 2021-09-26 23:09:33 +02:00
414c27ee63 modules: services: nginx: sso: use runtime secrets 2021-09-26 23:09:33 +02:00
7257f3156e machines: porthos: services: switch to agenix
The prep-work should be done now, time to hit the switch.
2021-09-26 23:09:32 +02:00
c7766afe90 modules: services: nginx: allow sso secret files
This is in preparation of the migration to agenix, which does not allow
access to the secrets at build time.
2021-09-26 23:09:32 +02:00
dc5a44ce82 home: put modules into folders 2021-09-26 23:09:32 +02:00
5b0e0bcbc2 home: terminal: put modules into folders 2021-09-26 23:09:32 +02:00
b90629fdd9 home: x: put modules into folders 2021-09-26 23:09:32 +02:00
acc23ab684 home: wm: put modules into folders 2021-09-26 23:09:32 +02:00
544aec0d91 home: mail: put modules into folders 2021-09-26 23:09:32 +02:00
a12b629dc3 home: firefox: put modules into folders 2021-09-26 23:09:32 +02:00
f61f11ba29 profiles: put modules into folders 2021-09-26 23:09:32 +02:00
b46b918295 modules: services: drone: split into files
This is cleaner to read.
2021-09-26 23:09:32 +02:00
ac90c5b11a modules: services: put modules into folders 2021-09-26 23:09:32 +02:00
836b54b8eb modules: hardware: put modules into folders 2021-09-26 23:09:32 +02:00
7bec7ae0f9 modules: system: put modules into folders 2021-09-26 23:09:32 +02:00
d5b09c48ef modules: programs: put modules into folders 2021-09-26 23:09:32 +02:00
c88fa91671 modules: home: put into folder 2021-09-26 23:09:32 +02:00
f09ba6b5be machines: porthos: users: use clear-text ssh key 2021-09-26 23:09:32 +02:00
33d539ed4f modules: system: users: use agenix secrets 2021-09-26 23:09:32 +02:00
91abacd0f6 modules: services: wireguard: use agenix secrets 2021-09-26 23:09:32 +02:00
16d3cd9f81 modules: services: nginx: use 'credentialsFile'
In preparation for the migration to agenix.
2021-09-26 23:09:32 +02:00
7d37701811 modules: services: matrix: use 'mailConfigFile'
In preparation of the migration to agenix.
2021-09-26 23:09:32 +02:00
4643690b43 modules: services: paperless: use 'secretKeyFile'
In preparation for the migration to agenix.
2021-09-26 23:09:32 +02:00
5579baecfb modules: services: nextcloud: use 'credentialsfile'
In preparation for the migration to agenix.
2021-09-26 23:09:32 +02:00
9d8da4d2b2 modules: services: miniflux: use 'credentialsFiles'
In preparation for the migration to agenix.
2021-09-26 23:09:32 +02:00
da63787874 modules: services: transmission: secrets w/ file
In preparation for the migration to using agenix.
2021-09-26 23:09:31 +02:00
98034a5410 secrets: register agenix secrets automatically 2021-09-26 23:09:31 +02:00
8664781da7 secrets: migrate to agenix
It is finally time to graduate to an actually secure, stateless
solution.
2021-09-26 23:09:31 +02:00
abf526ae3c secrets: import 'agenix' module 2021-09-25 13:31:43 +02:00
7273f2102a flake: add 'agenix' 2021-09-25 13:30:51 +02:00
963c86c66f home: remove unused 'secrets' module 2021-09-25 13:27:01 +02:00
f3519e845f home: ssh: add missing 'mkIf cfg.enable' 2021-09-24 01:21:57 +02:00
8ba1746be4 home: remove unused arguments 2021-09-24 01:21:57 +02:00
313b0c23a9 modules: remove unused arguments 2021-09-24 01:21:57 +02:00
176d95d890 machines: remove unused arguments 2021-09-24 01:21:57 +02:00
b398481ba3 pkgs: remove unused arguments 2021-09-24 01:21:57 +02:00
d813d85af8 lib: remove 'with self;' 2021-09-24 01:21:57 +02:00
9473cff408 lib: modules: refactor 'mapModules'
Introduce the recursive version of this function, then refactor to
reduce repetition.
2021-09-24 01:21:57 +02:00
2b0b6f2004 lib: modules: document 'mapModules' 2021-09-24 00:26:28 +02:00
8852699c9a modules: services: nginx: use 'recursiveMerge' 2021-09-23 22:11:25 +02:00
364ea0404a home: wm: i3: use 'recursiveMerge' 2021-09-23 22:11:25 +02:00
8ce123c527 lib: attrs: add 'recursiveMerge' 2021-09-23 22:11:25 +02:00
c13e57f584 modules: system: users: use 'initialHashedPassword'
This is the better option to use in case I want to have a stateless
system.
2021-09-23 21:30:24 +02:00
2f9d3417d4 modules: system: users: use 'ambroisie' password
Do not rely on `my.user.name` which could be changed to a value not
available in the secrets.
2021-09-23 21:28:29 +02:00
27040532bd modules: programs: steam: respect XDG conventions
Steam wants to pollute HOME with `.steam*` files and folders, which are
useless and annoying.

We want to make sure the wrappers are preferred when installing, so use
`lib.hiPrio` to ensure they get chosen.
2021-09-15 19:23:24 +02:00
7aa2a0f8fa machines: aramis: programs: enable steam 2021-09-15 19:23:24 +02:00
24b540d948 modules: programs: add steam 2021-09-15 19:23:24 +02:00
91489d5b71 modules: add 'programs' directory 2021-09-15 16:48:10 +02:00
4ccf549e58 modules: system: remove 'media'
It was not the idiomatic way to do this.
2021-09-15 16:10:06 +02:00
8c0b70dcb5 pkgs: make use of scoping
This is the way to make sure `callPackage` picks up my custom packages
to be used in the set.
2021-09-15 15:33:18 +02:00
02992d819e home: gdb: add nix store to safe path
For now, the nix store path is hard-coded rather than substituted.

This is useful for pretty-printing C++ types compiled with a different
C++ library from my gdb.
2021-09-03 17:34:39 +02:00
9474a3b57b git: remove duplicate ignore directive 2021-09-01 14:52:38 +02:00
4521cba5f0 flake: use 'nativeBuildInputs' 2021-09-01 14:51:27 +02:00
0df212f877 pkgs: unified-hosts-lists: do not set 'phases' 2021-08-31 20:11:11 +02:00
1690efc107 pkgs: unbound-zones-adblock: do not set 'phases' 2021-08-31 20:11:00 +02:00
5fdf108c40 pkgs: matrix-notifier: do not set 'phases' 2021-08-31 20:10:41 +02:00
2d40fc3d00 pkgs: i3-get-window-criteria: do not set 'phases' 2021-08-31 20:08:22 +02:00
5accea2a33 pkgs: havm: use 'nativeBuildInputs'
This is the correct one to use for a compiler like 'ghc'.
2021-08-31 19:50:44 +02:00
1d41918d70 pkgs: diff-flake: do not set 'phases' 2021-08-31 19:03:33 +02:00
2709c3751f pkgs: comma: do not set 'phases' 2021-08-31 19:03:25 +02:00
920e31c72f pkgs: comma: give path to source directly 2021-08-31 19:03:24 +02:00
cc54fe9087 pkgs: bw-pass: do not set 'phases' 2021-08-31 18:59:05 +02:00
2c81416774 pkgs: havm: use 'checkInputs' for test dependency 2021-08-31 18:44:17 +02:00
9a5bba7574 home: wm: i3bar: remove redundant '%' 2021-08-31 18:31:32 +02:00
bf6af94bec modules: services: paperless: proxy websockets 2021-08-31 13:52:11 +02:00
14d56a1337 machines: porthos: services: enable paperless 2021-08-31 13:52:11 +02:00
23484989a6 modules: services: paperless: add admin password
This is a fallback in case SSO stops working...
2021-08-31 13:52:11 +02:00
197f371ca9 secrets: add paperless password
To be used as a fallback.
2021-08-31 13:52:11 +02:00
da4595cd39 modules: services: add paperless 2021-08-31 13:52:11 +02:00
2ea68f705d secrets: add paperless 2021-08-31 13:52:11 +02:00
2d12211d3e flake: bump inputs 2021-08-31 13:52:10 +02:00
187c35c448 home: pager: remove lesspipe
I don't use it anymore.
2021-08-30 21:23:13 +02:00
8319f0ea5c modules: services: nginx: nginx-sso verbose logs
For some reason it still doesn't appear in the systemd log...
2021-08-30 17:38:25 +02:00
fd898df590 modules: services: nginx: add SSO 2021-08-30 17:36:39 +02:00
52079bf1e7 modules: services: nginx: enable explicitly 2021-08-30 17:36:39 +02:00
878759cb77 secrets: add sso 2021-08-30 17:36:39 +02:00
fd526b674b secrets: allow lists in types 2021-08-30 15:35:00 +02:00
77cf3430ae modules: services: use new nginx wrapper
And when not possible, document why.

Note for the future: there is some repetition in some modules to
configure the correct value of the subdomain, which I happen to know
will line up correctly thanks to the nginx wrapper. A good way to
refactor this in the future would involve avoiding this repetition,
allowing use to query the correct domain in some way...
2021-08-26 15:54:13 +02:00
a8514dcdf1 modules: services: nginx: overhaul modularity
This should be all that's needed for almost all my services.
2021-08-26 15:54:13 +02:00
906202b222 lib: lists: add countValues 2021-08-26 15:54:13 +02:00
7d2c43d157 lib: lists: add 'mapFilter' 2021-08-26 15:54:13 +02:00
3736e3a415 home: zsh: clean-up blank in history 2021-08-25 12:51:38 +02:00
e2546bd958 home: zsh: append to history
Otherwise the file is replaced rather than appended to.
2021-08-25 12:44:42 +02:00
3d7420210a home: zsh: do not share history accross shells
It's more annoying than helpful...
2021-08-25 12:22:36 +02:00
fcc3089e77 home: gdb: fix configuration path
Turns out the latest version of `gdb` does not yet look for its
configuration in `XDG_CONFIG_HOME`...
2021-08-22 15:02:57 +02:00
b20ef7f809 home: gdb: add rr 2021-08-21 01:13:14 +02:00
5edffcd21d home: gdb: fix auto-load safe path 2021-08-20 21:22:27 +02:00
bc6761bdc9 home: add gdb 2021-08-20 20:03:51 +02:00
087794433e modules: services: nextcloud: exclude previews 2021-08-19 14:27:40 +02:00
98c2f16eb2 modules: services: backup: make it verbose 2021-08-19 14:27:40 +02:00
0fe9a57458 machines: porthos: services: enable navidrome 2021-08-19 12:23:06 +02:00
c228916072 modules: services: add navidrome 2021-08-19 12:23:06 +02:00
414e181a8b flake: bump inputs 2021-08-19 11:49:41 +02:00
7d09677792 modules: services: backup: fix exclude files
I was using the wrong option... Somehow it didn't error out.
2021-08-09 20:08:43 +02:00
cf2747a98f pkgs: add drone-scp 2021-08-08 18:03:19 +02:00
d679262c6f pkgs: unified-hosts-lists: 3.6.4 -> 3.8.5 2021-08-07 12:29:41 +02:00
e1fddb0b1f pkgs: bw-pass: report errors to stderr
Useful in case the script can't prompt using `rofi`.
2021-07-31 20:17:37 +02:00
6c3662dbb3 modules: services: tlp: add power scaling 2021-07-31 16:56:20 +02:00
19c5cd0e13 modules: services: nextcloud: upgrade version 2021-07-29 13:42:28 +02:00
522d1f49df flake: bump inputs
And update package names for grafana dashboards to avoid breaking the
config.
2021-07-29 13:42:28 +02:00
3459067cd4 modules: services: postgres: upgrade version 2021-07-29 13:03:10 +02:00
5d21cecee7 modules: services: postgres: add migration script
The process to upgrade is:

* Make sure the version number of the script is one major version over
  the service version.

* Activate the script, rebuild configuration.

* Run `upgrade-pg-cluster` as `root`. One can give arguments like
  `--link` or `--jobs 4` to speedup the process. See documentation for
  some details.

* Change package to new version once the upgrade is finished, rebuild
  configuration.

* Optionally, `ANALYZE` the new database.
2021-07-29 13:02:49 +02:00
99c33cd7ad modules: services: add postgresql
Enable the service itself in other modules when needed, but pin the
package in a single place.
2021-07-29 12:43:28 +02:00
eba977b582 modules: services: monitoring: add scrape interval 2021-07-15 18:54:07 +02:00
2bfbda9942 flake: flatten and filter packages w/ flake-utils
Instead of my home-grown solution, use one that has been upstreamed.
2021-07-14 21:49:31 +02:00
2291d6b6fa machines: porthos: services: enable monitoring 2021-07-13 19:17:33 +02:00
e342934718 secrets: add monitoring password 2021-07-13 19:17:33 +02:00
24028669f4 modules: services: add monitoring dashboard 2021-07-13 19:17:33 +02:00
c910b643da modules: services: add monitoring
This includes a dashboard to monitor system ressources, using
Prometheus.
2021-07-13 19:17:33 +02:00
9fa16a9b33 flake: bump inputs 2021-07-13 19:08:54 +02:00
7469fe0063 home: git: use topological order in log
It is the one that makes most sense, rather than some kind of date
order...
2021-07-13 17:50:44 +02:00
5fcc96ab77 modules: services: matrix: SSL only for server
This is a requirement anyway for homeservers, and the `forceSSL` option
tried to create a redirect for non-SSL traffic, except the `listen`
option only provided SSL endpoints anyway, so this resulted in
additional rules in the nginx config looking like this:

```nginx
server {
        server_name matrix.belanyi.fr ;
        location /.well-known/acme-challenge {
                root /var/lib/acme/acme-challenge;
                auth_basic off;
        }
        location / {
                return 301 https://$host$request_uri;
        }
}
```
2021-07-13 17:43:31 +02:00
cdbd37b506 pkgs: bw-pass: change password prompt 2021-07-04 11:52:07 +02:00
222d9f789d overlays: transgui: correctly use previous patches 2021-07-04 11:52:07 +02:00
1a492c6eb8 home: direnv: update to new option name
And enable the flakes option.

I don't actually use this on my own projects, but it could be useful for
other projects that I contribute to.
2021-06-30 20:08:07 +02:00
6ff1a53a35 home: mail: add himalaya
This mail client is very KISS. I like it.
2021-06-30 20:08:06 +02:00
8d5c9c58d8 flake: bump inputs 2021-06-30 20:07:55 +02:00
62488bc671 home: firefox: add sponsorblock 2021-06-27 19:51:04 +02:00
fb2ec8cd6b home: secrets: use more specific type
I will amend it if I need more types, but for now this is fine.
2021-06-27 19:48:42 +02:00
7f8b661309 secrets: use more specific type
I will amend it if I need more types, but for now this is fine.
2021-06-27 19:48:26 +02:00
4b6f6423db modules: hardware: sound: refactor options
Do not enable ALSA when using pipewire. Ensure that both pulseaudio and
pipewire are not configured at the same time.
2021-06-27 01:59:07 +02:00
a5d3f7f861 home: wm: i3: also toggle xss-lock 2021-06-26 18:38:11 +02:00
85ff634331 modules: move home configuration from flake 2021-06-25 20:46:36 +02:00
76cac9af51 modules: change username configuration option
It makes more sense to have a `my.user` option.
2021-06-25 20:45:36 +02:00
0ff730bf44 home: zsh: explicitly set history save size
Turns out the `history.save` limit is for what is *loaded into memory*,
not what is written to disk.
2021-06-23 23:14:05 +02:00
0970ab71eb home: zsh: explicitly opt out of extended history 2021-06-23 23:13:39 +02:00
e8f664c949 home: wm: dunst: use rofi as 'dmenu' when enabled 2021-06-23 23:08:23 +02:00
43786904b4 home: wm: i3: enable rofi bindings when applicable 2021-06-23 23:06:15 +02:00
2b200fc98e home: wm: dunst: add line wrapping
Once again, trying to make them actually readable.
2021-06-22 19:48:03 +02:00
1d26e5146c home: wm: dunst: add max icon size
Otherwise I end up with icons that are way too big...
2021-06-22 19:39:35 +02:00
54d7c713a8 pkgs: matrix-notifier: 0.1.2 -> 0.2.0
`pandoc` is now a dependency.
2021-06-16 21:19:09 +02:00
5fa2b1fed9 pkgs: use 'lib' as first input
This is the idiomatic style in nixpkgs.
2021-06-16 20:13:25 +02:00
9bb09ee8f4 modules: services: indexers: limit Jackett memory 2021-06-15 21:25:56 +02:00
b7301b54c0 pkgs: matrix-notifier: 0.1.0 -> 0.1.2 2021-06-15 18:42:13 +02:00
48859859eb home: wm: screen-lock: use actual assertion
Instead of hijacking the type verification, use an assertion.
2021-06-15 17:45:17 +02:00
e4d3d8a949 modules: system: add boot
And enable mounting `/tmp` as tmpfs by default.
2021-06-14 16:41:28 +02:00
dd1742b5b8 ci: migrate to 'exec' runner
Now that I have written a script to do the Matrix notification, I can do
that.
2021-06-13 18:38:09 +02:00
40380be139 pkgs: add matrix-notifier 2021-06-13 18:37:11 +02:00
ecae28a72f home: secrets: clean-up 'default.nix' 2021-06-12 20:35:28 +02:00
a4cce8a561 secrets: clean-up 'default.nix' 2021-06-12 20:35:06 +02:00
aec2e08062 flake: filter 'packages' on system 2021-06-12 19:56:17 +02:00
5d3204715a pkgs: bw-pass: fix 'meta.platforms'
This makes use of 'keyutils' which only works on Linux.
2021-06-12 19:30:25 +02:00
902539ea6d modules: system: documentation: include POSIX man 2021-06-12 13:23:09 +02:00
23e5ddd7f3 modules: services: matrix: add mail configuration 2021-06-09 19:14:09 +02:00
4601a55253 secrets: matrix: add mail configuration 2021-06-09 19:14:09 +02:00
4c4c8ea4e5 modules: services: matrix: enable spaces 2021-06-09 18:33:54 +02:00
ce8138eb07 modules: services: matrix: add SMS verification 2021-06-09 18:32:59 +02:00
5bb28a9396 home: firefox: tridactyl: add tabduplicate mapping 2021-06-07 17:56:46 +02:00
c6ab0e1b00 machines: aramis: profiles: enable devices 2021-06-07 17:56:46 +02:00
851da6b72f profiles: add devices 2021-06-07 17:56:46 +02:00
a5d63dcf65 modules: hardware: add mx-ergo
This adds the ability to scroll using the ball, which is way better.
2021-06-07 17:56:46 +02:00
e7723d5275 home: wm: i3: remove 'udiskie' and 'flameshot'
It makes more sense to activate those at the `profile` level.
2021-06-03 17:34:16 +02:00
4ec380e128 profiles: wm: enable 'i3' helpers
`flameshot` and `udiskie` provide some functionnality that would usually
be found in an actual DE.

It makes more sense to activate them here instead of in the home
configuration, so I will remove it in the next commit.
2021-06-03 17:33:13 +02:00
0cf077012d home: wm: i3: move script generation out-of-line
This makes for a cleaner configuration file.
2021-06-03 17:18:33 +02:00
a465955a28 git: ignore generated pre-commit configuration 2021-05-31 23:06:37 +02:00
4b9d686c97 nix: evaluate shell hooks
This activates the pre-commit-hook configuration.
2021-05-31 23:06:20 +02:00
1699382e4e flake: add pre-commit-hooks
Instead of havin the tool manage versions, use a pinned version.
2021-05-31 23:04:08 +02:00
21fa1ccdac flake: change format 2021-05-31 23:02:32 +02:00
cd0fe40c94 machines: aramis: hardware: enable trackpoint 2021-05-31 20:30:36 +02:00
9d96899065 modules: home: use 'username' config value 2021-05-30 01:31:05 +02:00
ba15ad9674 flake: use 'username' config value 2021-05-30 01:20:14 +02:00
3cc933de81 home: zsh: remove trailing whitespace 2021-05-30 00:46:09 +02:00
22a01eeadf modules: system: users: make it configurable
Notably, make use of my global 'username' option.
2021-05-30 00:46:09 +02:00
558f9b3919 modules: add option to specify username
Given that I use it in plenty of places, it makes sense to place it
there for reference in other modules.
2021-05-30 00:46:09 +02:00
c23d89dcb2 modules: system: packages: make it configurable 2021-05-30 00:46:09 +02:00
7916a26a58 modules: system: nix: make it configurable 2021-05-30 00:46:09 +02:00
565d40fefb modules: system: language: make it configurable 2021-05-30 00:46:09 +02:00
a3eaa6d97e modules: system: move 'packages' 2021-05-29 16:58:44 +02:00
130e04a152 modules: system: move 'nix' 2021-05-29 16:58:44 +02:00
43ef533ae1 modules: system: move 'documentation' 2021-05-29 16:58:44 +02:00
377c97ea9f modules: system: move 'language' 2021-05-29 16:58:44 +02:00
7f285ab9cf modules: system: move 'users' 2021-05-29 16:58:44 +02:00
50a5347802 modules: system: move 'media' 2021-05-29 16:56:15 +02:00
3ff50b1c22 modules: add 'system' directory 2021-05-29 16:56:15 +02:00
9b568beb9a modules: move 'services' into subfolder 2021-05-29 16:56:15 +02:00
274b909971 modules: hardware: move 'upower' 2021-05-29 16:56:15 +02:00
dd19b9dd92 modules: hardware: move 'sound' 2021-05-29 16:56:15 +02:00
5f0c1f6a79 modules: hardware: move 'networking' 2021-05-29 16:56:15 +02:00
abbe1bb203 modules: hardware: move 'ergodox' 2021-05-29 16:56:15 +02:00
ec1bc63de7 modules: hardware: move 'bluetooth' 2021-05-29 16:56:15 +02:00
66cd746e53 modules: add 'hardware' directory 2021-05-29 16:56:15 +02:00
36344fe924 modules: ergodox: remove useless group clause
The `zsa` module already add the group itself.
2021-05-29 16:15:20 +02:00
cdb8f0d0a7 flake: bump inputs 2021-05-29 12:23:01 +02:00
1f861e4d50 services: jellyfin: fix proxy configuration 2021-05-28 11:38:28 +02:00
90a89c56c8 home: comma: configure custom 'nixpkgs' flake
This makes use of my pinned `pkgs` flake from the registry by default.
2021-05-27 21:50:27 +02:00
b95b357251 home: extract 'comma' into its own module 2021-05-27 21:49:24 +02:00
60309fad02 pkgs: comma: allow override which nixpkgs is used
This is useful for me to use my pinned `pkgs` instead.
2021-05-27 21:42:41 +02:00
b8f1f85bc2 pkgs: add volantes-cursors 2021-05-27 19:57:31 +02:00
8bb4948eec home: x: cursor: switch to Vimix 2021-05-27 19:15:52 +02:00
bcdb6dbe64 pkgs: add vimix-cursors 2021-05-27 19:15:52 +02:00
a223ca6072 home: git: add 'pick' alias
I wanted to name it 'pickaxe' but for a curious reason, it does not seem
to be working when I use that alias...

I am trying to find a second alias name for `git log -p -S`, which only
shows commits that change the number of occurrences of its pickaxe in
the file. Whereas `-G` shows any commit involving the pickaxe in its
diff.
2021-05-25 23:13:35 +02:00
d5307ff551 machines: aramis: sound: switch to pipewire
The support for mSBC means I should get better audio on my QC35.
2021-05-25 23:13:35 +02:00
a648fc6d0f home: wm: i3: use pamixer for audio control
This can be used with either pipewire and pulseaudio without having to
install all of pulseaudio.
2021-05-25 23:13:35 +02:00
da6c160baf modules: bluetooth: add pipewire codecs 2021-05-25 23:13:35 +02:00
10434bdbfc modules: sound: add pipewire configuration 2021-05-25 18:19:52 +02:00
941913e213 machines: aramis: sound: use common module 2021-05-25 18:19:52 +02:00
20513ab3a2 modules: add sound
I will probably want to share this configuration between multiple
machines in the future.
2021-05-25 18:19:52 +02:00
d986f2f906 services: podgrab: remove mention of merged PR 2021-05-23 00:32:59 +02:00
ec36d1c1b7 project: readme: mention manual flood config 2021-05-23 00:14:26 +02:00
d18fc252a4 machines: porthos: services: enable flood 2021-05-22 23:59:27 +02:00
beb35737d9 services: add flood 2021-05-22 23:59:27 +02:00
d43a224da0 home: wm: i3bar: invert baclight icon
Because I am using an emoji font, it looks better that way.
2021-05-22 23:59:27 +02:00
b3653a63bd home: mail: add msmtp 2021-05-22 23:49:57 +02:00
0452d696ae home: add mail and accounts configuration 2021-05-22 23:49:57 +02:00
7a91bf3906 home: terminal: use 'cfg.terminal' for TERMINAL 2021-05-22 23:49:57 +02:00
153f919485 pkgs: add bw-pass
Until `rbw` gets support for Yubikey 2FA, I still need a decent way to
query for my passwords on the command line...

This wrapper program should be good enough for basic usage with programs
that need a password command.
2021-05-22 23:49:57 +02:00
1647ab4ac7 modules: nix: expose pinned nixpkgs as 'pkgs'
That way if I do want to use that latest version, I can still use
`nixpkgs#<whatever>`.
2021-05-22 23:49:57 +02:00
bab605871d home: firefox: tridactyl: fix Reddit URL rewriter 2021-05-22 23:49:57 +02:00
cfa59614f1 home: firefox: add ff2mpv
This allows watching videos using mpv via a simple button.
2021-05-22 23:49:57 +02:00
93f173d0ca machines: aramis: home: enable mpv 2021-05-22 23:49:57 +02:00
82099b19f3 home: add mpv 2021-05-22 23:49:57 +02:00
4d0ab2e5a6 pkgs: add ff2mpv-go 2021-05-22 23:49:57 +02:00
2c8770ad70 services: podgrab: switch to upstream service 2021-05-22 23:49:57 +02:00
8e278e0f99 pkgs: remove podgrab
Now that it has been merged upstream, no reason to keep it.
2021-05-22 23:49:02 +02:00
4fcad6026a modules: nix: pin flake registry to common inputs 2021-05-22 23:47:27 +02:00
6b50f906fa flake: inject 'inputs' into NixOS configuration 2021-05-22 23:47:27 +02:00
7f0c595ae8 home: wm: rofi: configure terminal 2021-05-22 23:47:27 +02:00
bbddf086ec profiles: laptop: enable TLP 2021-05-22 23:47:27 +02:00
9a9d0ba266 services: add TLP 2021-05-22 23:47:27 +02:00
faad0c0624 pkgs: add myself as maintainer to all packages 2021-05-22 23:47:27 +02:00
0dc9495fda home: add nix-index 2021-05-22 23:47:27 +02:00
05f291f72a services: adblock: use new 'settings' option
This shows that I have not upgraded the server in a while...
2021-05-22 23:47:27 +02:00
f376059027 flake: bump inputs 2021-05-20 17:55:45 +02:00
9e5d616d16 home: firefox: tridactyl: fix parent URL on Reddit 2021-05-16 00:03:59 +02:00
1d97eb22bf home: packages: add 'comma' to common package set 2021-05-16 00:03:59 +02:00
7087ce32a6 pkgs: add comma 2021-05-16 00:03:59 +02:00
797387f571 machines: aramis: services: remove gnupg-agent
The one configured by home-manager is more appropriate.
2021-05-16 00:03:59 +02:00
ec73ed2f10 home: x: add 'xsel' package
I like it better than 'xclip'.
2021-05-16 00:03:59 +02:00
684dac5904 home: zsh: make history ten times bigger 2021-05-16 00:03:59 +02:00
467cfaa066 profiles: laptop: enable power-alert 2021-05-16 00:03:59 +02:00
2ba551f1b0 home: add power-alert 2021-05-16 00:03:59 +02:00
2128286779 profiles: laptop: enable upower 2021-05-16 00:03:59 +02:00
853bb7a0ce modules: add upower 2021-05-16 00:03:59 +02:00
abdba0a223 home: pager: fix colorized man pages
Turns out that sessionVariables are not being set at the proper time for
use with `tput`.

This commit also cleans up a bit how the config was being set.
2021-05-16 00:03:59 +02:00
d87f37c572 home: wm: i3bar: add 'backlight' block 2021-05-16 00:03:59 +02:00
226b8f7b6a home: wm: i3bar: remove gammastep block
It doesn't seem to be working well with my setup...
2021-05-16 00:03:59 +02:00
62ac22a8c5 home: wm: i3: use 'brightnessctl' 2021-05-16 00:03:59 +02:00
27c11b9b67 home: wm: i3: fix screen-related mappings 2021-05-16 00:03:59 +02:00
996d61b0f4 modules: users: simplify 'groupsIfExist' 2021-05-16 00:03:59 +02:00
62cee0be61 machines: porthos: set timezone 2021-05-16 00:03:59 +02:00
6c4f494a42 machines: aramis: use laptop profile 2021-05-16 00:03:59 +02:00
cd967ccf99 profiles: add laptop 2021-05-16 00:03:59 +02:00
4fb46a6c58 machines: aramis: use X profile 2021-05-16 00:03:59 +02:00
e7d8548b80 profiles: add X 2021-05-16 00:03:59 +02:00
10adc23223 machines: aramis: use gtk profile 2021-05-16 00:03:59 +02:00
7f945f86a6 profiles: add gtk 2021-05-16 00:03:59 +02:00
4960179f9d machines: aramis: use wm profile 2021-05-16 00:03:59 +02:00
8c7d5cdb30 profiles: add wm 2021-05-16 00:03:59 +02:00
4650c47974 modules: bluetooth: fix documentation 2021-05-16 00:03:59 +02:00
28cc5b64b4 machines: aramis: enable bluetooth profile 2021-05-16 00:03:59 +02:00
4fbb3d53e9 profiles: add bluetooth 2021-05-16 00:03:59 +02:00
d2c9b72eb6 flake: add profiles folder
This will be used for configurations that either consolidates multiple options
that make sens to use together, or span accross system and home configuration.
2021-05-16 00:03:59 +02:00
104a7a8d46 home: gtk: do not set font size
Turns out that I do not like how it interferes with Firefox's
rendering... I should probably investigate this in the future if I want
to use this option.
2021-05-16 00:03:59 +02:00
229ecd18ce machines: aramis: home: enable GTK
In order to not have an error at activation, dconf must be made
available to the dbus service.
2021-05-10 00:31:01 +02:00
c6ee3a0351 home: add gtk 2021-05-10 00:31:01 +02:00
e12b3a9599 machines: aramis: home: add transgui 2021-05-10 00:31:01 +02:00
9ecdc7c1ed overlays: add transgui-fix-duplicate-status
Upstream is being slow in merging the patch...
2021-05-10 00:31:01 +02:00
96c9b1b57d flake: add overlays folder 2021-05-10 00:31:01 +02:00
a4b54f3630 machines: aramis: home: add jellyfin-media-player 2021-05-10 00:31:01 +02:00
ec7f62f7bc home: terminal: export TERMINAL when appropriate
This is used by some programs, like 'rofi' to launch terminal programs.
2021-05-10 00:31:01 +02:00
2daaaed37f pkgs: i3-get-window-criteria: remove whitespace 2021-05-10 00:31:01 +02:00
c7fccd3ed3 home: wm: i3: add i3-get-window-criteria package 2021-05-10 00:31:01 +02:00
2d21945670 pkgs: add i3-get-window-criteria 2021-05-10 00:31:01 +02:00
a7839c63e0 machines: aramis: home: enable feh 2021-05-10 00:31:01 +02:00
e82d510c0c home: add feh 2021-05-10 00:31:01 +02:00
384e801553 machines: aramis: home: set up background
`i3` inherits its background from `lightdm`.
2021-05-10 00:31:01 +02:00
b2e0e81216 home: packages: add 'file' to common package set 2021-05-10 00:31:01 +02:00
d36cb23fa3 home: pager: add colored man page support 2021-05-10 00:31:01 +02:00
1bb9367470 machines: aramis: add some additional packages 2021-05-10 00:31:01 +02:00
0a8effa09f home: packages: add option for additional packages 2021-05-10 00:31:01 +02:00
ddffa1f247 modules: documentation: add linux man pages option
I want to be able to read about syscalls or the C library.
2021-05-10 00:31:01 +02:00
2b6399606a modules: documentation: use 'mkDisableOption'
The documentation module already gates behind 'documentation.enable' for
the other options.
2021-05-10 00:31:01 +02:00
7e1ca1f3d5 home: x: add cursor
I would like to check out alternative themes. Notably Quintom [1],
Volantes [2], and Vimix [3].

[1]: https://gitlab.com/Burning_Cube/quintom-cursor-theme
[2]: https://github.com/varlesh/volantes-cursors
[3]: https://github.com/vinceliuice/Vimix-cursors
2021-05-10 00:31:01 +02:00
c4bc609b7e machines: aramis: home: enable bluetooth 2021-05-10 00:31:01 +02:00
91954e9a02 home: add bluetooth 2021-05-10 00:31:01 +02:00
0c8eea0fb4 home: wm: i3bar: use FontAwesome5 for icons 2021-05-10 00:31:01 +02:00
5930fc0d3b home: wm: i3: use new 'fonts' option type 2021-05-10 00:31:01 +02:00
554620f004 flake: bump inputs 2021-05-10 00:31:01 +02:00
432cd97b53 machines: aramis: enable bluetooth 2021-05-10 00:31:01 +02:00
35b8de02c2 modules: add bluetooth 2021-05-10 00:31:01 +02:00
4319105aa5 machines: aramis: networking: use wireless option 2021-05-10 00:31:01 +02:00
8013120856 modules: networking: add 'wireless' option 2021-05-10 00:31:01 +02:00
8755d84b21 machines: aramis: install: exit on error 2021-05-10 00:31:01 +02:00
ed1539ae29 machines: aramis: home: enable nm-applet 2021-05-10 00:31:01 +02:00
40fa4798e1 home: add nm-applet 2021-05-10 00:31:01 +02:00
165e26f0b3 modules: users: add myself to 'networkmanager' 2021-05-08 17:14:13 +02:00
0a7a2c5c90 machine: aramis: networking: use networkmanager
I consider WiFi configurations to be ephemeral
2021-05-08 17:14:13 +02:00
3f35f9e440 home: gammastep: show tray icon 2021-05-08 17:14:13 +02:00
d111e16bea home: gammastep: change default night temperature
I want the colour to be warmer, and blues even more attenuated.
2021-05-08 17:14:13 +02:00
e0fe15aa2b home: wm: i3: add mic mute media key 2021-05-08 17:14:13 +02:00
ec8ea63fcb home: wm: i3: fix audio media keys 2021-05-08 17:14:13 +02:00
7a85b04541 home: wm: i3bar: extend width of music block 2021-05-08 17:14:13 +02:00
b52c55db5f home: wm: i3bar: show temperature block by default 2021-05-08 17:14:13 +02:00
eba01a0067 home: zsh: enable VTE integration when appropriate 2021-05-08 17:14:13 +02:00
4c154c7216 machines: aramis: services: enable wireguard 2021-05-08 17:14:13 +02:00
f8a1480d09 home: wm: screen-lock: add 'notify.delay' setting 2021-05-08 17:14:13 +02:00
e5b5e73294 home: wm: screen-lock: add corner delay setting 2021-05-08 17:14:13 +02:00
5973841ff5 modules: users: reformat 2021-05-08 17:14:13 +02:00
3177d01157 home: firefox: add form-history-control extension 2021-05-08 17:14:13 +02:00
7c17b675f6 home: wm: i3: use keycode for shutdown mapping
The motivation for using keycodes for all those mappings is to allow
switch to an actual french keyboard layout it still be able to move
through workspaces etc...
2021-05-08 17:14:13 +02:00
22642908dd machines: aramis: home: use GTK pinentry
I do have a graphical session, I can afford to be "fancy"
2021-05-08 17:14:13 +02:00
f96bc19bf6 home: gpg: make pinentry configurable 2021-05-08 17:14:13 +02:00
2dbb25a9e3 modules: packages: prefer user compinit to global
This should make the shell startup faster.
2021-05-08 17:14:13 +02:00
a4abc2edd8 project: bootstrap: unlock BW when logged in 2021-05-08 17:14:13 +02:00
ad2c5dd209 home: wm: i3: add display bindings 2021-05-08 17:14:13 +02:00
6cea859693 home: wm: i3: add dunst bindings 2021-05-08 17:14:13 +02:00
33752d2bcb home: wm: i3: add binding to toggle xautolock 2021-05-08 17:14:13 +02:00
5042c1df20 home: wm: screen-lock: add xautolock options 2021-05-08 17:14:13 +02:00
46b3a32b82 home: wm: add screen-lock 2021-05-08 17:14:13 +02:00
79d92178b5 home: wm: dunst: add configuration 2021-05-08 17:14:13 +02:00
3344b079dc home: wm: add dunst 2021-05-08 17:14:13 +02:00
c56517497a home: wm: use explicit 'enable' options
This is so that I can explicitly enable them if I were to use Wayland
and Sway, given that they should be compatible with both environment.

This also means that putting them in `/home/x/` would a misnomer... Will
revisit this if and when I try out Wayland and sway...
2021-05-08 17:14:13 +02:00
38a475d35d modules: users: add myself to 'video' and 'audio' 2021-05-08 17:14:13 +02:00
c6ebb9d45f home: wm: i3bar: hide music block when not playing 2021-05-08 17:14:13 +02:00
44c66ab729 home: wm: i3bar: add gammastep block if enabled 2021-05-08 17:14:13 +02:00
f608bcd9f9 machines: aramis: home: enable gammastep 2021-05-08 17:14:13 +02:00
b3fffcac3e home: add gammastep 2021-05-08 17:14:13 +02:00
873c41745a home: firefox: add tridactyl 2021-05-08 17:14:13 +02:00
dadd835b66 home: firefox: use tridactyl-native when enabled 2021-05-08 17:14:13 +02:00
1587b992da machines: aramis: home: enable firefox 2021-05-08 17:14:13 +02:00
38440f67ab home: add firefox 2021-05-08 17:14:13 +02:00
85f4220068 home: wm: i3: use udiskie service 2021-05-08 17:14:13 +02:00
43457ce41e home: add udiskie 2021-05-08 17:14:13 +02:00
44cad6b52b home: wm: i3: use flameshot service directly
Instead of starting `flameshot` with `i3`, use the provided service.
2021-05-08 17:14:13 +02:00
86b12dc8a8 home: add flameshot 2021-05-08 17:14:13 +02:00
61b36c5434 machines: aramis: home: enable zathura 2021-05-08 17:14:13 +02:00
bc6c50aff1 home: add zathura 2021-05-08 17:14:13 +02:00
3aa089db36 machines: aramis: home: enable termite 2021-05-08 17:14:13 +02:00
b7b1c77dc8 home: wm: i3: use 'my.home.terminal' explicitly 2021-05-08 17:14:13 +02:00
07b91de2f2 home: terminal: add termite 2021-05-08 17:14:13 +02:00
a4f3d67393 home: add terminal
This module abstracts away the color configuration.
2021-05-08 17:14:13 +02:00
b983136080 home: wm: i3: add configuration 2021-05-08 17:14:13 +02:00
f257c15071 home: wm: add rofi 2021-05-08 17:14:13 +02:00
82790ea5fa home: wm: add i3bar 2021-05-08 17:14:13 +02:00
3d51af4f54 machines: aramis: home: enable X & i3 2021-05-08 17:14:13 +02:00
6af00fe351 machines: aramis: add home configuration 2021-05-08 17:14:13 +02:00
864e78bc61 modules: add home
This makes setting and referring to my home-manager options easier.
2021-05-08 17:14:13 +02:00
ca48df5674 home: wm: add i3
This is only the basic default configuration. The full configuration
will come later.

I am not a fan of `wm.windowManager`, I might rename that option at some
point.
2021-05-08 17:14:13 +02:00
ff4745e1e6 home: add X keyboard configuration 2021-05-08 17:14:13 +02:00
63791a98a4 machines: add aramis 2021-05-08 17:14:13 +02:00
9690b0b14b lib: attrs: add renaming functions 2021-05-08 17:14:13 +02:00
af317ac156 lib: attrs: document functions 2021-05-08 17:14:13 +02:00
b30d574069 lib: attrs: add genAttrs' function 2021-05-08 17:14:13 +02:00
825e09f59e flake: refactor handling of shared modules 2021-05-08 17:14:13 +02:00
817ca1e9df machine: aramis: add installer script
This is the first time that I am setting up LVM-on-LUKS with NixOS, so a
VM came in handy to test it out.
2021-05-08 17:14:13 +02:00
411 changed files with 10308 additions and 2266 deletions

View file

@ -1,24 +0,0 @@
kind: pipeline
name: check config
steps:
- name: format check
image: nixos/nix
commands:
- nix-shell -p nixpkgs-fmt --run 'nixpkgs-fmt . --check'
- name: notify
image: plugins/matrix
settings:
homeserver:
from_secret: matrix_homeserver
roomid:
from_secret: matrix_roomid
username:
from_secret: matrix_username
password:
from_secret: matrix_password
trigger:
status:
- failure
- success

14
.envrc
View file

@ -1,8 +1,10 @@
use_flake() {
watch_file flake.nix
watch_file flake.lock
eval "$(nix print-dev-env)"
}
if ! has nix_direnv_version || ! nix_direnv_version 2.2.1; then
source_url "https://raw.githubusercontent.com/nix-community/nix-direnv/2.2.1/direnvrc" "sha256-zelF0vLbEl5uaqrfIzbgNzJWGmLzCmYAkInj/LNxvKs="
fi
ulimit -s unlimited # Bypass current bug in `nix` flakes evaluation
use flake
watch_file ./flake/checks.nix
watch_file ./flake/dev-shells.nix
eval "$shellHooks"

View file

@ -1,4 +0,0 @@
# Do not edit this file. To specify the files to encrypt, create your own
# .gitattributes file in the directory where your files are.
* !filter !diff
*.gpg binary

1
.gitignore vendored Normal file
View file

@ -0,0 +1 @@
/.pre-commit-config.yaml

View file

@ -1,21 +0,0 @@
repos:
- repo: 'https://github.com/pre-commit/pre-commit-hooks'
rev: 'v2.3.0'
hooks:
- id: 'trailing-whitespace'
- id: 'end-of-file-fixer'
- id: 'check-yaml'
- id: 'check-added-large-files'
- repo: 'https://github.com/jumanjihouse/pre-commit-hooks'
rev: '2.1.4'
hooks:
- id: 'forbid-binary'
- repo: 'local'
hooks:
- id: 'nixpkgs-fmt'
name: 'nixpkgs-fmt'
description: 'Format nix code with nixpkgs-fmt'
entry: 'nixpkgs-fmt'
language: 'system'
files: '\.nix$'
always_run: true

1
.stylua.toml Normal file
View file

@ -0,0 +1 @@
indent_type = "Spaces"

26
.woodpecker/check.yml Normal file
View file

@ -0,0 +1,26 @@
labels:
backend: local
pipeline:
- name: nix flake check
image: bash
commands:
- nix flake check
- name: notifiy
image: bash
secrets:
- source: matrix_homeserver
target: address
- source: matrix_roomid
target: room
- source: matrix_username
target: user
- source: matrix_password
target: pass
commands:
- nix run '.#matrix-notifier'
when:
status:
- failure
- success

View file

@ -17,7 +17,8 @@ Secondly, take care of a few manual steps:
* Configure Gitea and Drone
* Configure Lohr webhook and SSH key
* Configure Jellyfin
* Configure Jackett and NZBHydra2
* Configure Prowlarr,Jackett and NZBHydra2
* Configure Sonarr, Radarr, Bazarr
* Configure Transmission's webui port
* Configure Quassel user
* Configure Flood account

View file

@ -1,5 +1,5 @@
#!/usr/bin/env nix-shell
#! nix-shell -i bash -p bitwarden-cli git gnupg jq nixFlakes
#! nix-shell -i bash -p bitwarden-cli git gnupg jq nix
# Command failure is script failure
set -e
@ -58,6 +58,8 @@ get_ssh() {
get_doc "SysAdmin/SSH" "shared-key-public" "$HOME/.ssh/shared_rsa.pub" 644
get_doc "SysAdmin/SSH" "shared-key-private" "$HOME/.ssh/shared_rsa" 600
get_doc "SysAdmin/SSH" "agenix-public" "$HOME/.ssh/agenix.pub" 644
get_doc "SysAdmin/SSH" "agenix-private" "$HOME/.ssh/agenix" 600
}
get_pgp() {
@ -78,22 +80,13 @@ get_pgp() {
}
get_creds() {
BW_SESSION="$(bw login --raw)"
BW_SESSION="$(bw login --raw || bw unlock --raw)"
export BW_SESSION
get_ssh
get_pgp
}
setup_gpg() {
info 'Setting up loopback pinentry for GnuPG'
echo "allow-loopback-pinentry" > ~/.gnupg/gpg-agent.conf
info 'Signing dummy message to ensure GnuPG key is usable by `git-crypt`'
echo whatever | gpg --clearsign --armor --pinentry loopback --output /dev/null
}
[ -z "$NOCREDS" ] && get_creds
[ -z "$NOGPG" ] && setup_gpg
nix --experimental-features 'nix-command flakes' develop

185
flake.lock generated
View file

@ -1,21 +1,129 @@
{
"nodes": {
"futils": {
"agenix": {
"inputs": {
"darwin": "darwin",
"home-manager": [
"home-manager"
],
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1619345332,
"narHash": "sha256-qHnQkEp1uklKTpx3MvKtY6xzgcqXDsz5nLilbbuL+3A=",
"lastModified": 1690228878,
"narHash": "sha256-9Xe7JV0krp4RJC9W9W9WutZVlw6BlHTFMiUP/k48LQY=",
"owner": "ryantm",
"repo": "agenix",
"rev": "d8c973fd228949736dedf61b7f8cc1ece3236792",
"type": "github"
},
"original": {
"owner": "ryantm",
"ref": "main",
"repo": "agenix",
"type": "github"
}
},
"darwin": {
"inputs": {
"nixpkgs": [
"agenix",
"nixpkgs"
]
},
"locked": {
"lastModified": 1673295039,
"narHash": "sha256-AsdYgE8/GPwcelGgrntlijMg4t3hLFJFCRF3tL5WVjA=",
"owner": "lnl7",
"repo": "nix-darwin",
"rev": "87b9d090ad39b25b2400029c64825fc2a8868943",
"type": "github"
},
"original": {
"owner": "lnl7",
"ref": "master",
"repo": "nix-darwin",
"type": "github"
}
},
"flake-compat": {
"flake": false,
"locked": {
"lastModified": 1673956053,
"narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=",
"owner": "edolstra",
"repo": "flake-compat",
"rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9",
"type": "github"
},
"original": {
"owner": "edolstra",
"repo": "flake-compat",
"type": "github"
}
},
"flake-parts": {
"inputs": {
"nixpkgs-lib": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1690933134,
"narHash": "sha256-ab989mN63fQZBFrkk4Q8bYxQCktuHmBIBqUG1jl6/FQ=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "59cf3f1447cfc75087e7273b04b31e689a8599fb",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"ref": "main",
"repo": "flake-parts",
"type": "github"
}
},
"futils": {
"inputs": {
"systems": "systems"
},
"locked": {
"lastModified": 1689068808,
"narHash": "sha256-6ixXo3wt24N/melDWjq70UuHQLxGV8jZvooRanIHXw0=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "2ebf2558e5bf978c7fb8ea927dfaed8fefab2e28",
"rev": "919d646de7be200f3bf08cb76ae1f09402b6f9b4",
"type": "github"
},
"original": {
"owner": "numtide",
"ref": "master",
"ref": "main",
"repo": "flake-utils",
"type": "github"
}
},
"gitignore": {
"inputs": {
"nixpkgs": [
"pre-commit-hooks",
"nixpkgs"
]
},
"locked": {
"lastModified": 1660459072,
"narHash": "sha256-8DFJjXG8zqoONA1vXtgeKXy68KdJL5UaXR8NtVMUbx8=",
"owner": "hercules-ci",
"repo": "gitignore.nix",
"rev": "a20de23b925fd8264fd7fad6454652e142fd7f73",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "gitignore.nix",
"type": "github"
}
},
"home-manager": {
"inputs": {
"nixpkgs": [
@ -23,11 +131,11 @@
]
},
"locked": {
"lastModified": 1619558193,
"narHash": "sha256-DljP5/9EX0eXEPhzCUFqFEHkkcFuXJBx1PTgcv0OgyM=",
"lastModified": 1691039228,
"narHash": "sha256-iPNZJ1LvfUf1Y456ewC0DXgf99TNssG8OLObOyqxO6M=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "18ad12d52b8cebbb57013865eec2be5125de050a",
"rev": "86dd48d70a2e2c17e84e747ba4faa92453e68d4a",
"type": "github"
},
"original": {
@ -39,11 +147,11 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1619464443,
"narHash": "sha256-R7WAb8EnkIJxxaF6GTHUPytjonhB4Zm0iatyWoW169A=",
"lastModified": 1691006197,
"narHash": "sha256-DbtxVWPt+ZP5W0Usg7jAyTomIM//c3Jtfa59Ht7AV8s=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "8e4fe32876ca15e3d5eb3ecd3ca0b224417f5f17",
"rev": "66aedfd010204949cb225cf749be08cb13ce1813",
"type": "github"
},
"original": {
@ -55,11 +163,11 @@
},
"nur": {
"locked": {
"lastModified": 1619628114,
"narHash": "sha256-s3pQyvMfXVmbQOX224yOWQf6zi8406sShFF4u17LVQ0=",
"lastModified": 1691139289,
"narHash": "sha256-cZtqvYztpGwLtAsfrzY2VeTfFdW3HBwX7m1KV2Zy2nw=",
"owner": "nix-community",
"repo": "NUR",
"rev": "0615e756dc14986c4968fa478c0bd080d621cb2b",
"rev": "cb20b89d5b355c53a18dd149e7104a67381c7c17",
"type": "github"
},
"original": {
@ -69,12 +177,59 @@
"type": "github"
}
},
"pre-commit-hooks": {
"inputs": {
"flake-compat": "flake-compat",
"flake-utils": [
"futils"
],
"gitignore": "gitignore",
"nixpkgs": [
"nixpkgs"
],
"nixpkgs-stable": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1691093055,
"narHash": "sha256-sjNWYpDHc6vx+/M0WbBZKltR0Avh2S43UiDbmYtfHt0=",
"owner": "cachix",
"repo": "pre-commit-hooks.nix",
"rev": "ebb43bdacd1af8954d04869c77bc3b61fde515e4",
"type": "github"
},
"original": {
"owner": "cachix",
"ref": "master",
"repo": "pre-commit-hooks.nix",
"type": "github"
}
},
"root": {
"inputs": {
"agenix": "agenix",
"flake-parts": "flake-parts",
"futils": "futils",
"home-manager": "home-manager",
"nixpkgs": "nixpkgs",
"nur": "nur"
"nur": "nur",
"pre-commit-hooks": "pre-commit-hooks"
}
},
"systems": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
}
},

108
flake.nix
View file

@ -1,11 +1,32 @@
{
description = "NixOS configuration with flakes";
inputs = {
agenix = {
type = "github";
owner = "ryantm";
repo = "agenix";
ref = "main";
inputs = {
home-manager.follows = "home-manager";
nixpkgs.follows = "nixpkgs";
};
};
flake-parts = {
type = "github";
owner = "hercules-ci";
repo = "flake-parts";
ref = "main";
inputs = {
nixpkgs-lib.follows = "nixpkgs";
};
};
futils = {
type = "github";
owner = "numtide";
repo = "flake-utils";
ref = "master";
ref = "main";
};
home-manager = {
@ -31,79 +52,20 @@
repo = "NUR";
ref = "master";
};
};
outputs = { self, futils, home-manager, nixpkgs, nur } @ inputs:
let
inherit (futils.lib) eachDefaultSystem;
lib = nixpkgs.lib.extend (self: super: {
my = import ./lib { inherit inputs; pkgs = nixpkgs; lib = self; };
});
defaultModules = [
({ ... }: {
# Let 'nixos-version --json' know about the Git revision
system.configurationRevision = self.rev or "dirty";
})
{
nixpkgs.overlays = (lib.attrValues self.overlays) ++ [
nur.overlay
];
}
home-manager.nixosModules.home-manager
{
home-manager.users.ambroisie = import ./home;
# Nix Flakes compatibility
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
}
];
buildHost = name: system: lib.nixosSystem {
inherit system;
modules = defaultModules ++ [
(./. + "/${name}.nix")
];
specialArgs = {
# Use my extended lib in NixOS configuration
inherit lib;
};
};
in
eachDefaultSystem
(system:
let
pkgs = nixpkgs.legacyPackages.${system};
in
rec {
apps = {
diff-flake = futils.lib.mkApp { drv = packages.diff-flake; };
};
defaultApp = apps.diff-flake;
devShell = pkgs.mkShell {
name = "NixOS-config";
buildInputs = with pkgs; [
git-crypt
gitAndTools.pre-commit
gnupg
nixpkgs-fmt
];
};
packages = import ./pkgs { inherit pkgs; };
}) // {
overlay = self.overlays.pkgs;
overlays = {
lib = final: prev: { inherit lib; };
pkgs = final: prev: { ambroisie = import ./pkgs { pkgs = prev; }; };
};
nixosConfigurations = lib.mapAttrs buildHost {
porthos = "x86_64-linux";
pre-commit-hooks = {
type = "github";
owner = "cachix";
repo = "pre-commit-hooks.nix";
ref = "master";
inputs = {
flake-utils.follows = "futils";
nixpkgs.follows = "nixpkgs";
nixpkgs-stable.follows = "nixpkgs";
};
};
};
# Can't eta-reduce a flake outputs...
outputs = inputs: import ./flake inputs;
}

9
flake/apps.nix Normal file
View file

@ -0,0 +1,9 @@
{ inputs, ... }:
{
perSystem = { self', ... }: {
apps = {
diff-flake = inputs.futils.lib.mkApp { drv = self'.packages.diff-flake; };
default = self'.apps.diff-flake;
};
};
}

33
flake/checks.nix Normal file
View file

@ -0,0 +1,33 @@
{ inputs, ... }:
{
imports = [
inputs.pre-commit-hooks.flakeModule
];
perSystem = { ... }: {
pre-commit = {
# Add itself to `nix flake check`
check.enable = true;
settings = {
hooks = {
deadnix = {
enable = true;
};
nixpkgs-fmt = {
enable = true;
};
shellcheck = {
enable = true;
};
stylua = {
enable = true;
};
};
};
};
};
}

22
flake/default.nix Normal file
View file

@ -0,0 +1,22 @@
{ flake-parts
, futils
, ...
} @ inputs:
let
mySystems = futils.lib.defaultSystems;
in
flake-parts.lib.mkFlake { inherit inputs; } {
systems = mySystems;
imports = [
./apps.nix
./checks.nix
./dev-shells.nix
./home-manager.nix
./lib.nix
./nixos.nix
./overlays.nix
./packages.nix
./templates.nix
];
}

19
flake/dev-shells.nix Normal file
View file

@ -0,0 +1,19 @@
{ ... }:
{
perSystem = { config, pkgs, ... }: {
devShells = {
default = pkgs.mkShellNoCC {
name = "NixOS-config";
nativeBuildInputs = with pkgs; [
gitAndTools.pre-commit
nixpkgs-fmt
];
shellHook = ''
${config.pre-commit.installationScript}
'';
};
};
};
}

61
flake/home-manager.nix Normal file
View file

@ -0,0 +1,61 @@
{ self, inputs, lib, ... }:
let
defaultModules = [
# Include generic settings
"${self}/home"
{
# Basic user information defaults
home.username = lib.mkDefault "ambroisie";
home.homeDirectory = lib.mkDefault "/home/ambroisie";
# Make it a Linux installation by default
targets.genericLinux.enable = lib.mkDefault true;
# Enable home-manager
programs.home-manager.enable = true;
}
];
mkHome = name: system: inputs.home-manager.lib.homeManagerConfiguration {
# Work-around for home-manager
# * not letting me set `lib` as an extraSpecialArgs
# * not respecting `nixpkgs.overlays` [1]
# [1]: https://github.com/nix-community/home-manager/issues/2954
pkgs = import inputs.nixpkgs {
inherit system;
overlays = (lib.attrValues self.overlays) ++ [
inputs.nur.overlay
];
};
modules = defaultModules ++ [
"${self}/hosts/homes/${name}"
];
extraSpecialArgs = {
# Inject inputs to use them in global registry
inherit inputs;
};
};
hosts = {
"ambroisie@ambroisie" = "x86_64-linux"; # Unfortunate naming here...
};
in
{
perSystem = { system, ... }: {
# Work-around for https://github.com/nix-community/home-manager/issues/3075
legacyPackages = {
homeConfigurations =
let
filteredHosts = lib.filterAttrs (_: v: v == system) hosts;
allHosts = filteredHosts // {
# Default configuration
ambroisie = system;
};
in
lib.mapAttrs mkHome allHosts;
};
};
}

11
flake/lib.nix Normal file
View file

@ -0,0 +1,11 @@
{ self, inputs, ... }:
let
inherit (inputs) nixpkgs;
lib = nixpkgs.lib.extend (final: _: {
my = import "${self}/lib" { inherit inputs; pkgs = nixpkgs; lib = final; };
});
in
{
flake.lib = lib;
}

39
flake/nixos.nix Normal file
View file

@ -0,0 +1,39 @@
{ self, inputs, ... }:
let
inherit (self) lib;
defaultModules = [
{
# Let 'nixos-version --json' know about the Git revision
system.configurationRevision = self.rev or "dirty";
}
{
nixpkgs.overlays = (lib.attrValues self.overlays) ++ [
inputs.nur.overlay
];
}
# Include generic settings
"${self}/modules"
# Include bundles of settings
"${self}/profiles"
];
buildHost = name: system: lib.nixosSystem {
inherit system;
modules = defaultModules ++ [
"${self}/hosts/nixos/${name}"
];
specialArgs = {
# Use my extended lib in NixOS configuration
inherit lib;
# Inject inputs to use them in global registry
inherit inputs;
};
};
in
{
flake.nixosConfigurations = lib.mapAttrs buildHost {
aramis = "x86_64-linux";
porthos = "x86_64-linux";
};
}

17
flake/overlays.nix Normal file
View file

@ -0,0 +1,17 @@
{ self, ... }:
let
default-overlays = import "${self}/overlays";
additional-overlays = {
# Expose my expanded library
lib = _final: _prev: { inherit (self) lib; };
# Expose my custom packages
pkgs = _final: prev: {
ambroisie = prev.recurseIntoAttrs (import "${self}/pkgs" { pkgs = prev; });
};
};
in
{
flake.overlays = default-overlays // additional-overlays;
}

13
flake/packages.nix Normal file
View file

@ -0,0 +1,13 @@
{ self, inputs, ... }:
{
perSystem = { pkgs, system, ... }: {
packages =
let
inherit (inputs.futils.lib) filterPackages flattenTree;
packages = import "${self}/pkgs" { inherit pkgs; };
flattenedPackages = flattenTree packages;
finalPackages = filterPackages system flattenedPackages;
in
finalPackages;
};
}

4
flake/templates.nix Normal file
View file

@ -0,0 +1,4 @@
{ self, ... }:
{
flake.templates = import "${self}/templates";
}

26
home/aliases/default.nix Normal file
View file

@ -0,0 +1,26 @@
{ config, lib, ... }:
let
cfg = config.my.home.aliases;
in
{
options.my.home.aliases = with lib; {
enable = my.mkDisableOption "shell aliases configuration";
};
config = lib.mkIf cfg.enable {
home = {
shellAliases = {
# I like pretty colors
diff = "diff --color=auto";
grep = "grep --color=auto";
egrep = "egrep --color=auto";
fgrep = "fgrep --color=auto";
ls = "ls --color=auto";
# Well-known ls aliases
l = "ls -alh";
ll = "ls -l";
};
};
};
}

31
home/atuin/default.nix Normal file
View file

@ -0,0 +1,31 @@
{ config, lib, ... }:
let
cfg = config.my.home.atuin;
in
{
options.my.home.atuin = with lib; {
enable = my.mkDisableOption "atuin configuration";
};
config = lib.mkIf cfg.enable {
programs.atuin = {
enable = true;
flags = [
# I *despise* this hijacking of the up key, even though I use Ctrl-p
"--disable-up-arrow"
];
settings = {
# The package is managed by Nix
update_check = false;
# I don't care for the fancy display
style = "compact";
# Get closer to fzf's fuzzy search
search_mode = "skim";
# Show long command lines at the bottom
show_preview = true;
};
};
};
}

View file

@ -3,13 +3,15 @@ let
cfg = config.my.home.bat;
in
{
options.my.home.bat = with lib.my; {
enable = mkDisableOption "bat configuration";
options.my.home.bat = with lib; {
enable = my.mkDisableOption "bat configuration";
};
config.programs.bat = lib.mkIf cfg.enable {
enable = true;
config = {
theme = "gruvbox-dark";
pager = with config.home.sessionVariables; "${PAGER} ${LESS}";
};
};

View file

@ -0,0 +1,27 @@
{ config, lib, ... }:
let
cfg = config.my.home.bitwarden;
in
{
options.my.home.bitwarden = with lib; {
enable = my.mkDisableOption "bitwarden configuration";
pinentry = mkOption {
type = types.str;
default = "tty";
example = "gtk2";
description = "Which pinentry interface to use";
};
};
config = lib.mkIf cfg.enable {
programs.rbw = {
enable = true;
settings = {
email = lib.my.mkMailAddress "bruno" "belanyi.fr";
inherit (cfg) pinentry;
};
};
};
}

View file

@ -0,0 +1,19 @@
{ config, lib, ... }:
let
cfg = config.my.home.bluetooth;
in
{
options.my.home.bluetooth = with lib; {
enable = mkEnableOption "bluetooth configuration";
};
config = lib.mkIf cfg.enable {
services.blueman-applet = {
enable = true;
};
services.mpris-proxy = {
enable = true;
};
};
}

15
home/calibre/default.nix Normal file
View file

@ -0,0 +1,15 @@
{ config, lib, pkgs, ... }:
let
cfg = config.my.home.calibre;
in
{
options.my.home.calibre = with lib; {
enable = mkEnableOption "calibre configuration";
};
config = lib.mkIf cfg.enable {
home.packages = with pkgs; [
calibre # NOTE: relies on my overlay to add necessary plug-in dependencies
];
};
}

29
home/comma/default.nix Normal file
View file

@ -0,0 +1,29 @@
{ config, lib, pkgs, ... }:
let
cfg = config.my.home.comma;
in
{
options.my.home.comma = with lib; {
enable = my.mkDisableOption "comma configuration";
pkgsFlake = mkOption {
type = types.str;
default = "pkgs";
example = "nixpkgs";
description = ''
Which flake from the registry should be used with
<command>nix shell</command>.
'';
};
};
config = lib.mkIf cfg.enable {
home.packages = with pkgs; [
ambroisie.comma
];
home.sessionVariables = {
COMMA_PKGS_FLAKE = cfg.pkgsFlake;
};
};
}

View file

@ -1,20 +1,47 @@
{ ... }:
{
imports = [
./bat.nix
./direnv.nix
./documentation.nix
./aliases
./atuin
./bat
./bitwarden
./bluetooth
./calibre
./comma
./dircolors
./direnv
./discord
./documentation
./feh
./firefox
./flameshot
./fzf
./gammastep
./gdb
./git
./gpg.nix
./htop.nix
./jq.nix
./packages.nix
./pager.nix
./secrets # Home-manager specific secrets
./ssh.nix
./tmux.nix
./gpg
./gtk
./htop
./jq
./mail
./mpv
./nix
./nix-index
./nixpkgs
./nm-applet
./packages
./pager
./power-alert
./secrets
./ssh
./terminal
./tmux
./udiskie
./vim
./xdg.nix
./wm
./x
./xdg
./zathura
./zsh
];
@ -23,4 +50,7 @@
# Who am I?
home.username = "ambroisie";
# Start services automatically
systemd.user.startServices = "sd-switch";
}

View file

@ -0,0 +1,15 @@
{ config, lib, ... }:
let
cfg = config.my.home.dircolors;
in
{
options.my.home.dircolors = with lib; {
enable = my.mkDisableOption "dircolors configuration";
};
config = lib.mkIf cfg.enable {
programs.dircolors = {
enable = true;
};
};
}

View file

@ -1,15 +0,0 @@
{ config, lib, ... }:
let
cfg = config.my.home.direnv;
in
{
options.my.home.direnv = with lib.my; {
enable = mkDisableOption "direnv configuration";
};
config.programs.direnv = lib.mkIf cfg.enable {
enable = true;
# A better `use_nix`
enableNixDirenvIntegration = true;
};
}

46
home/direnv/default.nix Normal file
View file

@ -0,0 +1,46 @@
{ config, lib, ... }:
let
cfg = config.my.home.direnv;
in
{
options.my.home.direnv = with lib; {
enable = my.mkDisableOption "direnv configuration";
defaultFlake = mkOption {
type = types.str;
default = "pkgs";
example = "nixpkgs";
description = ''
Which flake from the registry should be used for
<command>use pkgs</command> by default.
'';
};
};
config = lib.mkIf cfg.enable {
programs.direnv = {
enable = true;
nix-direnv = {
# A better `use_nix`
enable = true;
};
};
xdg.configFile =
let
libDir = ./lib;
contents = builtins.readDir libDir;
names = lib.attrNames contents;
files = lib.filter (name: contents.${name} == "regular") names;
linkLibFile = name:
lib.nameValuePair
"direnv/lib/${name}"
{ source = libDir + "/${name}"; };
in
lib.my.genAttrs' files linkLibFile;
home.sessionVariables = {
DIRENV_DEFAULT_FLAKE = cfg.defaultFlake;
};
};
}

32
home/direnv/lib/nix.sh Normal file
View file

@ -0,0 +1,32 @@
#shellcheck shell=bash
use_pkgs() {
if ! has nix; then
# shellcheck disable=2016
log_error 'use_pkgs: `nix` is not in PATH'
return 1
fi
# Use user-provided default value, or fallback to nixpkgs
local DEFAULT_FLAKE="${DIRENV_DEFAULT_FLAKE:-nixpkgs}"
# Allow changing the default flake through a command line switch
if [ "$1" = "-f" ] || [ "$1" = "--flake" ]; then
DEFAULT_FLAKE="$2"
shift 2
fi
# Allow specifying a full installable, or just a package name and use the default flake
local packages=()
for pkg; do
if [[ $pkg =~ .*#.* ]]; then
packages+=("$pkg")
else
packages+=("$DEFAULT_FLAKE#$pkg")
fi
done
# shellcheck disable=2154
direnv_load nix shell "${packages[@]}" --command "$direnv" dump
}

View file

@ -0,0 +1,22 @@
#shellcheck shell=bash
layout_postgres() {
if ! has postgres || ! has initdb; then
# shellcheck disable=2016
log_error 'layout_postgres: `postgres` and `initdb` are not in PATH'
return 1
fi
# shellcheck disable=2155
export PGDATA="$(direnv_layout_dir)/postgres"
export PGHOST="$PGDATA"
if [[ ! -d "$PGDATA" ]]; then
initdb
cat >> "$PGDATA/postgresql.conf" << EOF
listen_addresses = ''
unix_socket_directories = '$PGHOST'
EOF
echo "CREATE DATABASE $USER;" | postgres --single -E postgres
fi
}

25
home/direnv/lib/python.sh Normal file
View file

@ -0,0 +1,25 @@
#shellcheck shell=bash
layout_poetry() {
if ! has poetry; then
# shellcheck disable=2016
log_error 'layout_poetry: `poetry` is not in PATH'
return 1
fi
if [[ ! -f pyproject.toml ]]; then
# shellcheck disable=2016
log_error 'layout_poetry: no pyproject.toml found. Use `poetry new` or `poetry init` to create one first'
return 1
fi
# create venv if it doesn't exist
poetry run true
# shellcheck disable=2155
export VIRTUAL_ENV=$(poetry env info --path)
export POETRY_ACTIVE=1
PATH_add "$VIRTUAL_ENV/bin"
watch_file pyproject.toml
watch_file poetry.lock
}

23
home/discord/default.nix Normal file
View file

@ -0,0 +1,23 @@
{ config, lib, pkgs, ... }:
let
cfg = config.my.home.discord;
jsonFormat = pkgs.formats.json { };
in
{
options.my.home.discord = with lib; {
enable = mkEnableOption "discord configuration";
};
config = lib.mkIf cfg.enable {
home.packages = with pkgs; [
discord
];
xdg.configFile."discord/settings.json".source =
jsonFormat.generate "discord.json" {
# Do not keep me from using the app just to force an update
SKIP_HOST_UPDATE = true;
};
};
}

View file

@ -3,8 +3,8 @@ let
cfg = config.my.home.documentation;
in
{
options.my.home.documentation = with lib.my; {
enable = mkDisableOption "documentation integration";
options.my.home.documentation = with lib; {
enable = my.mkDisableOption "documentation integration";
};
# Add documentation for user packages

13
home/feh/default.nix Normal file
View file

@ -0,0 +1,13 @@
{ config, lib, ... }:
let
cfg = config.my.home.feh;
in
{
options.my.home.feh = with lib; {
enable = mkEnableOption "feh configuration";
};
config.programs.feh = lib.mkIf cfg.enable {
enable = true;
};
}

83
home/firefox/default.nix Normal file
View file

@ -0,0 +1,83 @@
{ config, lib, pkgs, ... }:
let
cfg = config.my.home.firefox;
in
{
imports = [
./tridactyl
];
options.my.home.firefox = with lib; {
enable = mkEnableOption "firefox configuration";
tridactyl = {
enable = mkOption {
type = types.bool;
description = "tridactyl configuration";
example = false;
default = config.my.home.firefox.enable;
};
};
ff2mpv = {
enable = mkOption {
type = types.bool;
description = "ff2mpv configuration";
example = false;
default = config.my.home.mpv.enable;
};
};
};
config.programs.firefox = lib.mkIf cfg.enable {
enable = true;
package = pkgs.firefox.override {
cfg = {
enableTridactylNative = cfg.tridactyl.enable;
};
extraNativeMessagingHosts = with pkgs; ([ ]
# Watch videos using mpv
++ lib.optional cfg.ff2mpv.enable ambroisie.ff2mpv-go
);
};
profiles = {
default = {
id = 0;
settings = {
"browser.bookmarks.showMobileBookmarks" = true; # Mobile bookmarks
"browser.download.useDownloadDir" = false; # Ask for download location
"browser.in-content.dark-mode" = true; # Dark mode
"browser.newtabpage.activity-stream.feeds.section.topstories" = false; # Disable top stories
"browser.newtabpage.activity-stream.feeds.sections" = false;
"browser.newtabpage.activity-stream.feeds.system.topstories" = false; # Disable top stories
"browser.newtabpage.activity-stream.section.highlights.includePocket" = false; # Disable pocket
"extensions.pocket.enabled" = false; # Disable pocket
"media.eme.enabled" = true; # Enable DRM
"media.gmp-widevinecdm.enabled" = true; # Enable DRM
"media.gmp-widevinecdm.visible" = true; # Enable DRM
"signon.autofillForms" = false; # Disable built-in form-filling
"signon.rememberSignons" = false; # Disable built-in password manager
"ui.systemUsesDarkTheme" = true; # Dark mode
};
extensions = with pkgs.nur.repos.rycee.firefox-addons; ([
bitwarden
consent-o-matic
form-history-control
reddit-comment-collapser
reddit-enhancement-suite
refined-github
sponsorblock
ublock-origin
]
++ lib.optional (cfg.tridactyl.enable) tridactyl
++ lib.optional (cfg.ff2mpv.enable) ff2mpv
);
};
};
};
}

View file

@ -0,0 +1,28 @@
{ config, lib, pkgs, ... }:
let
cfg = config.my.home.firefox.tridactyl;
term = config.my.home.terminal.program;
vimCommandLine = {
alacritty = ''-e "vim" "%f" "+normal!%lGzv%c|"'';
# Termite wants the whole command in a single argument...
termite = ''-e "vim %f '+normal!%lGzv%c|'"'';
};
in
{
config = lib.mkIf cfg.enable {
xdg.configFile."tridactyl/tridactylrc".source = pkgs.substituteAll {
src = ./tridactylrc;
editorcmd = lib.concatStringsSep " " [
# Use my configured terminal
term
# Make it easy to pick out with a window class name
"--class tridactyl_editor"
# Open vim with the cursor in the correct position
vimCommandLine.${term}
];
};
};
}

View file

@ -0,0 +1,82 @@
" Shamelessly taken from bovine3dom's example configuration file from the docs
" Basics {{{
" Use dark color scheme
colorscheme dark
" Make tridactyl open Vim in my prefered terminal
set editorcmd @editorcmd@
" Remove editor file after use
alias editor_rm composite editor | jsb -p tri.native.run(`rm -f '${JS_ARG[0]}'`)
bind --mode=insert <C-i> editor_rm
bind --mode=input <C-i> editor_rm
" }}}
" Binds {{{
" Reddit et al. {{{
" Toggle comments on Reddit, Hacker News, Lobste.rs
bind ;c hint -Jc [class*="expand"],[class*="togg"],[class="comment_folder"]
" Make `gu` take me back to subreddit from comments
bindurl reddit.com gu urlparent 3
" Only hint search results on Google
bindurl www.google.com f hint -Jc #search div:not(.action-menu) > a
bindurl www.google.com F hint -Jbc #search div:not(.action-menu) > a
" Only hint search results on DuckDuckGo
bindurl ^https://duckduckgo.com f hint -Jc [data-testid="result-title-a"]
bindurl ^https://duckduckgo.com F hint -Jbc [data-testid="result-title-a"]
" Only hint item pages on Hacker News
bindurl news.ycombinator.com ;f hint -Jc .age > a
bindurl news.ycombinator.com ;F hint -Jtc .age > a
" }}}
" Better bindings {{{
" Handy multiwindow binds
bind gd tabdetach
bind gD composite tabduplicate; tabdetach
" Duplicate a tab without detaching window
bind <Space>d tabduplicate
" Make yy use canonical links on the few websites that support them
bind yy clipboard yankcanon
" }}}
" Search {{{
" Case insensitive only if fully lowercase
set findcase smart
" Search forward/backward
bind / fillcmdline find
bind ? fillcmdline find -?
" Go to next/previous match
bind n findnext 1
bind N findnext -1
" Because :nohls never works
bind <Space><Space> nohlsearch
" Use browser's native find when using Ctrl-F
unbind <C-f>
" }}}
" }}}
" Redirections {{{
" Always redirect Reddit to the old site
autocmd DocStart ^http(s?)://www.reddit.com js tri.excmds.urlmodify("-t", "www", "old")
" Use a better Twitter front-end
autocmd DocStart ^http(s?)://twitter.com js tri.excmds.urlmodify("-t", "twitter.com", "nitter.net")
" }}}
" Disabled websites {{{
blacklistadd netflix.com
blacklistadd primevideo.com
blacklistadd jellyfin.belanyi.fr
" }}}
" vim: set filetype=vim foldmethod=marker:

View file

@ -0,0 +1,13 @@
{ config, lib, ... }:
let
cfg = config.my.home.flameshot;
in
{
options.my.home.flameshot = with lib; {
enable = mkEnableOption "flameshot configuration";
};
config.services.flameshot = lib.mkIf cfg.enable {
enable = true;
};
}

15
home/fzf/default.nix Normal file
View file

@ -0,0 +1,15 @@
{ config, lib, ... }:
let
cfg = config.my.home.fzf;
in
{
options.my.home.fzf = with lib; {
enable = my.mkDisableOption "fzf configuration";
};
config = lib.mkIf cfg.enable {
programs.fzf = {
enable = true;
};
};
}

View file

@ -0,0 +1,44 @@
{ config, lib, ... }:
let
cfg = config.my.home.gammastep;
mkTempOption = with lib; description: default: mkOption {
inherit description default;
type = types.int;
example = 1000;
};
mkTimeOption = with lib; description: default: mkOption {
inherit description default;
type = types.str;
example = "12:00-14:00";
};
in
{
options.my.home.gammastep = with lib; {
enable = mkEnableOption "gammastep configuration";
temperature = {
day = mkTempOption "Colour temperature to use during the day" 6500;
night = mkTempOption "Colour temperature to use during the night" 2000;
};
times = {
dawn = mkTimeOption "Dawn time" "6:00-7:30";
dusk = mkTimeOption "Dusk time" "18:30-20:00";
};
};
config.services.gammastep = lib.mkIf cfg.enable {
enable = true;
tray = true;
dawnTime = cfg.times.dawn;
duskTime = cfg.times.dusk;
temperature = {
inherit (cfg.temperature) day night;
};
};
}

38
home/gdb/default.nix Normal file
View file

@ -0,0 +1,38 @@
{ config, lib, pkgs, ... }:
let
cfg = config.my.home.gdb;
in
{
options.my.home.gdb = with lib; {
enable = my.mkDisableOption "gdb configuration";
rr = {
enable = my.mkDisableOption "rr configuration";
package = mkOption {
type = types.package;
default = pkgs.rr;
defaultText = literalExample "pkgs.rr";
description = ''
Package providing rr
'';
};
};
};
config = lib.mkMerge [
(lib.mkIf cfg.enable {
home.packages = with pkgs; [
gdb
];
xdg.configFile."gdb/gdbinit".source = ./gdbinit;
})
(lib.mkIf cfg.rr.enable {
home.packages = [
cfg.rr.package
];
})
];
}

24
home/gdb/gdbinit Normal file
View file

@ -0,0 +1,24 @@
# Keep a history of all commands in each directory
set history save on
# Enable those pretty-printers
enable pretty-printer
# Pretty formatting of structures
set print pretty on
# Show derived type based on VTable
set print object on
# Show static members
set print static-members on
# Show VTable
set print vtbl on
# Demangle types
set print demangle on
# Read python scrips in the load path
set auto-load python-scripts
# Allow autoloading project-local .gdbinit files
add-auto-load-safe-path ~/git/
# Allow autoloading from the Nix store
add-auto-load-safe-path /nix/store

View file

@ -24,3 +24,11 @@ compile_commands.json
# Swap and backup files
*~
~.swp
# Direnv files
.envrc
.direnv/
# Project-local neovim configuration files
.nvim.lua
.nvimrc

View file

@ -1,34 +1,73 @@
{ config, pkgs, lib, ... }:
let
cfg = config.my.home.git;
inherit (lib.my) mkMailAddress;
in
{
options.my.home.git = with lib.my; {
enable = mkDisableOption "git configuration";
options.my.home.git = with lib; {
enable = my.mkDisableOption "git configuration";
};
config.home.packages = with pkgs; lib.mkIf cfg.enable [
git-absorb
git-revise
tig
];
config.programs.git = lib.mkIf cfg.enable {
enable = true;
# Who am I?
userEmail = "bruno@belanyi.fr";
userEmail = mkMailAddress "bruno" "belanyi.fr";
userName = "Bruno BELANYI";
# I want the full experience
package = pkgs.gitAndTools.gitFull;
package = pkgs.gitFull;
aliases = {
lol = "log --graph --decorate --pretty=oneline --abbrev-commit";
git = "!git";
lol = "log --graph --decorate --pretty=oneline --abbrev-commit --topo-order";
lola = "lol --all";
assume = "update-index --assume-unchanged";
unassume = "update-index --no-assume-unchanged";
assumed = "!git ls-files -v | grep ^h | cut -c 3-";
pick = "log -p -G";
push-new = "!git push -u origin "
+ ''"$(git branch | grep '^* ' | cut -f2- -d' ')"'';
root = "git rev-parse --show-toplevel";
};
lfs.enable = true;
delta = {
enable = true;
options = {
features = "diff-highlight decorations";
# Less jarring style for `diff-highlight` emulation
diff-highlight = {
minus-style = "red";
minus-non-emph-style = "red";
minus-emph-style = "bold red 52";
plus-style = "green";
plus-non-emph-style = "green";
plus-emph-style = "bold green 22";
whitespace-error-style = "reverse red";
};
# Personal preference for easier reading
decorations = {
commit-style = "raw"; # Do not recolor meta information
keep-plus-minus-markers = true;
paging = "always";
};
};
};
# There's more
extraConfig = {
# Makes it a bit more readable
@ -62,13 +101,6 @@ in
whitespace = "red reverse";
};
"color.diff-highlight" = {
oldNormal = "red bold";
oldHighlight = "red bold 52";
newNormal = "green bold";
newHighlight = "green bold 22";
};
commit = {
# Show my changes when writing the message
verbose = true;
@ -89,15 +121,14 @@ in
defaultBranch = "main";
};
pager =
let
diff-highlight = "${pkgs.gitAndTools.gitFull}/share/git/contrib/diff-highlight/diff-highlight";
in
{
diff = "${diff-highlight} | less";
log = "${diff-highlight} | less";
show = "${diff-highlight} | less";
};
# Local configuration, not-versioned
include = {
path = "config.local";
};
merge = {
conflictStyle = "zdiff3";
};
pull = {
# Avoid useless merge commits
@ -114,11 +145,42 @@ in
autoSquash = true;
autoStash = true;
};
url = {
"git@git.belanyi.fr:" = {
insteadOf = "https://git.belanyi.fr/";
};
"git@github.com:" = {
insteadOf = "https://github.com/";
};
"git@gitlab.com:" = {
insteadOf = "https://gitlab.com/";
};
};
};
# Multiple identities
includes = [
{ path = ./epita.config; condition = "gitdir:~/git/EPITA/"; }
{
condition = "gitdir:~/git/EPITA/";
contents = {
user = {
name = "Bruno BELANYI";
email = mkMailAddress "bruno.belanyi" "epita.fr";
};
};
}
{
condition = "gitdir:~/git/work/";
contents = {
user = {
name = "Bruno BELANYI";
email = mkMailAddress "ambroisie" "google.com";
};
};
}
];
ignores =

View file

@ -1,4 +0,0 @@
[user]
email = bruno.belanyi@epita.fr
name = Bruno BELANYI
# vim: set ft=gitconfig:

View file

@ -1,24 +0,0 @@
{ config, lib, ... }:
let
cfg = config.my.home.gpg;
in
{
options.my.home.gpg = with lib.my; {
enable = mkDisableOption "gpg configuration";
};
config = lib.mkIf cfg.enable {
programs.gpg = {
enable = true;
};
services.gpg-agent = {
enable = true;
enableSshSupport = true; # One agent to rule them all
pinentryFlavor = "tty";
extraConfig = ''
allow-loopback-pinentry
'';
};
};
}

36
home/gpg/default.nix Normal file
View file

@ -0,0 +1,36 @@
{ config, lib, ... }:
let
cfg = config.my.home.gpg;
in
{
options.my.home.gpg = with lib; {
enable = my.mkDisableOption "gpg configuration";
pinentry = mkOption {
type = types.str;
default = "tty";
example = "gtk2";
description = "Which pinentry interface to use";
};
};
config = lib.mkIf cfg.enable {
programs.gpg = {
enable = true;
};
services.gpg-agent = {
enable = true;
enableSshSupport = true; # One agent to rule them all
pinentryFlavor = cfg.pinentry;
extraConfig = ''
allow-loopback-pinentry
'';
};
home.shellAliases = {
# Sometime `gpg-agent` errors out...
reset-agent = "gpg-connect-agent updatestartuptty /bye";
};
};
}

33
home/gtk/default.nix Normal file
View file

@ -0,0 +1,33 @@
{ config, lib, pkgs, ... }:
let
cfg = config.my.home.gtk;
in
{
options.my.home.gtk = with lib; {
enable = mkEnableOption "GTK configuration";
};
config.gtk = lib.mkIf cfg.enable {
enable = true;
font = {
package = pkgs.dejavu_fonts;
name = "DejaVu Sans";
};
gtk2 = {
# That sweet, sweet clean home that I am always aiming for...
configLocation = "${config.xdg.configHome}/gtk-2.0/gtkrc";
};
iconTheme = {
package = pkgs.gnome.gnome-themes-extra;
name = "Adwaita";
};
theme = {
package = pkgs.gnome.gnome-themes-extra;
name = "Adwaita";
};
};
}

View file

@ -3,8 +3,8 @@ let
cfg = config.my.home.htop;
in
{
options.my.home.htop = with lib.my; {
enable = mkDisableOption "htop configuration";
options.my.home.htop = with lib; {
enable = my.mkDisableOption "htop configuration";
};
config.programs.htop = lib.mkIf cfg.enable {

View file

@ -3,8 +3,8 @@ let
cfg = config.my.home.jq;
in
{
options.my.home.jq = with lib.my; {
enable = mkDisableOption "jq configuration";
options.my.home.jq = with lib; {
enable = my.mkDisableOption "jq configuration";
};
config.programs.jq = lib.mkIf cfg.enable {

View file

@ -0,0 +1,94 @@
{ config, lib, pkgs, ... }:
let
cfg = config.my.home.mail;
inherit (lib.my) mkMailAddress;
mkConfig = { domain, address, passName, aliases ? [ ], primary ? false }: {
realName = lib.mkDefault "Bruno BELANYI";
userName = lib.mkDefault (mkMailAddress address domain);
passwordCommand =
lib.mkDefault [ (lib.getExe pkgs.ambroisie.rbw-pass) "Mail" passName ];
address = mkMailAddress address domain;
aliases = builtins.map (lib.flip mkMailAddress domain) aliases;
inherit primary;
himalaya = {
enable = cfg.himalaya.enable;
# FIXME: try to actually configure it at some point
backend = "imap";
sender = "smtp";
};
msmtp = {
enable = cfg.msmtp.enable;
};
};
migaduConfig = {
imap = {
host = "imap.migadu.com";
port = 993;
tls = {
enable = true;
};
};
smtp = {
host = "smtp.migadu.com";
port = 465;
tls = {
enable = true;
};
};
};
gmailConfig = {
flavor = "gmail.com";
folders = {
drafts = "[Gmail]/Drafts";
sent = "[Gmail]/Sent Mail";
trash = "[Gmail]/Trash";
};
};
office365Config = {
flavor = "outlook.office365.com";
};
in
{
config.accounts.email.accounts = {
personal = lib.mkMerge [
# Common configuraton
(mkConfig {
domain = "belanyi.fr";
address = "bruno";
passName = "Migadu";
aliases = [ "admin" "postmaster" ];
primary = true; # This is my primary email
})
migaduConfig
];
gmail = lib.mkMerge [
# Common configuraton
(mkConfig {
domain = "gmail.com";
address = "brunobelanyi";
passName = "GMail";
})
gmailConfig
];
epita = lib.mkMerge [
# Common configuration
(mkConfig {
domain = "epita.fr";
address = "bruno.belanyi";
passName = "EPITA";
})
office365Config
];
};
}

31
home/mail/default.nix Normal file
View file

@ -0,0 +1,31 @@
{ config, lib, ... }:
let
cfg = config.my.home.mail;
mkRelatedOption = desc: lib.mkEnableOption desc // { default = cfg.enable; };
in
{
imports = [
./accounts
./himalaya
./msmtp
];
options.my.home.mail = with lib; {
enable = my.mkDisableOption "email configuration";
himalaya = {
enable = mkEnableOption "himalaya configuration";
};
msmtp = {
enable = mkRelatedOption "msmtp configuration";
};
};
config = {
accounts.email = {
maildirBasePath = "mail";
};
};
}

View file

@ -0,0 +1,23 @@
{ config, lib, pkgs, ... }:
let
cfg = config.my.home.mail.himalaya;
in
{
config.programs.himalaya = lib.mkIf cfg.enable {
enable = true;
settings = {
notify-cmd =
let
notify-send = lib.getExe pkgs.libnotify;
in
pkgs.writeScript "mail-notifier" ''
SENDER="$1"
SUBJECT="$2"
${notify-send} \
-c himalaya \
-- "$(printf 'Received email from %s\n\n%s' "$SENDER" "$SUBJECT")"
'';
};
};
}

View file

@ -0,0 +1,9 @@
{ config, lib, ... }:
let
cfg = config.my.home.mail.msmtp;
in
{
config.programs.msmtp = lib.mkIf cfg.enable {
enable = true;
};
}

19
home/mpv/default.nix Normal file
View file

@ -0,0 +1,19 @@
{ config, lib, pkgs, ... }:
let
cfg = config.my.home.mpv;
in
{
options.my.home.mpv = with lib; {
enable = mkEnableOption "mpv configuration";
};
config = lib.mkIf cfg.enable {
programs.mpv = {
enable = true;
scripts = [
pkgs.mpvScripts.mpris # Allow controlling using media keys
];
};
};
}

View file

@ -0,0 +1,13 @@
{ config, lib, ... }:
let
cfg = config.my.home.nix-index;
in
{
options.my.home.nix-index = with lib; {
enable = my.mkDisableOption "nix-index configuration";
};
config.programs.nix-index = lib.mkIf cfg.enable {
enable = true;
};
}

82
home/nix/default.nix Normal file
View file

@ -0,0 +1,82 @@
# Nix related settings
{ config, inputs, lib, pkgs, ... }:
let
cfg = config.my.home.nix;
channels = lib.my.merge [
{
# Allow me to use my custom package using `nix run self#pkg`
self = inputs.self;
# Add NUR to run some packages that are only present there
nur = inputs.nur;
# Use pinned nixpkgs when using `nix run pkgs#<whatever>`
pkgs = inputs.nixpkgs;
}
(lib.optionalAttrs cfg.overrideNixpkgs {
# ... And with `nix run nixpkgs#<whatever>`
nixpkgs = inputs.nixpkgs;
})
];
in
{
options.my.home.nix = with lib; {
enable = my.mkDisableOption "nix configuration";
linkInputs = my.mkDisableOption "link inputs to `$XDG_CONFIG_HOME/nix/inputs`";
addToRegistry = my.mkDisableOption "add inputs and self to registry";
addToNixPath = my.mkDisableOption "add inputs and self to nix path";
overrideNixpkgs = my.mkDisableOption "point nixpkgs to pinned system version";
};
config = lib.mkIf cfg.enable (lib.mkMerge [
{
assertions = [
{
assertion = cfg.addToNixPath -> cfg.linkInputs;
message = ''
enabling `my.home.nix.addToNixPath` needs to have
`my.home.nix.linkInputs = true`
'';
}
];
}
{
nix = {
package = lib.mkDefault pkgs.nix; # NixOS module sets it unconditionally
settings = {
experimental-features = [ "nix-command" "flakes" ];
};
};
}
(lib.mkIf cfg.addToRegistry {
nix.registry =
let
makeEntry = v: { flake = v; };
makeEntries = lib.mapAttrs (lib.const makeEntry);
in
makeEntries channels;
})
(lib.mkIf cfg.linkInputs {
xdg.configFile =
let
makeLink = n: v: {
name = "nix/inputs/${n}";
value = { source = v.outPath; };
};
makeLinks = lib.mapAttrs' makeLink;
in
makeLinks channels;
})
(lib.mkIf cfg.addToNixPath {
home.sessionVariables.NIX_PATH = "${config.xdg.configHome}/nix/inputs\${NIX_PATH:+:$NIX_PATH}";
})
]);
}

20
home/nixpkgs/default.nix Normal file
View file

@ -0,0 +1,20 @@
{ config, lib, pkgs, ... }:
let
cfg = config.my.home.nixpkgs;
in
{
options.my.home.nixpkgs = with lib; {
enable = mkEnableOption "nixpkgs configuration";
};
config = lib.mkIf cfg.enable {
home.packages = with pkgs; [
nixpkgs-review
];
home.sessionVariables = {
GITHUB_TOKEN = ''$(cat "${config.age.secrets."github/token".path}")'';
GITHUB_API_TOKEN = ''$(cat "${config.age.secrets."github/token".path}")'';
};
};
}

View file

@ -0,0 +1,13 @@
{ config, lib, ... }:
let
cfg = config.my.home.nm-applet;
in
{
options.my.home.nm-applet = with lib; {
enable = mkEnableOption "network-manager-applet configuration";
};
config.services.network-manager-applet = lib.mkIf cfg.enable {
enable = true;
};
}

View file

@ -1,20 +0,0 @@
{ config, lib, pkgs, ... }:
let
cfg = config.my.home.packages;
in
{
options.my.home.packages = with lib.my; {
enable = mkDisableOption "user packages";
};
config.home.packages = with pkgs; lib.mkIf cfg.enable [
# Git related
gitAndTools.git-absorb
gitAndTools.git-revise
gitAndTools.tig
# Dev work
rr
# Terminal prettiness
termite.terminfo
];
}

26
home/packages/default.nix Normal file
View file

@ -0,0 +1,26 @@
{ config, lib, pkgs, ... }:
let
cfg = config.my.home.packages;
in
{
options.my.home.packages = with lib; {
enable = my.mkDisableOption "user packages";
additionalPackages = mkOption {
type = with types; listOf package;
default = [ ];
example = literalExample ''
with pkgs; [
quasselClient
]
'';
};
};
config.home.packages = with pkgs; lib.mkIf cfg.enable ([
fd
file
mosh
ripgrep
] ++ cfg.additionalPackages);
}

View file

@ -1,18 +0,0 @@
{ config, lib, ... }:
let
cfg = config.my.home.pager;
in
{
options.my.home.pager = with lib.my; {
enable = mkDisableOption "pager configuration";
};
config.programs.lesspipe.enable = cfg.enable;
config.home.sessionVariables = lib.mkIf cfg.enable {
# My default pager
PAGER = "less";
# Clear the screen on start and exit
LESS = "-R -+X -c";
};
}

21
home/pager/default.nix Normal file
View file

@ -0,0 +1,21 @@
{ config, lib, ... }:
let
cfg = config.my.home.pager;
in
{
options.my.home.pager = with lib; {
enable = my.mkDisableOption "pager configuration";
};
config = lib.mkIf cfg.enable {
home.sessionVariables = {
# My default pager
PAGER = "less";
# Clear the screen on start and exit
LESS = "-R -+X -c";
# Better XDG compliance
LESSHISTFILE = "${config.xdg.dataHome}/less/history";
};
};
}

View file

@ -0,0 +1,15 @@
{ config, lib, ... }:
let
cfg = config.my.home.power-alert;
in
{
options.my.home.power-alert = with lib; {
enable = mkEnableOption "power-alert configuration";
};
config = lib.mkIf cfg.enable {
services.poweralertd = {
enable = true;
};
};
}

View file

@ -1,3 +0,0 @@
* filter=git-crypt diff=git-crypt
.gitattributes !filter !diff
/default.nix !filter !diff

Binary file not shown.

View file

@ -1,19 +1,25 @@
{ lib, ... }:
{ config, inputs, lib, options, ... }:
with lib;
let
canaryHash = builtins.hashFile "sha256" ./canary;
expectedHash =
"9df8c065663197b5a1095122d48e140d3677d860343256abd5ab6e4fb4c696ab";
in
if canaryHash != expectedHash then
abort "Secrets are not readable. Have you run `git-crypt unlock`?"
else {
options.my.secrets = mkOption {
type = types.attrs;
};
{
imports = [
inputs.agenix.homeManagerModules.age
];
config.my.secrets = {
# Home-manager secrets go here
config.age = {
secrets =
let
toName = lib.removeSuffix ".age";
toSecret = name: { ... }: {
file = ./. + "/${name}";
};
convertSecrets = n: v: lib.nameValuePair (toName n) (toSecret n v);
secrets = import ./secrets.nix;
in
lib.mapAttrs' convertSecrets secrets;
# Add my usual agenix key to the defaults
identityPaths = options.age.identityPaths.default ++ [
"${config.home.homeDirectory}/.ssh/agenix"
];
};
}

Binary file not shown.

9
home/secrets/secrets.nix Normal file
View file

@ -0,0 +1,9 @@
# Common secrets
let
keys = import ../../keys;
all = builtins.attrValues keys.users;
in
{
"github/token.age".publicKeys = all;
}

View file

@ -3,13 +3,18 @@ let
cfg = config.my.home.ssh;
in
{
options.my.home.ssh = with lib.my; {
enable = mkDisableOption "ssh configuration";
options.my.home.ssh = with lib; {
enable = my.mkDisableOption "ssh configuration";
};
config.programs.ssh = {
config.programs.ssh = lib.mkIf cfg.enable {
enable = true;
includes = [
# Local configuration, not-versioned
"config.local"
];
matchBlocks = {
"github.com" = {
hostname = "github.com";
@ -29,8 +34,8 @@ in
user = "git";
};
"gitea.belanyi.fr" = {
hostname = "gitea.belanyi.fr";
"git.belanyi.fr" = {
hostname = "git.belanyi.fr";
identityFile = "~/.ssh/shared_rsa";
user = "git";
};

View file

@ -0,0 +1,52 @@
{ config, lib, ... }:
let
cfg = config.my.home.terminal;
in
{
config = lib.mkIf (cfg.program == "alacritty") {
programs.alacritty = {
enable = true;
settings = {
font = {
size = 5.5;
};
colors = {
primary = {
background = cfg.colors.background;
foreground = cfg.colors.foreground;
bright_foreground = cfg.colors.foregroundBold;
};
cursor = {
cursor = cfg.colors.cursor;
};
normal = {
black = cfg.colors.black;
red = cfg.colors.red;
green = cfg.colors.green;
yellow = cfg.colors.yellow;
blue = cfg.colors.blue;
magenta = cfg.colors.magenta;
cyan = cfg.colors.cyan;
white = cfg.colors.white;
};
bright = {
black = cfg.colors.blackBold;
red = cfg.colors.redBold;
green = cfg.colors.greenBold;
yellow = cfg.colors.yellowBold;
blue = cfg.colors.blueBold;
magenta = cfg.colors.magentaBold;
cyan = cfg.colors.cyanBold;
white = cfg.colors.whiteBold;
};
};
};
};
};
}

62
home/terminal/default.nix Normal file
View file

@ -0,0 +1,62 @@
{ config, lib, ... }:
let
mkColorOption = with lib; description: default: mkOption {
inherit description default;
example = "#abcdef";
type = types.strMatching "#[0-9a-f]{6}";
};
cfg = config.my.home.terminal;
in
{
imports = [
./alacritty
./termite
];
options.my.home = with lib; {
terminal = {
program = mkOption {
type = with types; nullOr (enum [ "alacritty" "termite" ]);
default = null;
example = "termite";
description = "Which terminal to use for home session";
};
colors = {
background = mkColorOption "Background color" "#161616";
foreground = mkColorOption "Foreground color" "#ffffff";
foregroundBold = mkColorOption "Foreground bold color" "#ffffff";
cursor = mkColorOption "Cursor color" "#ffffff";
black = mkColorOption "Black" "#222222";
blackBold = mkColorOption "Black bold" "#666666";
red = mkColorOption "Red" "#e84f4f";
redBold = mkColorOption "Red bold" "#d23d3d";
green = mkColorOption "Green" "#b7ce42";
greenBold = mkColorOption "Green bold" "#bde077";
yellow = mkColorOption "Yellow" "#fea63c";
yellowBold = mkColorOption "Yellow bold" "#ffe863";
blue = mkColorOption "Blue" "#66aabb";
blueBold = mkColorOption "Blue bold" "#aaccbb";
magenta = mkColorOption "Magenta" "#b7416e";
magentaBold = mkColorOption "Magenta bold" "#e16a98";
cyan = mkColorOption "Cyan" "#6d878d";
cyanBold = mkColorOption "Cyan bold" "#42717b";
white = mkColorOption "White" "#dddddd";
whiteBold = mkColorOption "White bold" "#cccccc";
};
};
};
config.home.sessionVariables = lib.mkIf (cfg.program != null) {
TERMINAL = cfg.program;
};
}

View file

@ -0,0 +1,53 @@
{ config, lib, pkgs, ... }:
let
cfg = config.my.home.terminal;
in
{
config = lib.mkIf (cfg.program == "termite") {
programs.termite = {
enable = true;
# Niceties
browser = "${pkgs.xdg-utils}/bin/xdg-open";
clickableUrl = true;
dynamicTitle = true;
fullscreen = false;
mouseAutohide = true;
urgentOnBell = true;
# Look and feel
allowBold = true;
audibleBell = false;
cursorBlink = "system";
font = "Monospace 9";
scrollbar = "off";
# Colors
backgroundColor = cfg.colors.background;
cursorColor = cfg.colors.cursor;
foregroundColor = cfg.colors.foreground;
foregroundBoldColor = cfg.colors.foregroundBold;
colorsExtra = with cfg.colors; ''
# Normal colors
color0 = ${black}
color1 = ${red}
color2 = ${green}
color3 = ${yellow}
color4 = ${blue}
color5 = ${magenta}
color6 = ${cyan}
color7 = ${white}
# Bold colors
color8 = ${blackBold}
color9 = ${redBold}
color10 = ${greenBold}
color11 = ${yellowBold}
color12 = ${blueBold}
color13 = ${magentaBold}
color14 = ${cyanBold}
color15 = ${whiteBold}
'';
};
};
}

View file

@ -1,47 +0,0 @@
{ config, lib, pkgs, ... }:
let
cfg = config.my.home.tmux;
in
{
options.my.home.tmux = with lib.my; {
enable = mkDisableOption "tmux terminal multiplexer";
};
config.programs.tmux = lib.mkIf cfg.enable {
enable = true;
keyMode = "vi"; # Home-row keys and other niceties
clock24 = true; # I'm one of those heathens
escapeTime = 0; # Let vim do its thing instead
historyLimit = 5000; # Bigger buffer
terminal = "tmux-256color"; # I want accurate termcap info
plugins = with pkgs.tmuxPlugins; [
# Open high-lighted files in copy mode
open
# Better pane management
pain-control
# Better session management
sessionist
# X clipboard integration
yank
{
# Show when prefix has been pressed
plugin = prefix-highlight;
extraConfig = ''
# Also show when I'm in copy or sync mode
set -g @prefix_highlight_show_copy_mode 'on'
set -g @prefix_highlight_show_sync_mode 'on'
# Show prefix mode in status bar
set -g status-right '#{prefix_highlight} %a %Y-%m-%d %H:%M'
'';
}
];
extraConfig = ''
# Better vim mode
bind-key -T copy-mode-vi 'v' send -X begin-selection
bind-key -T copy-mode-vi 'y' send -X copy-selection-and-cancel
'';
};
}

80
home/tmux/default.nix Normal file
View file

@ -0,0 +1,80 @@
{ config, lib, pkgs, ... }:
let
cfg = config.my.home.tmux;
hasGUI = lib.any lib.id [
config.my.home.x.enable
(config.my.home.wm.windowManager != null)
];
in
{
options.my.home.tmux = with lib; {
enable = my.mkDisableOption "tmux terminal multiplexer";
enabledPassthrough = mkEnableOption "tmux DCS passthrough sequence";
};
config.programs.tmux = lib.mkIf cfg.enable {
enable = true;
keyMode = "vi"; # Home-row keys and other niceties
clock24 = true; # I'm one of those heathens
escapeTime = 0; # Let vim do its thing instead
historyLimit = 50000; # Bigger buffer
terminal = "tmux-256color"; # I want accurate termcap info
plugins = with pkgs.tmuxPlugins; [
# Open high-lighted files in copy mode
open
# Better pane management
pain-control
# Better session management
sessionist
{
# X clipboard integration
plugin = yank;
extraConfig = ''
# Use 'clipboard' because of misbehaving apps (e.g: firefox)
set -g @yank_selection_mouse 'clipboard'
# Stay in copy mode after yanking
set -g @yank_action 'copy-pipe'
'';
}
{
# Show when prefix has been pressed
plugin = prefix-highlight;
extraConfig = ''
# Also show when I'm in copy or sync mode
set -g @prefix_highlight_show_copy_mode 'on'
set -g @prefix_highlight_show_sync_mode 'on'
# Show prefix mode in status bar
set -g status-right '#{prefix_highlight} %a %Y-%m-%d %H:%M'
'';
}
];
extraConfig = ''
# Better vim mode
bind-key -T copy-mode-vi 'v' send -X begin-selection
${
lib.optionalString
(!hasGUI)
"bind-key -T copy-mode-vi 'y' send -X copy-selection"
}
# Block selection in vim mode
bind-key -Tcopy-mode-vi 'C-v' send -X begin-selection \; send -X rectangle-toggle
# Allow any application to send OSC52 escapes to set the clipboard
set -s set-clipboard on
# Longer session names in status bar
set -g status-left-length 16
${
lib.optionalString cfg.enabledPassthrough ''
# Allow any application to use the tmux DCS for passthrough
set -g allow-passthrough on
''
}
'';
};
}

13
home/udiskie/default.nix Normal file
View file

@ -0,0 +1,13 @@
{ config, lib, ... }:
let
cfg = config.my.home.udiskie;
in
{
options.my.home.udiskie = with lib; {
enable = mkEnableOption "udiskie configuration";
};
config.services.udiskie = lib.mkIf cfg.enable {
enable = true;
};
}

View file

@ -1,14 +0,0 @@
" Create the `b:undo_ftplugin` variable if it doesn't exist
call ftplugined#check_undo_ft()
" Use shfmt as ALE fixer for bash
let b:ale_fixers=[ 'shfmt' ]
let b:undo_ftplugin.='|unlet! b:ale_fixers'
" Indent with 4 spaces, simplify script, indent switch cases, use Bash variant
let b:ale_sh_shfmt_options='-i 4 -s -ci -ln bash'
let b:undo_ftplugin.='|unlet! b:ale_sh_shfmt_options'
" Use bash dialect explicitly, require explicit empty string test
let b:ale_sh_shellcheck_options='-s bash -o avoid-nullary-conditions'
let b:undo_ftplugin.='|unlet! b:ale_sh_shellcheck_options'

View file

@ -7,7 +7,3 @@ let b:undo_ftplugin.='|setlocal shiftwidth<'
" Have automatic padding of transactions so that decimal is on 52nd column
let g:beancount_separator_col=52
" Automatic padding for transactions
nnoremap <buffer> <leader>= :AlignCommodity<CR>
vnoremap <buffer> <leader>= :AlignCommodity<CR>

View file

@ -1,14 +0,0 @@
" Create the `b:undo_ftplugin` variable if it doesn't exist
call ftplugined#check_undo_ft()
" More warnings and the usual version in flags for Clang
let b:ale_c_clang_options='-Wall -Wextra -pedantic -std=c99'
let b:undo_ftplugin.='|unlet! b:ale_c_clang_options'
" More warnings and the usual version in flags for GCC
let b:ale_c_gcc_options='-Wall -Wextra -pedantic -std=c99'
let b:undo_ftplugin.='|unlet! b:ale_c_gcc_options'
" Use compile_commands.json to look for additional flags
let b:ale_c_parse_compile_commands=1
let b:undo_ftplugin.='|unlet! b:ale_c_parse_compile_commands'

View file

@ -1,14 +0,0 @@
" Create the `b:undo_ftplugin` variable if it doesn't exist
call ftplugined#check_undo_ft()
" More warnings and the usual version in flags for Clang
let b:ale_cpp_clang_options='-Wall -Wextra -pedantic -std=c++17'
let b:undo_ftplugin.='|unlet! b:ale_cpp_clang_options'
" More warnings and the usual version in flags for GCC
let b:ale_cpp_gcc_options='-Wall -Wextra -pedantic -std=c++17'
let b:undo_ftplugin.='|unlet! b:ale_cpp_gcc_options'
" Use compile_commands.json to look for additional flags
let b:ale_c_parse_compile_commands=1
let b:undo_ftplugin.='|unlet! b:ale_c_parse_compile_commands'

View file

@ -1,6 +0,0 @@
" Create the `b:undo_ftplugin` variable if it doesn't exist
call ftplugined#check_undo_ft()
" Use my desired ALE fixer for D
let b:ale_fixers=[ 'dfmt' ]
let b:undo_ftplugin.='|unlet! b:ale_fixers'

View file

@ -1,2 +0,0 @@
" Create the `b:undo_ftplugin` variable if it doesn't exist
call ftplugined#check_undo_ft()

View file

@ -5,26 +5,6 @@ call ftplugined#check_undo_ft()
setlocal shiftwidth=2
let b:undo_ftplugin.='|setlocal shiftwidth<'
" Use my desired ALE fixers for Haskell
let b:ale_fixers=[ 'brittany' ]
let b:undo_ftplugin.='|unlet! b:ale_fixers'
" Use stack-managed `hlint`
let b:ale_haskell_hlint_executable='stack'
let b:undo_ftplugin.='|unlet! b:ale_haskell_hlint_executable'
" Use stack-managed `brittany`
let b:ale_haskell_brittany_executable='stack'
let b:undo_ftplugin.='|unlet! b:ale_haskell_brittany_executable'
" Use dynamic libraries because of Arch linux, with default ALE options
let b:ale_haskell_ghc_options='--dynamic -fno-code -v0'
let b:undo_ftplugin.='|unlet! b:ale_haskell_ghc_options'
" Automatically format files when saving them
let b:ale_fix_on_save=1
let b:undo_ftplugin='|unlet! b:ale_lint_on_save'
" Change max length of a line to 100 for this buffer to match official guidelines
setlocal colorcolumn=100
let b:undo_ftplugin.='|setlocal colorcolumn<'

View file

@ -1,6 +0,0 @@
" Create the `b:undo_ftplugin` variable if it doesn't exist
call ftplugined#check_undo_ft()
" Use my desired ALE fixer for JSON
let b:ale_fixers=[ 'jq' ]
let b:undo_ftplugin.='|unlet! b:ale_fixers'

View file

@ -1,10 +1,6 @@
" Create the `b:undo_ftplugin` variable if it doesn't exist
call ftplugined#check_undo_ft()
" Let ALE know that I want Markdown linters
let b:ale_linter_aliases=[ 'markdown' ]
let b:undo_ftplugin.='|unlet! b:ale_linter_aliases'
" Use a small indentation value on Pandoc files
setlocal shiftwidth=2
let b:undo_ftplugin.='|setlocal shiftwidth<'

View file

@ -0,0 +1,6 @@
" Create the `b:undo_ftplugin` variable if it doesn't exist
call ftplugined#check_undo_ft()
" Use a small indentation value on Nix files
setlocal shiftwidth=2
let b:undo_ftplugin.='|setlocal shiftwidth<'

View file

@ -1,40 +0,0 @@
" Create the `b:undo_ftplugin` variable if it doesn't exist
call ftplugined#check_undo_ft()
" Use my desired ALE fixers for python
let b:ale_fixers=[ 'black', 'isort' ]
let b:undo_ftplugin.='|unlet! b:ale_fixers'
" Use my desired ALE linters for python
let b:ale_linters=[ 'flake8', 'mypy', 'pylint', 'pyls' ]
let b:undo_ftplugin.='|unlet! b:ale_linters'
" Use pyls inside the python environment if needed
let b:ale_python_pyls_auto_pipenv=1
let b:undo_ftplugin.='|unlet! b:ale_python_pyls_auto_pipenv'
" Disable pycodestyle checks from pyls because I'm already using flake8
let b:ale_python_pyls_config={
\ 'pyls': {
\ 'plugins': {
\ 'pycodestyle': {
\ 'enabled': v:false
\ },
\ },
\ },
\ }
let b:undo_ftplugin.='|unlet! b:ale_python_pyls_config'
" Don't use mypy to check for syntax errors
let b:ale_python_mypy_ignore_invalid_syntax=1
let b:undo_ftplugin.='|unlet! b:ale_python_mypy_ignore_invalid_syntax'
" Use mypy inside the python environment if needed
let b:ale_python_mypy_auto_pipenv=1
let b:undo_ftplugin.='|unlet! b:ale_python_mypy_auto_pipenv'
" Automatically format files when saving them
let b:ale_fix_on_save=1
let b:undo_ftplugin='|unlet! b:ale_lint_on_save'
" Change max length of a line to 88 for this buffer to match black's settings
setlocal colorcolumn=88
let b:undo_ftplugin.='|setlocal colorcolumn<'

View file

@ -1,8 +0,0 @@
" Create the `b:undo_ftplugin` variable if it doesn't exist
call ftplugined#check_undo_ft()
" Use h/l to go to the previous/next non-empty quickfix or location list
nnoremap <silent> <buffer> h :call quickfixed#older()<CR>
let b:undo_ftplugin.='|nunmap <buffer> h'
nnoremap <silent> <buffer> l :call quickfixed#newer()<CR>
let b:undo_ftplugin.='|nunmap <buffer> l'

View file

@ -1,31 +1,6 @@
" Create the `b:undo_ftplugin` variable if it doesn't exist
call ftplugined#check_undo_ft()
" Check tests too
let b:ale_rust_cargo_check_tests=1
let b:undo_ftplugin='|unlet! b:ale_rust_cargo_check_tests'
" Check examples too
let b:ale_rust_cargo_check_examples=1
let b:undo_ftplugin='|unlet! b:ale_rust_cargo_check_examples'
" Use clippy if it's available instead of just cargo check
let b:ale_rust_cargo_use_clippy=executable('cargo-clippy')
let b:undo_ftplugin='|unlet! b:ale_rust_cargo_use_clippy'
" Use rust-analyzer instead of RLS as a linter
let b:ale_linters=[ 'cargo', 'analyzer' ]
let b:undo_ftplugin='|unlet! b:ale_linters'
" Use rustfmt as ALE fixer for rust
let b:ale_fixers=[ 'rustfmt' ]
let b:undo_ftplugin.='|unlet! b:ale_fixers'
" Automatically format files when saving them
let b:ale_fix_on_save=1
let b:undo_ftplugin='|unlet! b:ale_lint_on_save'
" Change max length of a line to 99 for this buffer to match official guidelines
setlocal colorcolumn=99
let b:undo_ftplugin.='|setlocal colorcolumn<'

View file

@ -1,14 +0,0 @@
" Create the `b:undo_ftplugin` variable if it doesn't exist
call ftplugined#check_undo_ft()
" Use shfmt as ALE fixer for sh
let b:ale_fixers=[ 'shfmt' ]
let b:undo_ftplugin.='|unlet! b:ale_fixers'
" Indent with 4 spaces, simplify the code, indent switch cases, use POSIX
let b:ale_sh_shfmt_options='-i 4 -s -ci -ln posix'
let b:undo_ftplugin.='|unlet! b:ale_sh_shfmt_options'
" Require explicit empty string test
let b:ale_sh_shellcheck_options='-o avoid-nullary-conditions'
let b:undo_ftplugin.='|unlet! b:ale_sh_shellcheck_options'

View file

@ -0,0 +1,6 @@
" Create the `b:undo_ftplugin` variable if it doesn't exist
call ftplugined#check_undo_ft()
" Use a small indentation value on tiger files
setlocal shiftwidth=2
let b:undo_ftplugin.='|setlocal shiftwidth<'

View file

@ -1,14 +0,0 @@
" Create the `b:undo_ftplugin` variable if it doesn't exist
call ftplugined#check_undo_ft()
" Use shfmt as ALE fixer for zsh
let b:ale_fixers=[ 'shfmt' ]
let b:undo_ftplugin.='|unlet! b:ale_fixers'
" Indent with 4 spaces, simplify script, indent switch cases, use Bash variant
let b:ale_sh_shfmt_options='-i 4 -s -ci -ln bash'
let b:undo_ftplugin.='|unlet! b:ale_sh_shfmt_options'
" Use bash dialect explicitly, require explicit empty string test
let b:ale_sh_shellcheck_options='-s bash -o avoid-nullary-conditions'
let b:undo_ftplugin.='|unlet! b:ale_sh_shellcheck_options'

View file

@ -1,2 +0,0 @@
" Use ALE LSP-powered symbol information
nnoremap <Leader>K :ALEHover<CR>

View file

@ -0,0 +1,10 @@
local wk = require("which-key")
local keys = {
name = "Comment/uncomment",
c = "Current line",
u = "Uncomment the current and adjacent commented lines",
["gc"] = "Uncomment the current and adjacent commented lines",
}
wk.register(keys, { prefix = "gc" })

View file

@ -1,10 +0,0 @@
" Visual bindings for merging diffs as in normal mode
xnoremap dp :diffput<cr>
xnoremap do :diffget<cr>
" Open status window
nnoremap <Leader>gs :Gstatus<CR>
" Open diff view of current buffer: the up/left window is the current index
nnoremap <Leader>gd :Gdiffsplit!<CR>
" Open current file log in new tab, populate its location list with history
nnoremap <Leader>gl :sp<CR><C-w>T:Gllog --follow -- %:p<CR>

Some files were not shown because too many files have changed in this diff Show more