You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
324 lines
9.5 KiB
Nix
324 lines
9.5 KiB
Nix
{ pkgs, lib, ... }:
|
|
|
|
{
|
|
home.packages = with pkgs; [ bat wget clipit ncmpcpp pandoc silver-searcher tree unzip wirelesstools xcape xsel anki pavucontrol ranger blueman gifsicle networkmanager paprefs steam mpv nnn nodejs pinentry vlc gnupg nitrogen alacritty wine tldr yarn spotify signal-desktop mu mosh ispell google-chrome emacs-all-the-icons-fonts gnupg python3 python37Packages.pip veracrypt bashmount exfat exfat-utils neofetch toot rtv newsboat neomutt i3lock-pixeled nmap p4v killall calc cargo cava diceware magic-wormhole msmtp xorg.xmodmap zip youtube-dl cacert dropbox-cli keepassx2 w3m wireshark-qt khard khal vdirsyncer slack riot-web retroarch ipfs gimp blender urlview
|
|
];
|
|
|
|
home.sessionVariables = {
|
|
EDITOR = "vim";
|
|
BROWSER = "firefox";
|
|
LEDGER_FILE = ~/Sync/Ledger/ledger.ledger;
|
|
|
|
P4USER = "dswan";
|
|
P4PORT = "humu.iocom.com:1666";
|
|
P4CONFIG = "p4.cfg";
|
|
P4EDITOR = "nvim";
|
|
P4IGNORE = ".ignore";
|
|
};
|
|
|
|
services.mpd = {
|
|
enable = true;
|
|
musicDirectory = "/home/dustinswan/Music";
|
|
playlistDirectory = "/home/dustinswan/Music/Playlists";
|
|
};
|
|
|
|
services.syncthing = {
|
|
enable = true;
|
|
tray = true;
|
|
};
|
|
|
|
services.compton = {
|
|
enable = true;
|
|
inactiveOpacity = "0.90";
|
|
};
|
|
|
|
services.gpg-agent = {
|
|
enable = true;
|
|
enableSshSupport = true;
|
|
defaultCacheTtl = 86400;
|
|
maxCacheTtl = 86400;
|
|
defaultCacheTtlSsh = 86400;
|
|
maxCacheTtlSsh = 86400;
|
|
extraConfig = ''
|
|
pinentry-program /home/dustinswan/.nix-profile/bin/pinentry
|
|
'';
|
|
};
|
|
|
|
services.polybar = {
|
|
enable = true;
|
|
package = pkgs.polybar.override {
|
|
i3GapsSupport = true;
|
|
mpdSupport = true;
|
|
alsaSupport = true;
|
|
};
|
|
config = ~/dotfiles/polybar;
|
|
script = "PATH=$PATH:${pkgs.i3-gaps}/bin polybar top &";
|
|
};
|
|
|
|
services.screen-locker = {
|
|
enable = true;
|
|
inactiveInterval = 30;
|
|
lockCmd = "${pkgs.i3lock-pixeled}/bin/i3lock-pixeled";
|
|
};
|
|
|
|
services.dunst = {
|
|
enable = true;
|
|
iconTheme = {
|
|
package = pkgs.numix-icon-theme;
|
|
name = "Numix";
|
|
size = "32";
|
|
};
|
|
settings = {
|
|
global = {
|
|
geometry = "300x5-30+50";
|
|
padding = 12;
|
|
horizontal_padding = 12;
|
|
transparency = 10;
|
|
frame_color = "#66aaff";
|
|
frame_width = 2;
|
|
font = "Iosevka Nerd Font Regular 9";
|
|
markup = "full";
|
|
word_wrap = true;
|
|
format = "<b>%s</b> \n %b";
|
|
icon_position = "left";
|
|
|
|
background = "#000000";
|
|
foreground = "#dddddd";
|
|
};
|
|
|
|
urgency_low = {
|
|
background = "#000000";
|
|
foreground = "#dddddd";
|
|
};
|
|
|
|
urgency_normal = {
|
|
background = "#000000";
|
|
foreground = "#dddddd";
|
|
};
|
|
|
|
urgency_critical = {
|
|
foreground = "#eceff1";
|
|
background = "#bd2c40";
|
|
frame_color = "#9b0a20";
|
|
};
|
|
};
|
|
};
|
|
# services.udiskie.enable = true;
|
|
services.unclutter.enable = true;
|
|
# services.keepassx.enable = true;
|
|
services.flameshot.enable = true;
|
|
services.keybase.enable = true;
|
|
services.pasystray.enable = true;
|
|
services.network-manager-applet.enable = true;
|
|
services.blueman-applet.enable = true;
|
|
services.emacs.enable = true;
|
|
|
|
programs.home-manager.enable = true;
|
|
programs.htop.enable = true;
|
|
programs.jq.enable = true;
|
|
programs.vscode.enable = true;
|
|
programs.tmux = {
|
|
enable = true;
|
|
shortcut = "a";
|
|
keyMode = "vi";
|
|
baseIndex = 1;
|
|
newSession = true;
|
|
plugins = with pkgs.tmuxPlugins; [
|
|
sensible resurrect pain-control continuum copycat open urlview
|
|
{
|
|
plugin = yank;
|
|
extraConfig = "set -g @yank_selection_mouse 'primary'";
|
|
}
|
|
];
|
|
extraConfig = ''
|
|
bind-key -n C-0 select-window -t :0
|
|
bind-key -n C-1 select-window -t :1
|
|
bind-key -n C-2 select-window -t :2
|
|
bind-key -n C-3 select-window -t :3
|
|
bind-key -n C-4 select-window -t :4
|
|
bind-key -n C-5 select-window -t :5
|
|
bind-key -n C-6 select-window -t :6
|
|
bind-key -n C-7 select-window -t :7
|
|
bind-key -n C-8 select-window -t :8
|
|
bind-key -n C-9 select-window -t :9
|
|
|
|
set -g set-titles on
|
|
set -g set-titles-string "#H (#S)"
|
|
set -g status-right ""
|
|
set -g status-left ""
|
|
|
|
set-option -g mouse on
|
|
set-option -g status-bg default
|
|
set-option -g status-fg "#666666"
|
|
set-option -g status-attr default
|
|
set-option -g pane-border-fg "#666666"
|
|
set-option -g pane-active-border-fg "#666666"
|
|
set-option -g message-bg black
|
|
set-option -g message-fg white
|
|
set-option -g display-panes-active-colour white
|
|
set-option -g display-panes-colour white
|
|
|
|
set-window-option -g window-status-fg "#666666"
|
|
set-window-option -g window-status-bg default
|
|
set-window-option -g window-status-current-fg white
|
|
set-window-option -g window-status-current-bg default
|
|
set-window-option -g window-status-format " #W"
|
|
set-window-option -g window-status-current-format " #W"
|
|
set-window-option -g window-status-separator " "
|
|
set-window-option -g clock-mode-colour white
|
|
|
|
# remove when tmux-plugin-navigator plugin is added
|
|
is_vim="ps -o state= -o comm= -t '#{pane_tty}' \
|
|
| grep -iqE '^[^TXZ ]+ +(\\S+\\/)?g?(view|n?vim?x?)(diff)?$'"
|
|
tmux bind-key -n C-h if-shell "$is_vim" "send-keys C-h" "select-pane -L"
|
|
tmux bind-key -n C-j if-shell "$is_vim" "send-keys C-j" "select-pane -D"
|
|
tmux bind-key -n C-k if-shell "$is_vim" "send-keys C-k" "select-pane -U"
|
|
tmux bind-key -n C-l if-shell "$is_vim" "send-keys C-l" "select-pane -R"
|
|
tmux bind-key -n C-\\ if-shell "$is_vim" "send-keys C-\\" "select-pane -l"
|
|
tmux bind-key -T copy-mode-vi C-h select-pane -L
|
|
tmux bind-key -T copy-mode-vi C-j select-pane -D
|
|
tmux bind-key -T copy-mode-vi C-k select-pane -U
|
|
tmux bind-key -T copy-mode-vi C-l select-pane -R
|
|
tmux bind-key -T copy-mode-vi C-\\ select-pane -l
|
|
'';
|
|
};
|
|
# programs.fish = {
|
|
# enable = true;
|
|
# shellAliases = {
|
|
# l = "ls -la";
|
|
# ta = "tmux attach -d";
|
|
# e = "emacsclient -a \"\" -t -nw";
|
|
# weather = "curl http://wttr.in";
|
|
# er = "rm -rf logs; unzip -o";
|
|
# };
|
|
# };
|
|
programs.zsh = {
|
|
enable = true;
|
|
enableAutosuggestions = true;
|
|
oh-my-zsh = {
|
|
enable = true;
|
|
plugins = [ "git" ];
|
|
theme = "refined";
|
|
};
|
|
shellAliases = {
|
|
l = "ls -la";
|
|
ta = "tmux attach -d";
|
|
e = "emacsclient -a \"\" -t -nw";
|
|
weather = "curl http://wttr.in";
|
|
er = "rm -rf logs; unzip -o";
|
|
};
|
|
};
|
|
programs.firefox.enable = true;
|
|
programs.fzf = {
|
|
enable = true;
|
|
enableZshIntegration = true;
|
|
};
|
|
programs.feh.enable = true;
|
|
programs.git = {
|
|
enable = true;
|
|
userName = "Dustin Swan";
|
|
userEmail = "dustin@dustinswan.com";
|
|
};
|
|
programs.emacs.enable = true;
|
|
programs.neovim = {
|
|
enable = true;
|
|
viAlias = true;
|
|
vimAlias = true;
|
|
withNodeJs = true;
|
|
withPython3 = true;
|
|
configure = {
|
|
customRC = builtins.readFile ~/dotfiles/vimrc;
|
|
};
|
|
};
|
|
programs.keychain = {
|
|
enable = true;
|
|
enableZshIntegration = true;
|
|
inheritType = "any";
|
|
agents = ["gpg" "ssh"];
|
|
keys = ["id_rsa" "2B3A6377"];
|
|
# extraFlags = "--quiet";
|
|
};
|
|
programs.rofi = {
|
|
enable = true;
|
|
};
|
|
programs.beets = {
|
|
enable = true;
|
|
settings = {
|
|
directory = "~/Music";
|
|
library = "~/Music/musiclibrary.db";
|
|
import = {
|
|
copy = true;
|
|
};
|
|
plugins = [ "lastgenre" "fetchart" "embedart" "lyrics" "scrub" "mpdupdate" ]; # TODO bandcamp
|
|
lastfm = {
|
|
user = "dustinswan";
|
|
};
|
|
bandcamp = {
|
|
lyrics = true;
|
|
art = true;
|
|
};
|
|
};
|
|
};
|
|
|
|
xsession = {
|
|
enable = true;
|
|
profileExtra = builtins.readFile ~/dotfiles/xprofile;
|
|
windowManager.i3 = {
|
|
enable = true;
|
|
package = pkgs.i3-gaps;
|
|
config = {
|
|
modifier = "Mod4";
|
|
gaps = {
|
|
inner = 10;
|
|
outer = 0;
|
|
smartBorders = "on";
|
|
};
|
|
window = {
|
|
border = 0;
|
|
commands = [
|
|
{ criteria = { class = "mpv"; }; command = "floating enable, move absolute position center"; }
|
|
{ criteria = { class = "feh"; }; command = "floating enable, move absolute position center"; }
|
|
];
|
|
};
|
|
bars = [];
|
|
startup = [{
|
|
command = "systemctl --user restart polybar";
|
|
always = true;
|
|
notification = false;
|
|
}];
|
|
keybindings = let mod = "Mod4"; in lib.mkOptionDefault {
|
|
"${mod}+space" = "exec \"rofi -show combi\"";
|
|
"${mod}+Return" = "exec alacritty";
|
|
"${mod}+Ctrl+Mod1+t" = "exec alacritty";
|
|
"${mod}+Ctrl+Mod1+e" = "exec \"emacsclient -c\"";
|
|
"${mod}+Ctrl+Mod1+b" = "exec firefox";
|
|
"${mod}+h" = "focus left";
|
|
"${mod}+j" = "focus down";
|
|
"${mod}+k" = "focus up";
|
|
"${mod}+l" = "focus right";
|
|
|
|
"${mod}+Shift+h" = "move left";
|
|
"${mod}+Shift+j" = "move down";
|
|
"${mod}+Shift+k" = "move up";
|
|
"${mod}+Shift+l" = "move right";
|
|
|
|
"${mod}+s" = "layout stacking";
|
|
"${mod}+comma" = "layout tabbed";
|
|
"${mod}+period" = "layout toggle split";
|
|
|
|
"${mod}+apostrophe" = "split h";
|
|
"${mod}+minus" = "split v";
|
|
|
|
"${mod}+Shift+space" = "floating toggle";
|
|
"${mod}+Ctrl+space" = "focus mode_toggle";
|
|
|
|
"${mod}+p" = "focus parent";
|
|
"${mod}+c" = "focus child";
|
|
"${mod}+r" = "mode resize";
|
|
};
|
|
};
|
|
# extraConfig = builtins.readFile ~/dotfiles/i3;
|
|
};
|
|
};
|
|
}
|