379 lines
8 KiB
Nix
379 lines
8 KiB
Nix
{ config, pkgs, lib, ... }:
|
|
with builtins;
|
|
with import ./modules/neovim-config.nix { inherit pkgs lib fromGitHub; };
|
|
{
|
|
home.username = "hive";
|
|
home.homeDirectory = "/home/hive";
|
|
home.stateVersion = import ./version.nix;
|
|
home.packages = with pkgs; [
|
|
appimage-run
|
|
steam-run
|
|
logseq
|
|
bat
|
|
diceware
|
|
evolution
|
|
prismlauncher
|
|
birdfont
|
|
ungoogled-chromium
|
|
darktable
|
|
nheko
|
|
mgba
|
|
blender
|
|
srain
|
|
onlyoffice-bin
|
|
dconf2nix
|
|
inkscape
|
|
minetest
|
|
vscodium
|
|
flare-signal
|
|
aria
|
|
pwgen
|
|
josm
|
|
xdg-ninja
|
|
godot_4
|
|
dino
|
|
jq
|
|
lapce
|
|
mangohud
|
|
nix-index
|
|
gimp
|
|
lollypop
|
|
skim
|
|
nix-output-monitor
|
|
picard
|
|
syncthing
|
|
armcord
|
|
ripgrep
|
|
tmate
|
|
comic-mono
|
|
comfortaa
|
|
btop
|
|
warp
|
|
virt-manager
|
|
mpv
|
|
wl-clipboard
|
|
adw-gtk3
|
|
(writeShellScriptBin "strings" ''${busybox}/bin/strings "$@"'')
|
|
] ++ ( with pkgs.gnome; [
|
|
gnome-tweaks
|
|
dconf-editor
|
|
gnome-boxes
|
|
] ++ ( with pkgs.gnomeExtensions; [
|
|
night-theme-switcher
|
|
unite
|
|
rounded-window-corners
|
|
appindicator
|
|
gsconnect
|
|
pano
|
|
unite
|
|
user-avatar-in-quick-settings
|
|
gamemode
|
|
]));
|
|
|
|
home.file = { # If managing individual files is needed
|
|
};
|
|
|
|
home.sessionVariables = {
|
|
# fish config
|
|
fish_greeting = "✨ heya ${config.home.username}, welcome to $(hostnamectl --pretty) ~";
|
|
|
|
EDITOR = "nvim";
|
|
|
|
NIXPKGS_ALLOW_UNFREE = 1;
|
|
|
|
# GAMEMODERUNEXEC = "nvidia-offload";
|
|
};
|
|
# configure dconf
|
|
# use dconf watch / to monitor for changes
|
|
# use dconf dump /path/to/keys | dconf2nix to generate automatically
|
|
dconf.settings = with lib.hm.gvariant; {
|
|
"org/gnome/shell" = {
|
|
disable-user-extensions = false;
|
|
disable-extension-version-validation = true;
|
|
enabled-extensions = [
|
|
"rounded-window-corners@yilozt"
|
|
"gsconnect@andyholmes.github.io"
|
|
"unite@hardpixel.eu"
|
|
"pano@elhan.io"
|
|
"quick-settings-avatar@d-go"
|
|
"appindicatorsupport@rgcjonas.gmail.com"
|
|
"gamemode@christian.kellner.me"
|
|
];
|
|
disabled-extensions = [];
|
|
favorite-apps = [
|
|
"firefox.desktop"
|
|
"org.gnome.Nautilus.desktop"
|
|
"org.gnome.Software.desktop"
|
|
];
|
|
};
|
|
"org/gnome/shell/extensions/unite" = {
|
|
extend-left-box = true;
|
|
show-window-buttons = "never";
|
|
show-window-title = "always";
|
|
};
|
|
"org/gnome/shell/extensions/rounded-window-corners" = {
|
|
custom-rounded-corner-settings = [(mkDictionaryEntry [
|
|
"org.wezfurlong.wezterm" (mkVariant [
|
|
(mkDictionaryEntry [
|
|
"padding" (mkVariant [
|
|
(mkDictionaryEntry [
|
|
"left" (mkVariant (mkUint32 13))
|
|
])
|
|
(mkDictionaryEntry [
|
|
"right" (mkVariant (mkUint32 14))
|
|
])
|
|
(mkDictionaryEntry [
|
|
"top" (mkVariant (mkUint32 29))
|
|
])
|
|
(mkDictionaryEntry [
|
|
"bottom" (mkVariant (mkUint32 13))
|
|
])
|
|
])
|
|
])
|
|
(mkDictionaryEntry [
|
|
"keep_rounded_corners" (mkVariant [
|
|
(mkDictionaryEntry [
|
|
"maximized" (mkVariant false)
|
|
])
|
|
(mkDictionaryEntry [
|
|
"fullscreen" (mkVariant false)
|
|
])
|
|
])
|
|
])
|
|
(mkDictionaryEntry [
|
|
"border_radius" (mkVariant (mkUint32 13))
|
|
])
|
|
(mkDictionaryEntry [
|
|
"smoothing" (mkVariant (mkUint32 0))
|
|
])
|
|
(mkDictionaryEntry [
|
|
"enabled" (mkVariant true)
|
|
])
|
|
])
|
|
])];
|
|
};
|
|
"org/gnome/mutter".center-new-windows = true;
|
|
"org/gnome/desktop/sound".allow-volume-above-100-percent = true;
|
|
"org/gnome/settings-daemon/plugins/media-keys".custom-keybindings = [
|
|
"/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0/"
|
|
];
|
|
"org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0" = {
|
|
binding = "<Super>t";
|
|
command = "wezterm";
|
|
name = "Wezterm";
|
|
};
|
|
};
|
|
|
|
# configure programs
|
|
programs.direnv = {
|
|
enable = true;
|
|
};
|
|
programs.firefox = { # TODO add options later
|
|
enable = true;
|
|
};
|
|
programs.home-manager.enable = true;
|
|
programs.zoxide = {
|
|
enable = true;
|
|
enableFishIntegration = true;
|
|
options = [ "--cmd cd" ];
|
|
};
|
|
programs.git = {
|
|
enable = true;
|
|
lfs.enable = true;
|
|
delta = {
|
|
enable = true;
|
|
options = {
|
|
decorations = {
|
|
commit-decoration-style = "bold yellow box ul";
|
|
file-decoration-style = "none";
|
|
file-style = "bold yellow ul";
|
|
hunk-header-decoration-style = "cyan box ul";
|
|
};
|
|
features = "side-by-side line-numbers decorations";
|
|
};
|
|
};
|
|
signing = {
|
|
key = "DD901BA40FBBB127";
|
|
signByDefault = true;
|
|
};
|
|
userEmail = "theotheroracle@disroot.org";
|
|
userName = "Bit Borealis";
|
|
extraConfig = {
|
|
init.defaultBranch = "main";
|
|
};
|
|
};
|
|
programs.neovim = {
|
|
enable = true;
|
|
defaultEditor = true;
|
|
viAlias = true;
|
|
vimAlias = true;
|
|
vimdiffAlias = true;
|
|
withNodeJs = true;
|
|
|
|
plugins = with pkgs.vimPlugins; [
|
|
editorconfig-nvim
|
|
vim-airline
|
|
vim-airline-themes
|
|
lsp_signature-nvim
|
|
nvim-colorizer-lua
|
|
nnn-vim
|
|
nvim-surround
|
|
nvim-treesitter.withAllGrammars
|
|
(fromGitHub "HEAD" "hiphish/rainbow-delimiters.nvim")
|
|
nvim-lspconfig
|
|
];
|
|
extraConfig = mkConfig {
|
|
settings = {
|
|
number = true;
|
|
linebreak = true;
|
|
showbreak = "+>";
|
|
textwidth = 80;
|
|
showmatch = true;
|
|
|
|
hlsearch = true;
|
|
smartcase = true;
|
|
ignorecase = true;
|
|
|
|
autoindent = true;
|
|
expandtab = false;
|
|
smartindent = true;
|
|
smarttab = true;
|
|
tabstop = 3;
|
|
shiftwidth = 3;
|
|
|
|
display = "lastline";
|
|
formatoptions = "jt";
|
|
ruler = true;
|
|
colorcolumn = 80;
|
|
termguicolors = true;
|
|
};
|
|
};
|
|
coc = {
|
|
enable = true;
|
|
};
|
|
};
|
|
programs.fish = {
|
|
enable = true;
|
|
shellAbbrs = {
|
|
e = "edit";
|
|
nvim = "edit";
|
|
nxs = "nix search nixpkgs";
|
|
nxr = "nix run nixpkgs#";
|
|
nxh = "nix shell nixpkgs#";
|
|
nxc = "sudo nix-collect-garbage -d";
|
|
};
|
|
shellAliases = {
|
|
edit = "$EDITOR";
|
|
csk = "cd (sk -e)";
|
|
nxu = ''sudo sh -c "nixos-rebuild boot --upgrade --log-format internal-json -v |& nom --json"'';
|
|
nxw = ''sudo sh -c "nixos-rebuild switch --log-format internal-json -v |& nom --json"'';
|
|
aria = "aria2c -c -k1M -x10";
|
|
dw = "diceware -n 6 -d -";
|
|
pw = "pwgen -By";
|
|
p = "ping -s 128 -O -c 100 -A -D 1.1.1.1";
|
|
pf = "sudo ping -f -c 100 -A 1.1.1.1";
|
|
};
|
|
functions = {
|
|
hme = ''
|
|
set -l hm_before_commit $PWD
|
|
cd ~/.config/home-manager/
|
|
git pull
|
|
cd $hm_before_commit
|
|
edit ~/.config/home-manager/home.nix
|
|
'';
|
|
hmu = ''
|
|
set -l hm_before_commit $PWD
|
|
cd ~/.config/home-manager/
|
|
gacp
|
|
cd $hm_before_commit
|
|
'';
|
|
gacp = ''
|
|
git diff
|
|
set gacp_read $(read -P 'continue ? [Y/n] ')
|
|
set gacp_n n
|
|
if [ "$gacp_read" != $gacp_n ]
|
|
git add .
|
|
git commit
|
|
git push
|
|
else
|
|
echo "cancelled ."
|
|
end
|
|
'';
|
|
|
|
ng = ''
|
|
set NG ~/.ssh/ng/
|
|
if test \( -e $NG/0 \) -a \( -e $NG/1 \)
|
|
echo (shuf -n 1 $NG/0) (shuf -n 1 $NG/1)
|
|
else
|
|
echo missing NG files
|
|
end
|
|
'';
|
|
fish_prompt = ''
|
|
set -l last_status $status
|
|
prompt_login
|
|
echo -n ' : '
|
|
set_color $fish_color_cwd
|
|
echo -n (prompt_pwd)
|
|
set_color normal
|
|
fish_vcs_prompt '|%s'
|
|
echo " ඞ"
|
|
if not test $last_status -eq 0
|
|
set_color $fish_color_error
|
|
end
|
|
echo -n "» "
|
|
set_color normal
|
|
'';
|
|
};
|
|
interactiveShellInit = ''
|
|
fish_add_path ~/.local/bin
|
|
fish_add_path ~/.local/bin/scripts
|
|
fish_add_path ~/.local/share/cargo/bin
|
|
fish_add_path ~/.local/share/flatpak/exports/bin
|
|
fish_add_path /var/lib/flatpak/exports/bin
|
|
fish_vi_key_bindings
|
|
'';
|
|
};
|
|
programs.password-store = {
|
|
enable = true;
|
|
package = pkgs.pass.withExtensions (exts: [ exts.pass-otp ]);
|
|
settings = {
|
|
PASSWORD_STORE_DIR = "${config.xdg.dataHome}/pass";
|
|
PASSWORD_STORE_CLIP_TIME = "60";
|
|
};
|
|
};
|
|
programs.wezterm = {
|
|
enable = true;
|
|
extraConfig = ''
|
|
return {
|
|
font = wezterm.font("Comic Mono"),
|
|
font_size = 12.0,
|
|
color_scheme = "Catppuccin Mocha",
|
|
hide_mouse_cursor_when_typing = false,
|
|
window_decorations = "INTEGRATED_BUTTONS | RESIZE",
|
|
integrated_title_button_style = "Gnome",
|
|
integrated_title_buttons = { 'Close' },
|
|
initial_cols = 84,
|
|
initial_rows = 28,
|
|
window_frame = {
|
|
inactive_titlebar_bg = '#1e1e2e',
|
|
active_titlebar_bg = '#1e1e2e',
|
|
font = wezterm.font {
|
|
family = "Comic Mono",
|
|
weight = "Regular",
|
|
},
|
|
},
|
|
}
|
|
'';
|
|
};
|
|
programs.browserpass.enable = true;
|
|
programs.gpg.enable = true;
|
|
|
|
|
|
# themeing
|
|
qt = {
|
|
enable = true;
|
|
platformTheme = "gnome";
|
|
style.name = "adwaita";
|
|
};
|
|
}
|