move to snowfall
This commit is contained in:
parent
9d7ad7c973
commit
769d4b0df5
188 changed files with 2203 additions and 3041 deletions
75
modules/home/shells/zsh/config/default.nix
Normal file
75
modules/home/shells/zsh/config/default.nix
Normal file
|
|
@ -0,0 +1,75 @@
|
|||
{pkgs, ...}: {
|
||||
# imports = [./zsh ./zsh/tools.nix ./starship.nix];
|
||||
|
||||
home.packages = with pkgs; [
|
||||
gnumake
|
||||
# Runs programs without installing them
|
||||
comma
|
||||
|
||||
# grep replacement
|
||||
ripgrep
|
||||
|
||||
# ping, but with cool graph
|
||||
gping
|
||||
|
||||
# dns client
|
||||
dogdns
|
||||
|
||||
# neofetch but for git repos
|
||||
onefetch
|
||||
|
||||
# neofetch but for cpu's
|
||||
cpufetch
|
||||
|
||||
# download from yt and other websites
|
||||
yt-dlp
|
||||
|
||||
zsh-history
|
||||
|
||||
# man pages for tiktok attention span mfs
|
||||
tealdeer
|
||||
|
||||
# markdown previewer
|
||||
glow
|
||||
|
||||
# profiling tool
|
||||
hyperfine
|
||||
|
||||
imagemagick
|
||||
ffmpeg-full
|
||||
|
||||
# preview images in terminal
|
||||
catimg
|
||||
|
||||
# networking stuff
|
||||
nmap
|
||||
wget
|
||||
|
||||
# faster find
|
||||
fd
|
||||
|
||||
# http request thingy
|
||||
xh
|
||||
|
||||
# generate regex
|
||||
grex
|
||||
|
||||
# json thingy
|
||||
jq
|
||||
|
||||
# syncthnig for acoustic people
|
||||
rsync
|
||||
|
||||
figlet
|
||||
# Generate qr codes
|
||||
qrencode
|
||||
|
||||
# script kidde stuff
|
||||
hcxdumptool
|
||||
hashcat
|
||||
|
||||
unzip
|
||||
# tshark
|
||||
# termshark
|
||||
];
|
||||
}
|
||||
26
modules/home/shells/zsh/config/starship.nix
Normal file
26
modules/home/shells/zsh/config/starship.nix
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
{config, ...}: {
|
||||
programs.starship = {
|
||||
enable = true;
|
||||
enableZshIntegration = config.programs.zsh.enable;
|
||||
settings = {
|
||||
add_newline = false;
|
||||
command_timeout = 1000;
|
||||
scan_timeout = 3;
|
||||
character = {
|
||||
error_symbol = "[](bold red)";
|
||||
success_symbol = "[](bold green)";
|
||||
vicmd_symbol = "[](bold yellow)";
|
||||
format = "$symbol [|](bold bright-black) ";
|
||||
};
|
||||
git_commit = {commit_hash_length = 7;};
|
||||
line_break.disabled = false;
|
||||
lua.symbol = "[](blue) ";
|
||||
python.symbol = "[](blue) ";
|
||||
hostname = {
|
||||
ssh_only = true;
|
||||
format = "[$hostname](bold blue) ";
|
||||
disabled = false;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
49
modules/home/shells/zsh/config/zsh/aliases.nix
Normal file
49
modules/home/shells/zsh/config/zsh/aliases.nix
Normal file
|
|
@ -0,0 +1,49 @@
|
|||
{
|
||||
pkgs,
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
with pkgs; {
|
||||
ytmp3 = ''
|
||||
${getExe yt-dlp} -x --continue --add-metadata --embed-thumbnail --audio-format mp3 --audio-quality 0 --metadata-from-title="%(artist)s - %(title)s" --prefer-ffmpeg -o "%(title)s.%(ext)s"'';
|
||||
cat = "${getExe bat} --style=plain";
|
||||
vpn = "mullvad";
|
||||
uuid = "cat /proc/sys/kernel/random/uuid";
|
||||
grep = getExe ripgrep;
|
||||
fzf = getExe skim;
|
||||
untar = "tar -xvf";
|
||||
untargz = "tar -xzf";
|
||||
MANPAGER = "sh -c 'col -bx | bat -l man -p'";
|
||||
du = getExe du-dust;
|
||||
ps = getExe procs;
|
||||
m = "mkdir -p";
|
||||
fcd = "cd $(find -type d | fzf)";
|
||||
l = "ls -lF --time-style=long-iso --icons";
|
||||
sc = "sudo systemctl";
|
||||
scu = "systemctl --user ";
|
||||
la = "${getExe eza} -lah --tree";
|
||||
ls = "${getExe eza} -h --git --icons --color=auto --group-directories-first -s extension";
|
||||
tree = "${getExe eza} --tree --icons --tree";
|
||||
kys = "shutdown now";
|
||||
gpl = "curl https://www.gnu.org/licenses/gpl-3.0.txt -o LICENSE";
|
||||
agpl = "curl https://www.gnu.org/licenses/agpl-3.0.txt -o LICENSE";
|
||||
tsm = "transmission-remote";
|
||||
g = "git";
|
||||
n = "nix";
|
||||
r = "rebuild";
|
||||
vm = "nixos-rebuild build-vm --flake ~/nixos#earth";
|
||||
mnt = "udisksctl mount -b";
|
||||
umnt = "udisksctl unmount -b";
|
||||
burn = "pkill -9";
|
||||
diff = "diff --color=auto";
|
||||
wu = "nmcli con up zachary_myers";
|
||||
wd = "nmcli con down zachary_myers";
|
||||
"v" = "nvim";
|
||||
".." = "cd ..";
|
||||
"..." = "cd ../../";
|
||||
"...." = "cd ../../../";
|
||||
"....." = "cd ../../../../";
|
||||
"......" = "cd ../../../../../";
|
||||
}
|
||||
71
modules/home/shells/zsh/config/zsh/default.nix
Normal file
71
modules/home/shells/zsh/config/zsh/default.nix
Normal file
|
|
@ -0,0 +1,71 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
inherit (builtins) concatStringsSep;
|
||||
in {
|
||||
home.sessionVariables.STARSHIP_CACHE = "${config.xdg.cacheHome}/starship";
|
||||
|
||||
programs.zsh = {
|
||||
enable = true;
|
||||
sessionVariables = {
|
||||
LC_ALL = "en_US.UTF-8";
|
||||
ZSH_AUTOSUGGEST_USE_ASYNC = "true";
|
||||
SSH_AUTH_SOCK = "/run/user/1000/keyring/ssh";
|
||||
};
|
||||
enableAutosuggestions = true;
|
||||
history = {
|
||||
save = 2137;
|
||||
size = 2137;
|
||||
expireDuplicatesFirst = true;
|
||||
ignoreDups = true;
|
||||
ignoreSpace = true;
|
||||
};
|
||||
|
||||
initExtra = let
|
||||
sources = with pkgs; [
|
||||
"${zsh-nix-shell}/share/zsh-nix-shell/nix-shell.plugin.zsh"
|
||||
"${zsh-history}/share/zsh/init.zsh"
|
||||
"${zsh-fzf-tab}/share/fzf-tab/fzf-tab.plugin.zsh"
|
||||
"${zsh-f-sy-h}/share/zsh/site-functions/F-Sy-H.plugin.zsh"
|
||||
"${zsh-autocomplete}/share/zsh-autocomplete/zsh-autocomplete.plugin.zsh"
|
||||
"${zsh-you-should-use}/share/zsh/plugins/you-should-use/you-should-use.plugin.zsh"
|
||||
"${zsh-navigation-tools}/share/zsh/site-functions/zsh-navigation-tools.plugin.zsh"
|
||||
];
|
||||
|
||||
source = map (source: "source ${source}") sources;
|
||||
|
||||
plugins = concatStringsSep "\n" ([
|
||||
"${pkgs.any-nix-shell}/bin/any-nix-shell zsh --info-right | source /dev/stdin"
|
||||
]
|
||||
++ source);
|
||||
in ''
|
||||
${plugins}
|
||||
|
||||
bindkey "^[[1;5C" forward-word
|
||||
bindkey "^[[1;5D" backward-word
|
||||
'';
|
||||
|
||||
plugins = [
|
||||
{
|
||||
name = "zsh-tmux";
|
||||
file = "zsh-tmux.plugin.zsh";
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "laggardkernel";
|
||||
repo = "zsh-tmux";
|
||||
rev = "v1.1.0";
|
||||
sha256 = "sha256-BB9L84HjUnV1OUIp2U2lHYHEg5q4p/TgqLcsCvInkC8=";
|
||||
};
|
||||
}
|
||||
];
|
||||
|
||||
dirHashes = {
|
||||
music = "$HOME/Music";
|
||||
media = "/run/media/$USER";
|
||||
};
|
||||
|
||||
shellAliases = import ./aliases.nix {inherit pkgs lib config;};
|
||||
};
|
||||
}
|
||||
59
modules/home/shells/zsh/config/zsh/tools.nix
Normal file
59
modules/home/shells/zsh/config/zsh/tools.nix
Normal file
|
|
@ -0,0 +1,59 @@
|
|||
{
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
programs = {
|
||||
gpg.enable = true;
|
||||
man.enable = true;
|
||||
eza.enable = true;
|
||||
dircolors = {
|
||||
enable = true;
|
||||
enableZshIntegration = true;
|
||||
};
|
||||
|
||||
skim = {
|
||||
enable = true;
|
||||
enableZshIntegration = true;
|
||||
defaultCommand = "rg --files --hidden";
|
||||
changeDirWidgetOptions = [
|
||||
"--preview 'eza --icons --git --color always -T -L 3 {} | head -200'"
|
||||
"--exact"
|
||||
];
|
||||
};
|
||||
direnv = {
|
||||
enable = true;
|
||||
nix-direnv.enable = true;
|
||||
};
|
||||
tealdeer = {
|
||||
enable = true;
|
||||
settings = {
|
||||
display = {
|
||||
compact = false;
|
||||
use_pager = true;
|
||||
};
|
||||
updates = {
|
||||
auto_update = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
# bat = {
|
||||
# enable = true;
|
||||
# config = {
|
||||
# pager = "less -FR";
|
||||
# theme = "catppuccin-frappe";
|
||||
# };
|
||||
# themes = {
|
||||
# catppuccin-frappe = {
|
||||
# src = pkgs.fetchFromGitHub {
|
||||
# owner = "catppuccin";
|
||||
# repo = "bat";
|
||||
# rev = "ba4d16880d63e656acced2b7d4e034e4a93f74b1";
|
||||
# sha256 = "6WVKQErGdaqb++oaXnY3i6/GuH2FhTgK0v4TN4Y0Wbw=";
|
||||
# };
|
||||
# file = "Catppuccin-frappe.tmTheme";
|
||||
# };
|
||||
# };
|
||||
# };
|
||||
};
|
||||
}
|
||||
86
modules/home/shells/zsh/default.nix
Normal file
86
modules/home/shells/zsh/default.nix
Normal file
|
|
@ -0,0 +1,86 @@
|
|||
{
|
||||
options,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
with lib.custom; let
|
||||
cfg = config.shells.zsh;
|
||||
in {
|
||||
options.shells.zsh = with types; {
|
||||
enable = mkBoolOpt false "Enable Zsh Configuration";
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
home.packages = with pkgs; [
|
||||
gnumake
|
||||
# Runs programs without installing them
|
||||
comma
|
||||
|
||||
# grep replacement
|
||||
ripgrep
|
||||
|
||||
# ping, but with cool graph
|
||||
gping
|
||||
|
||||
# dns client
|
||||
dogdns
|
||||
|
||||
# neofetch but for git repos
|
||||
onefetch
|
||||
|
||||
# neofetch but for cpu's
|
||||
cpufetch
|
||||
|
||||
# download from yt and other websites
|
||||
yt-dlp
|
||||
|
||||
zsh-history
|
||||
|
||||
# man pages for tiktok attention span mfs
|
||||
tealdeer
|
||||
|
||||
# markdown previewer
|
||||
glow
|
||||
|
||||
# profiling tool
|
||||
hyperfine
|
||||
|
||||
imagemagick
|
||||
ffmpeg-full
|
||||
|
||||
# preview images in terminal
|
||||
catimg
|
||||
|
||||
# networking stuff
|
||||
nmap
|
||||
wget
|
||||
|
||||
# faster find
|
||||
fd
|
||||
|
||||
# http request thingy
|
||||
xh
|
||||
|
||||
# generate regex
|
||||
grex
|
||||
|
||||
# json thingy
|
||||
jq
|
||||
|
||||
# syncthnig for acoustic people
|
||||
rsync
|
||||
|
||||
figlet
|
||||
# Generate qr codes
|
||||
qrencode
|
||||
|
||||
# script kidde stuff
|
||||
hcxdumptool
|
||||
hashcat
|
||||
|
||||
unzip
|
||||
];
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue