Compare commits
8 commits
9f548cffe3
...
4e26e1aa0b
| Author | SHA1 | Date | |
|---|---|---|---|
| 4e26e1aa0b | |||
| 1a2be3d84c | |||
| ca618b53cc | |||
| 88c00bb83d | |||
| 0dc8ac4433 | |||
| edeb67238b | |||
| 105bcbd53a | |||
| 84f1186b6c |
8 changed files with 102 additions and 51 deletions
18
flake.lock
generated
18
flake.lock
generated
|
|
@ -136,11 +136,11 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1739790043,
|
"lastModified": 1740624780,
|
||||||
"narHash": "sha256-4gK4zdNDQ4PyGFs7B6zp9iPIBy9E+bVJiZ0XAmncvgQ=",
|
"narHash": "sha256-8TP61AI3QBQsjzVUQFIV8NoB5nbYfJB3iHczhBikDkU=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "home-manager",
|
"repo": "home-manager",
|
||||||
"rev": "c1ea92cdfb85bd7b0995b550581d9fd1c3370bf9",
|
"rev": "b8869e4ead721bbd4f0d6b927e8395705d4f16e6",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|
@ -152,11 +152,11 @@
|
||||||
},
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1739580444,
|
"lastModified": 1740560979,
|
||||||
"narHash": "sha256-+/bSz4EAVbqz8/HsIGLroF8aNaO8bLRL7WfACN+24g4=",
|
"narHash": "sha256-Vr3Qi346M+8CjedtbyUevIGDZW8LcA1fTG0ugPY/Hic=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "8bb37161a0488b89830168b81c48aed11569cb93",
|
"rev": "5135c59491985879812717f4c9fea69604e7f26f",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|
@ -177,11 +177,11 @@
|
||||||
"treefmt-nix": "treefmt-nix"
|
"treefmt-nix": "treefmt-nix"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1739796551,
|
"lastModified": 1740655932,
|
||||||
"narHash": "sha256-XcTK29rOc0WxcSJDHUK8JQege9CzSVVAcjHdswOVFPA=",
|
"narHash": "sha256-BSTcgL2C74x0TgVdVEWfIz2SHkwIFMN0Dvv1lCoOhCA=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "NUR",
|
"repo": "NUR",
|
||||||
"rev": "827aa6eeaf92cc085f84947f6c32002792b67497",
|
"rev": "1ca8ff37f33a560c4a292ed83774434854f0b39a",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|
|
||||||
|
|
@ -15,6 +15,9 @@
|
||||||
# I use scripts that use the passthrough sequence often on this host
|
# I use scripts that use the passthrough sequence often on this host
|
||||||
enablePassthrough = true;
|
enablePassthrough = true;
|
||||||
|
|
||||||
|
# Frequent reboots mean that session persistence can be handy
|
||||||
|
enableResurrect = true;
|
||||||
|
|
||||||
terminalFeatures = {
|
terminalFeatures = {
|
||||||
# HTerm uses `xterm-256color` as its `$TERM`, so use that here
|
# HTerm uses `xterm-256color` as its `$TERM`, so use that here
|
||||||
xterm-256color = { };
|
xterm-256color = { };
|
||||||
|
|
|
||||||
|
|
@ -8,6 +8,7 @@
|
||||||
./bluetooth
|
./bluetooth
|
||||||
./calibre
|
./calibre
|
||||||
./comma
|
./comma
|
||||||
|
./delta
|
||||||
./dircolors
|
./dircolors
|
||||||
./direnv
|
./direnv
|
||||||
./discord
|
./discord
|
||||||
|
|
|
||||||
61
modules/home/delta/default.nix
Normal file
61
modules/home/delta/default.nix
Normal file
|
|
@ -0,0 +1,61 @@
|
||||||
|
{ config, pkgs, lib, ... }:
|
||||||
|
let
|
||||||
|
cfg = config.my.home.delta;
|
||||||
|
|
||||||
|
configFormat = pkgs.formats.gitIni { };
|
||||||
|
configPath = "${config.xdg.configHome}/delta/config";
|
||||||
|
in
|
||||||
|
{
|
||||||
|
options.my.home.delta = with lib; {
|
||||||
|
enable = my.mkDisableOption "delta configuration";
|
||||||
|
|
||||||
|
package = mkPackageOption pkgs "delta" { };
|
||||||
|
|
||||||
|
git = {
|
||||||
|
enable = my.mkDisableOption "git integration";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
config = lib.mkIf cfg.enable {
|
||||||
|
home.packages = [ cfg.package ];
|
||||||
|
|
||||||
|
xdg.configFile."delta/config".source = configFormat.generate "delta-config" {
|
||||||
|
delta = {
|
||||||
|
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";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.git = lib.mkIf cfg.git.enable {
|
||||||
|
delta = {
|
||||||
|
enable = true;
|
||||||
|
inherit (cfg) package;
|
||||||
|
};
|
||||||
|
|
||||||
|
includes = [
|
||||||
|
{
|
||||||
|
path = configPath;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
@ -61,19 +61,21 @@ in
|
||||||
"ui.systemUsesDarkTheme" = true; # Dark mode
|
"ui.systemUsesDarkTheme" = true; # Dark mode
|
||||||
};
|
};
|
||||||
|
|
||||||
extensions = with pkgs.nur.repos.rycee.firefox-addons; ([
|
extensions = {
|
||||||
bitwarden
|
packages = with pkgs.nur.repos.rycee.firefox-addons; ([
|
||||||
consent-o-matic
|
bitwarden
|
||||||
form-history-control
|
consent-o-matic
|
||||||
reddit-comment-collapser
|
form-history-control
|
||||||
reddit-enhancement-suite
|
reddit-comment-collapser
|
||||||
refined-github
|
reddit-enhancement-suite
|
||||||
sponsorblock
|
refined-github
|
||||||
ublock-origin
|
sponsorblock
|
||||||
]
|
ublock-origin
|
||||||
++ lib.optional (cfg.tridactyl.enable) tridactyl
|
]
|
||||||
++ lib.optional (cfg.ff2mpv.enable) ff2mpv
|
++ lib.optional (cfg.tridactyl.enable) tridactyl
|
||||||
);
|
++ lib.optional (cfg.ff2mpv.enable) ff2mpv
|
||||||
|
);
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
||||||
|
|
@ -42,34 +42,6 @@ in
|
||||||
|
|
||||||
lfs.enable = true;
|
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
|
# There's more
|
||||||
extraConfig = {
|
extraConfig = {
|
||||||
# Makes it a bit more readable
|
# Makes it a bit more readable
|
||||||
|
|
|
||||||
|
|
@ -20,6 +20,8 @@ in
|
||||||
|
|
||||||
enablePassthrough = mkEnableOption "tmux DCS passthrough sequence";
|
enablePassthrough = mkEnableOption "tmux DCS passthrough sequence";
|
||||||
|
|
||||||
|
enableResurrect = mkEnableOption "tmux-resurrect plugin";
|
||||||
|
|
||||||
terminalFeatures = mkOption {
|
terminalFeatures = mkOption {
|
||||||
type = with types; attrsOf (submodule {
|
type = with types; attrsOf (submodule {
|
||||||
options = {
|
options = {
|
||||||
|
|
@ -50,8 +52,9 @@ in
|
||||||
mouse = false; # I dislike mouse support
|
mouse = false; # I dislike mouse support
|
||||||
focusEvents = true; # Report focus events
|
focusEvents = true; # Report focus events
|
||||||
terminal = "tmux-256color"; # I want accurate termcap info
|
terminal = "tmux-256color"; # I want accurate termcap info
|
||||||
|
aggressiveResize = true; # Automatic resize when switching client size
|
||||||
|
|
||||||
plugins = with pkgs.tmuxPlugins; [
|
plugins = with pkgs.tmuxPlugins; builtins.filter (attr: attr != { }) [
|
||||||
# Open high-lighted files in copy mode
|
# Open high-lighted files in copy mode
|
||||||
open
|
open
|
||||||
# Better pane management
|
# Better pane management
|
||||||
|
|
@ -79,6 +82,13 @@ in
|
||||||
set -g status-right '#{prefix_highlight} %a %Y-%m-%d %H:%M'
|
set -g status-right '#{prefix_highlight} %a %Y-%m-%d %H:%M'
|
||||||
'';
|
'';
|
||||||
}
|
}
|
||||||
|
# Resurrect sessions
|
||||||
|
(lib.optionalAttrs cfg.enableResurrect {
|
||||||
|
plugin = resurrect;
|
||||||
|
extraConfig = ''
|
||||||
|
set -g @resurrect-dir '${config.xdg.stateHome}/tmux/resurrect'
|
||||||
|
'';
|
||||||
|
})
|
||||||
];
|
];
|
||||||
|
|
||||||
extraConfig = ''
|
extraConfig = ''
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,8 @@ local wk = require("which-key")
|
||||||
local detail = false
|
local detail = false
|
||||||
|
|
||||||
oil.setup({
|
oil.setup({
|
||||||
|
-- Don't show icons
|
||||||
|
columns = {},
|
||||||
view_options = {
|
view_options = {
|
||||||
-- Show files and directories that start with "." by default
|
-- Show files and directories that start with "." by default
|
||||||
show_hidden = true,
|
show_hidden = true,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue