nix #11

Manually merged
geoffrey merged 113 commits from nix into main 2023-12-09 21:43:01 +01:00
3 changed files with 31 additions and 18 deletions
Showing only changes of commit 5d5750b2db - Show all commits

View file

@ -117,7 +117,6 @@ in
gdb = "gdb -x ${config.xdg.configHome}/gdbinit"; gdb = "gdb -x ${config.xdg.configHome}/gdbinit";
iftop = "iftop -c ${config.xdg.configHome}/iftoprc"; iftop = "iftop -c ${config.xdg.configHome}/iftoprc";
lmms = "lmms --config ${config.xdg.configHome}/lmmsrc.xml"; lmms = "lmms --config ${config.xdg.configHome}/lmmsrc.xml";
tmux = "tmux -f ${config.xdg.configHome}/tmux/tmux.conf";
# Preference # Preference
vi = "nvim"; vi = "nvim";
@ -310,6 +309,31 @@ in
}; };
extraConfig = builtins.readFile ./inputrc; extraConfig = builtins.readFile ./inputrc;
}; };
tmux =
let
themepack = pkgs.tmuxPlugins.mkTmuxPlugin
rec {
pluginName = "tmux-themepack";
version = "1.1.0";
rtpFilePath = "themepack.tmux";
src = pkgs.fetchFromGitHub {
owner = "jimeh";
repo = "tmux-themepack";
rev = "${version}";
sha256 = "f6y92kYsKDFanNx5ATx4BkaB/E7UrmyIHU/5Z01otQE=";
};
};
in
{
enable = true;
mouse = false;
clock24 = true;
# TODO Vim mode?
plugins = with pkgs.tmuxPlugins; [
sensible
];
extraConfig = builtins.readFile ./tmux.conf + "source-file ${themepack}/share/tmux-plugins/tmux-themepack/powerline/default/green.tmuxtheme\n";
};
}; };
services = { services = {
gpg-agent = { gpg-agent = {

View file

@ -28,8 +28,11 @@ in
}; };
}; };
targets.vim.enable = false; # FIXME Not compatible with nixvim for now (there's a MR) targets = {
# targets.i3.enable = false; # I prefer my own styles vim.enable = false; # FIXME Not compatible with nixvim for now (there's a MR)
i3.enable = false; # I prefer my own styles
tmux.enable = false; # Using another theme
};
}; };
# Fix https://nix-community.github.io/home-manager/index.html#_why_do_i_get_an_error_message_about_literal_ca_desrt_dconf_literal_or_literal_dconf_service_literal # Fix https://nix-community.github.io/home-manager/index.html#_why_do_i_get_an_error_message_about_literal_ca_desrt_dconf_literal_or_literal_dconf_service_literal
@ -37,4 +40,5 @@ in
dconf.enable = false; # Otherwise standalone home-manager complains it can't find /etc/dbus-1/session.conf on Arch. dconf.enable = false; # Otherwise standalone home-manager complains it can't find /etc/dbus-1/session.conf on Arch.
# Symlinking it to /usr/share/dbus-1/session.conf goes further but not much. # Symlinking it to /usr/share/dbus-1/session.conf goes further but not much.
} }

View file

@ -9,24 +9,9 @@ bind-key -n M-7 select-window -t 7
bind-key -n M-8 select-window -t 8 bind-key -n M-8 select-window -t 8
bind-key -n M-9 select-window -t 9 bind-key -n M-9 select-window -t 9
set -g mouse off
# https://superuser.com/a/1007721 # https://superuser.com/a/1007721
bind -n WheelUpPane if-shell -F -t = "#{mouse_any_flag}" "send-keys -M" "if -Ft= '#{pane_in_mode}' 'send-keys -M' 'copy-mode -e; send-keys -M'" bind -n WheelUpPane if-shell -F -t = "#{mouse_any_flag}" "send-keys -M" "if -Ft= '#{pane_in_mode}' 'send-keys -M' 'copy-mode -e; send-keys -M'"
# Inform tmux that alacritty supports RGB # Inform tmux that alacritty supports RGB
# (because for some reason terminfo doesn't?) # (because for some reason terminfo doesn't?)
set -ga terminal-overrides ',alacritty*:RGB' set -ga terminal-overrides ',alacritty*:RGB'
# List of plugins
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-sensible'
set -g @plugin 'jimeh/tmux-themepack'
set -g @themepack 'powerline/block/green'
set-environment -g TMUX_PLUGIN_MANAGER_PATH '~/.cache/tmuxplugins/'
# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
if "test ! -d ~/.cache/tmuxplugins/tpm" \
"run 'git clone https://github.com/tmux-plugins/tpm ~/.cache/tmuxplugins/tpm && ~/.cache/tmuxplugins/tpm/bin/install_plugins'"
run -b '~/.cache/tmuxplugins/tpm/tpm'