Upgrade neovim plugins and clean Doom emacs
This commit is contained in:
parent
b0df5f4dc0
commit
c524c4c51a
131
modules/gui.nix
131
modules/gui.nix
|
@ -1,6 +1,8 @@
|
||||||
{ config, lib, pkgs, ... }:
|
{ config, lib, pkgs, ... }:
|
||||||
|
|
||||||
{
|
let tmux_config = builtins.readFile /home/coolneng/.tmux.conf;
|
||||||
|
|
||||||
|
in {
|
||||||
# Display manager
|
# Display manager
|
||||||
services.xserver.enable = true;
|
services.xserver.enable = true;
|
||||||
services.xserver.displayManager = {
|
services.xserver.displayManager = {
|
||||||
|
@ -82,92 +84,7 @@
|
||||||
shortcut = "x";
|
shortcut = "x";
|
||||||
terminal = "screen-256";
|
terminal = "screen-256";
|
||||||
baseIndex = 1;
|
baseIndex = 1;
|
||||||
extraConfig = ''
|
extraConfig = tmux_config;
|
||||||
## set terminal bell
|
|
||||||
set -g bell-action any
|
|
||||||
|
|
||||||
# i3 split bindings
|
|
||||||
bind g split-window -h
|
|
||||||
bind v split-window -v
|
|
||||||
unbind '"'
|
|
||||||
unbind %
|
|
||||||
unbind m
|
|
||||||
|
|
||||||
# vim split navigation
|
|
||||||
bind h select-pane -L
|
|
||||||
bind j select-pane -D
|
|
||||||
bind k select-pane -U
|
|
||||||
bind l select-pane -R
|
|
||||||
|
|
||||||
# equalize splits with x
|
|
||||||
unbind space
|
|
||||||
bind space select-layout even-vertical
|
|
||||||
|
|
||||||
# window switching
|
|
||||||
unbind n
|
|
||||||
unbind c
|
|
||||||
bind c new-window
|
|
||||||
unbind ,
|
|
||||||
unbind .
|
|
||||||
bind , previous-window
|
|
||||||
bind . next-window
|
|
||||||
bind-key n command-prompt "rename-window '%%'"
|
|
||||||
|
|
||||||
# change kill window bind
|
|
||||||
unbind &
|
|
||||||
unbind x
|
|
||||||
bind x kill-session
|
|
||||||
|
|
||||||
# switch to last session
|
|
||||||
bind S switch-client -l
|
|
||||||
|
|
||||||
# force a reload of the config file
|
|
||||||
unbind r
|
|
||||||
bind r source-file ~/.tmux.conf
|
|
||||||
|
|
||||||
set -g status on
|
|
||||||
set -g pane-base-index 1
|
|
||||||
set -g base-index 1
|
|
||||||
set -g set-titles on
|
|
||||||
set -g aggressive-resize on
|
|
||||||
set-option -g set-titles-string '#{pane_current_command}'
|
|
||||||
set-option -g visual-activity on
|
|
||||||
set-option -g status-position bottom
|
|
||||||
set-option -g renumber-windows on
|
|
||||||
set-window-option -g monitor-activity off
|
|
||||||
set-option -g allow-rename off
|
|
||||||
|
|
||||||
# copy mode
|
|
||||||
unbind [
|
|
||||||
bind Escape copy-mode
|
|
||||||
bind-key -T copy-mode-vi 'v' send -X begin-selection # Begin selection in copy mode.
|
|
||||||
bind-key -T copy-mode-vi 'C-v' send -X rectangle-toggle # Begin selection in copy mode.
|
|
||||||
bind-key -T copy-mode-vi 'y' send -X copy-selection # Yank selection in copy mode.
|
|
||||||
|
|
||||||
set -g mouse on
|
|
||||||
bind -T root WheelUpPane if-shell -F -t = "#{alternate_on}" "send-keys -M" "select-pane -t =; copy-mode -e; send-keys -M"
|
|
||||||
bind -T root WheelDownPane if-shell -F -t = "#{alternate_on}" "send-keys -M" "select-pane -t =; send-keys -M"
|
|
||||||
|
|
||||||
# Colorscheme
|
|
||||||
set -g status-justify "centre"
|
|
||||||
set -g status "on"
|
|
||||||
set -g status-left-style "none"
|
|
||||||
set -g message-command-style "fg=#c6c8d1,bg=#2e3244"
|
|
||||||
set -g status-right-style "none"
|
|
||||||
set -g pane-active-border-style "fg=#454b68"
|
|
||||||
set -g status-style "none,bg=#1e2132"
|
|
||||||
set -g message-style "fg=#c6c8d1,bg=#2e3244"
|
|
||||||
set -g pane-border-style "fg=#2e3244"
|
|
||||||
set -g status-right-length "100"
|
|
||||||
set -g status-left-length "100"
|
|
||||||
setw -g window-status-activity-style "none,fg=#454b68,bg=#1e2132"
|
|
||||||
setw -g window-status-separator ""
|
|
||||||
setw -g window-status-style "none,fg=#c6c8d1,bg=#1e2132"
|
|
||||||
set -g status-left "#[fg=#c6c8d1,bg=#454b68,bold] #S #[fg=#454b68,bg=#2e3244,nobold,nounderscore,noitalics]#[fg=#c6c8d1,bg=#1e2132] #[fg=#1e2132,bg=#1e2132,nobold,nounderscore,noitalics]"
|
|
||||||
set -g status-right "#[fg=#1e2132,bg=#1e2132,nobold,nounderscore,noitalics]#[fg=#c6c8d1,bg=#1e2132] #[fg=#2e3244,bg=#1e2132,nobold,nounderscore,noitalics]#[fg=#c6c8d1,bg=#2e3244] %b %d %Y #[fg=#454b68,bg=#2e3244,nobold,nounderscore,noitalics]#[fg=#c6c8d1,bg=#454b68,bold] %R #{prefix_highlight} "
|
|
||||||
setw -g window-status-format "#[fg=#1e2132,bg=#1e2132,nobold,nounderscore,noitalics] #[fg=#c6c8d1] #I #W #[fg=#1e2132,bg=#1e2132,nobold,nounderscore,noitalics]"
|
|
||||||
setw -g window-status-current-format "#[fg=#1e2132,bg=#2e3244,nobold,nounderscore,noitalics]#[fg=#c6c8d1,bg=#2e3244] #I #W #[fg=#2e3244,bg=#1e2132,nobold,nounderscore,noitalics]"
|
|
||||||
'';
|
|
||||||
};
|
};
|
||||||
|
|
||||||
# Automount external storage
|
# Automount external storage
|
||||||
|
@ -204,4 +121,44 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# Clean up Doom Emacs monthly
|
||||||
|
systemd.user.services.doom-purge = {
|
||||||
|
description = "Purge Doom Emacs";
|
||||||
|
wantedBy = [ "default.target" ];
|
||||||
|
path = [ pkgs.emacs pkgs.git ];
|
||||||
|
serviceConfig = {
|
||||||
|
Type = "oneshot";
|
||||||
|
ExecStart = "/bin/sh /home/coolneng/.emacs.d/bin/doom purge";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
systemd.user.timers.doom-purge = {
|
||||||
|
description = "Monthly purge of Doom Emacs";
|
||||||
|
wantedBy = [ "default.target" ];
|
||||||
|
timerConfig = {
|
||||||
|
OnCalendar = "13 22:00:00";
|
||||||
|
Unit = "doom-purge.service";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
# Upgrade Neovim plugins weekly
|
||||||
|
systemd.user.services.vim-plug-upgrade = {
|
||||||
|
description = "Upgrade Vim-Plug";
|
||||||
|
wantedBy = [ "default.target" ];
|
||||||
|
path = [ pkgs.git pkgs.neovim ];
|
||||||
|
serviceConfig = {
|
||||||
|
Type = "oneshot";
|
||||||
|
ExecStart = "${pkgs.neovim}/bin/nvim +PlugUpgrade +PlugUpdate +qa";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
systemd.user.timers.vim-plug-upgrade = {
|
||||||
|
description = "Weekly upgrade of Vim-Plug";
|
||||||
|
wantedBy = [ "default.target" ];
|
||||||
|
timerConfig = {
|
||||||
|
OnCalendar = "Wed 18:00:00";
|
||||||
|
Unit = "vim-plug-upgrade.service";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -35,6 +35,7 @@
|
||||||
nixfmt
|
nixfmt
|
||||||
podman-compose
|
podman-compose
|
||||||
shellcheck
|
shellcheck
|
||||||
|
shfmt
|
||||||
android-studio
|
android-studio
|
||||||
gnumake
|
gnumake
|
||||||
# Rice
|
# Rice
|
||||||
|
@ -50,8 +51,6 @@
|
||||||
zathura
|
zathura
|
||||||
libreoffice
|
libreoffice
|
||||||
gnome3.simple-scan
|
gnome3.simple-scan
|
||||||
# Propietary
|
|
||||||
skypeforlinux
|
|
||||||
# Mail stack
|
# Mail stack
|
||||||
neomutt
|
neomutt
|
||||||
isync
|
isync
|
||||||
|
@ -64,6 +63,7 @@
|
||||||
gimp
|
gimp
|
||||||
mpv
|
mpv
|
||||||
nodePackages.webtorrent-cli
|
nodePackages.webtorrent-cli
|
||||||
|
transmission-gtk
|
||||||
# File management
|
# File management
|
||||||
zip
|
zip
|
||||||
unzip
|
unzip
|
||||||
|
|
Loading…
Reference in New Issue