mirror of
https://github.com/eRgo35/nix-config.git
synced 2026-02-04 19:36:13 +01:00
error resolution
This commit is contained in:
40
home-manager/features/cli/aliases.nix
Normal file
40
home-manager/features/cli/aliases.nix
Normal file
@@ -0,0 +1,40 @@
|
|||||||
|
{
|
||||||
|
myAliases = {
|
||||||
|
".." = "cd ..";
|
||||||
|
"cd.." = "cd ..";
|
||||||
|
|
||||||
|
ls = "command eza";
|
||||||
|
grep = "grep --color=auto";
|
||||||
|
fgrep = "fgrep --color=auto";
|
||||||
|
egrep = "egrep --color=auto";
|
||||||
|
|
||||||
|
l="eza -G --icons";
|
||||||
|
ll="eza -l --icons";
|
||||||
|
lg="eza -lG";
|
||||||
|
lall="eza -lahF --icons --git";
|
||||||
|
lalg="eza -laGhF --icons --git";
|
||||||
|
latree="eza -laGghHT --git --icons";
|
||||||
|
la = "eza -la --git --icons";
|
||||||
|
lsd = "eza -laD";
|
||||||
|
|
||||||
|
cls="clear";
|
||||||
|
# df="df -ahiT --total";
|
||||||
|
userlist="cut -d: -f1 /etc/passwd";
|
||||||
|
free="free -mt";
|
||||||
|
du="du -ach | sort -h";
|
||||||
|
ps="ps auxf";
|
||||||
|
|
||||||
|
sudo="sudo ";
|
||||||
|
reload="exec $SHELL -l";
|
||||||
|
|
||||||
|
xclip = "xclip -selection c";
|
||||||
|
|
||||||
|
mkdir="mkdir -pv";
|
||||||
|
psmem="ps -e -orss=,args= | sort -b -k1 -nr";
|
||||||
|
psmem10="ps -e -orss=,args= | sort -b -k1 -nr | head -10";
|
||||||
|
pscpu="ps -e -o pcpu,cpu,nice,state,cputime,args|sort -k1,1n -nr";
|
||||||
|
pscpu10="ps -e -o pcpu,cpu,nice,state,cputime,args|sort -k1,1n -nr | head -10";
|
||||||
|
|
||||||
|
gua = "git remote | xargs -L1 git push --all";
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -1,4 +1,7 @@
|
|||||||
programs.bash = {
|
let cli = import ./aliases.nix; in
|
||||||
enable = true;
|
{
|
||||||
shellAliases = myAliases;
|
programs.bash = {
|
||||||
};
|
enable = true;
|
||||||
|
shellAliases = cli.myAliases;
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
imports = [
|
imports = [
|
||||||
./bash.nix
|
./bash.nix
|
||||||
./git.nix
|
./git.nix
|
||||||
./zsh.nix
|
./zsh
|
||||||
];
|
];
|
||||||
# home.packages = with pkgs; [];
|
# home.packages = with pkgs; [];
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,26 +1,28 @@
|
|||||||
programs.git = {
|
{
|
||||||
enable = true;
|
programs.git = {
|
||||||
userName = "Michał Czyż";
|
enable = true;
|
||||||
userEmail = "mike@c2yz.com";
|
userName = "Michał Czyż";
|
||||||
signing = {
|
userEmail = "mike@c2yz.com";
|
||||||
key = "78D4829A477DAB25";
|
signing = {
|
||||||
signByDefault = true;
|
key = "78D4829A477DAB25";
|
||||||
};
|
signByDefault = true;
|
||||||
extraConfig = {
|
|
||||||
push = {
|
|
||||||
default = "simple";
|
|
||||||
};
|
};
|
||||||
rerere = {
|
extraConfig = {
|
||||||
enable = true;
|
push = {
|
||||||
};
|
default = "simple";
|
||||||
column = {
|
};
|
||||||
ui = "auto";
|
rerere = {
|
||||||
};
|
enable = true;
|
||||||
branch = {
|
};
|
||||||
sort = "-committerdate";
|
column = {
|
||||||
};
|
ui = "auto";
|
||||||
init = {
|
};
|
||||||
defaultBranch = "main";
|
branch = {
|
||||||
|
sort = "-committerdate";
|
||||||
|
};
|
||||||
|
init = {
|
||||||
|
defaultBranch = "main";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
}
|
||||||
|
|||||||
@@ -1,35 +0,0 @@
|
|||||||
programs.zsh = {
|
|
||||||
enable = true;
|
|
||||||
enableCompletion = true;
|
|
||||||
|
|
||||||
history.size = 10000000;
|
|
||||||
history.path = "${config.xdg.dataHome}/zsh/history";
|
|
||||||
|
|
||||||
shellAliases = myAliases;
|
|
||||||
|
|
||||||
initExtra = ''
|
|
||||||
[[ ! -f ${./p10k.zsh} ]] || source ${./p10k.zsh}
|
|
||||||
eval "$(zoxide init zsh)"
|
|
||||||
'';
|
|
||||||
plugins = [
|
|
||||||
{
|
|
||||||
name = "powerlevel10k";
|
|
||||||
src = pkgs.zsh-powerlevel10k;
|
|
||||||
file = "share/zsh-powerlevel10k/powerlevel10k.zsh-theme";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
|
|
||||||
zplug = {
|
|
||||||
enable = true;
|
|
||||||
plugins = [
|
|
||||||
{ name = "zsh-users/zsh-autosuggestions"; }
|
|
||||||
# { name = "romkatv/powerlevel10k"; tags = [ as:theme depth:1 ]; }
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
oh-my-zsh = {
|
|
||||||
enable = true;
|
|
||||||
plugins = [ "git" ];
|
|
||||||
};
|
|
||||||
|
|
||||||
};
|
|
||||||
39
home-manager/features/cli/zsh/default.nix
Normal file
39
home-manager/features/cli/zsh/default.nix
Normal file
@@ -0,0 +1,39 @@
|
|||||||
|
{config, pkgs, ...}: let
|
||||||
|
cli = import ../aliases.nix;
|
||||||
|
in {
|
||||||
|
programs.zsh = {
|
||||||
|
enable = true;
|
||||||
|
enableCompletion = true;
|
||||||
|
|
||||||
|
history.size = 10000000;
|
||||||
|
history.path = "${config.xdg.dataHome}/zsh/history";
|
||||||
|
|
||||||
|
shellAliases = cli.myAliases;
|
||||||
|
|
||||||
|
initExtra = ''
|
||||||
|
[[ ! -f ${./p10k.zsh} ]] || source ${./p10k.zsh}
|
||||||
|
eval "$(zoxide init zsh)"
|
||||||
|
'';
|
||||||
|
plugins = [
|
||||||
|
{
|
||||||
|
name = "powerlevel10k";
|
||||||
|
src = pkgs.zsh-powerlevel10k;
|
||||||
|
file = "share/zsh-powerlevel10k/powerlevel10k.zsh-theme";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
|
||||||
|
zplug = {
|
||||||
|
enable = true;
|
||||||
|
plugins = [
|
||||||
|
{ name = "zsh-users/zsh-autosuggestions"; }
|
||||||
|
# { name = "romkatv/powerlevel10k"; tags = [ as:theme depth:1 ]; }
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
oh-my-zsh = {
|
||||||
|
enable = true;
|
||||||
|
plugins = [ "git" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -1,9 +1,11 @@
|
|||||||
programs.kitty = {
|
{
|
||||||
enable = true;
|
programs.kitty = {
|
||||||
font = {
|
enable = true;
|
||||||
name = "FiraCode Nerd Font";
|
font = {
|
||||||
size = 12;
|
name = "FiraCode Nerd Font";
|
||||||
};
|
size = 12;
|
||||||
|
};
|
||||||
|
|
||||||
theme = "Gruvbox Dark";
|
theme = "Gruvbox Dark";
|
||||||
};
|
};
|
||||||
|
}
|
||||||
|
|||||||
@@ -1,10 +1,12 @@
|
|||||||
programs.neovim = {
|
{pkgs, ...}: {
|
||||||
enable = true;
|
programs.neovim = {
|
||||||
package = pkgs.unstable.neovim-unwrapped;
|
enable = true;
|
||||||
|
package = pkgs.unstable.neovim-unwrapped;
|
||||||
|
|
||||||
viAlias = true;
|
viAlias = true;
|
||||||
vimAlias = true;
|
vimAlias = true;
|
||||||
vimdiffAlias = true;
|
vimdiffAlias = true;
|
||||||
|
|
||||||
defaultEditor = true;
|
defaultEditor = true;
|
||||||
};
|
};
|
||||||
|
}
|
||||||
|
|||||||
@@ -7,46 +7,7 @@
|
|||||||
config,
|
config,
|
||||||
pkgs,
|
pkgs,
|
||||||
...
|
...
|
||||||
}: let
|
}: {
|
||||||
myAliases = {
|
|
||||||
".." = "cd ..";
|
|
||||||
"cd.." = "cd ..";
|
|
||||||
|
|
||||||
ls = "command eza";
|
|
||||||
grep = "grep --color=auto";
|
|
||||||
fgrep = "fgrep --color=auto";
|
|
||||||
egrep = "egrep --color=auto";
|
|
||||||
|
|
||||||
l="eza -G --icons";
|
|
||||||
ll="eza -l --icons";
|
|
||||||
lg="eza -lG";
|
|
||||||
lall="eza -lahF --icons --git";
|
|
||||||
lalg="eza -laGhF --icons --git";
|
|
||||||
latree="eza -laGghHT --git --icons";
|
|
||||||
la = "eza -la --git --icons";
|
|
||||||
lsd = "eza -laD";
|
|
||||||
|
|
||||||
cls="clear";
|
|
||||||
# df="df -ahiT --total";
|
|
||||||
userlist="cut -d: -f1 /etc/passwd";
|
|
||||||
free="free -mt";
|
|
||||||
du="du -ach | sort -h";
|
|
||||||
ps="ps auxf";
|
|
||||||
|
|
||||||
sudo="sudo ";
|
|
||||||
reload="exec $SHELL -l";
|
|
||||||
|
|
||||||
xclip = "xclip -selection c";
|
|
||||||
|
|
||||||
mkdir="mkdir -pv";
|
|
||||||
psmem="ps -e -orss=,args= | sort -b -k1 -nr";
|
|
||||||
psmem10="ps -e -orss=,args= | sort -b -k1 -nr | head -10";
|
|
||||||
pscpu="ps -e -o pcpu,cpu,nice,state,cputime,args|sort -k1,1n -nr";
|
|
||||||
pscpu10="ps -e -o pcpu,cpu,nice,state,cputime,args|sort -k1,1n -nr | head -10";
|
|
||||||
|
|
||||||
gua = "git remote | xargs -L1 git push --all";
|
|
||||||
};
|
|
||||||
in {
|
|
||||||
# You can import other home-manager modules here
|
# You can import other home-manager modules here
|
||||||
imports = [
|
imports = [
|
||||||
# If you want to use modules your own flake exports (from modules/home-manager):
|
# If you want to use modules your own flake exports (from modules/home-manager):
|
||||||
@@ -156,7 +117,7 @@ in {
|
|||||||
discord
|
discord
|
||||||
telegram-desktop
|
telegram-desktop
|
||||||
libreoffice-fresh
|
libreoffice-fresh
|
||||||
vscodium
|
# vscodium
|
||||||
vscode
|
vscode
|
||||||
neovide
|
neovide
|
||||||
lunarvim
|
lunarvim
|
||||||
|
|||||||
Reference in New Issue
Block a user