please work
This commit is contained in:
parent
a8d370b9d5
commit
026074a7fe
3 changed files with 18 additions and 38 deletions
|
|
@ -1,25 +1,14 @@
|
||||||
for _hm in "/etc/profiles/per-user/$(id -un)" "$HOME/.nix-profile"; do
|
shopt -s autocd cdspell dirspell globstar histappend
|
||||||
[ -f "$_hm/etc/profile.d/hm-session-vars.sh" ] && . "$_hm/etc/profile.d/hm-session-vars.sh" && break
|
|
||||||
done
|
|
||||||
unset _hm
|
|
||||||
|
|
||||||
shopt -s autocd globstar histappend
|
|
||||||
|
|
||||||
HISTFILE="${XDG_STATE_HOME:-$HOME/.local/state}/bash_history"
|
HISTFILE="${XDG_STATE_HOME:-$HOME/.local/state}/bash_history"
|
||||||
HISTSIZE=2000
|
HISTSIZE=50000
|
||||||
HISTFILESIZE=2000
|
HISTFILESIZE=50000
|
||||||
HISTCONTROL=ignoreboth:erasedups
|
HISTCONTROL=ignoreboth:erasedups
|
||||||
|
|
||||||
export GPG_TTY=$(tty)
|
export GPG_TTY=$(tty)
|
||||||
export THEME="${THEME:-midnight}"
|
|
||||||
export FZF_COMPLETION_TRIGGER=';'
|
export FZF_COMPLETION_TRIGGER=';'
|
||||||
export FZF_TMUX=1
|
export FZF_TMUX=1
|
||||||
|
|
||||||
eval "$(fzf --bash)"
|
|
||||||
eval "$(direnv hook bash)"
|
|
||||||
eval "$(starship init bash)"
|
|
||||||
eval "$(zoxide init bash)"
|
|
||||||
|
|
||||||
fzf-config-widget() {
|
fzf-config-widget() {
|
||||||
local selected
|
local selected
|
||||||
selected="$(rg --files --hidden "$HOME"/.config | sed "s|$HOME|~|" | \
|
selected="$(rg --files --hidden "$HOME"/.config | sed "s|$HOME|~|" | \
|
||||||
|
|
|
||||||
|
|
@ -113,6 +113,10 @@ in
|
||||||
(lib.mkIf claude {
|
(lib.mkIf claude {
|
||||||
CLAUDE_CONFIG_DIR = "${config.xdg.configHome}/claude";
|
CLAUDE_CONFIG_DIR = "${config.xdg.configHome}/claude";
|
||||||
})
|
})
|
||||||
|
{
|
||||||
|
THEME = config.theme;
|
||||||
|
INPUTRC = "${repoDir}/config/bash/inputrc";
|
||||||
|
}
|
||||||
];
|
];
|
||||||
|
|
||||||
home.sessionPath = lib.mkMerge [
|
home.sessionPath = lib.mkMerge [
|
||||||
|
|
@ -195,26 +199,19 @@ in
|
||||||
}
|
}
|
||||||
'';
|
'';
|
||||||
|
|
||||||
programs.bash = lib.mkIf (!hostConfig.isNixOS) {
|
programs.bash = {
|
||||||
enable = true;
|
enable = true;
|
||||||
shellAliases = {
|
shellAliases = lib.mkIf (!hostConfig.isNixOS) {
|
||||||
ls = "eza";
|
|
||||||
l = "ls --color=auto --group-directories-first";
|
|
||||||
ll = "l -alF";
|
|
||||||
la = "ll -R";
|
|
||||||
g = "git";
|
g = "git";
|
||||||
nv = "nvim";
|
nv = "nvim";
|
||||||
};
|
};
|
||||||
initExtra = ''
|
initExtra = lib.mkAfter ''
|
||||||
export INPUTRC="$HOME/.config/nix/config/bash/inputrc"
|
|
||||||
export THEME="''${THEME:-midnight}"
|
|
||||||
[ -f "$HOME/.config/nix/config/bash/bashrc" ] && . "$HOME/.config/nix/config/bash/bashrc"
|
[ -f "$HOME/.config/nix/config/bash/bashrc" ] && . "$HOME/.config/nix/config/bash/bashrc"
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
programs.starship = {
|
programs.starship = {
|
||||||
enable = true;
|
enable = true;
|
||||||
enableBashIntegration = false;
|
|
||||||
settings = {
|
settings = {
|
||||||
format = lib.concatStrings [
|
format = lib.concatStrings [
|
||||||
"$directory"
|
"$directory"
|
||||||
|
|
@ -265,7 +262,6 @@ in
|
||||||
|
|
||||||
programs.fzf = {
|
programs.fzf = {
|
||||||
enable = true;
|
enable = true;
|
||||||
enableBashIntegration = false;
|
|
||||||
defaultCommand = "rg --files --hidden";
|
defaultCommand = "rg --files --hidden";
|
||||||
defaultOptions = [
|
defaultOptions = [
|
||||||
"--bind=ctrl-a:select-all"
|
"--bind=ctrl-a:select-all"
|
||||||
|
|
@ -281,18 +277,15 @@ in
|
||||||
|
|
||||||
programs.eza = {
|
programs.eza = {
|
||||||
enable = true;
|
enable = true;
|
||||||
enableBashIntegration = false;
|
|
||||||
git = true;
|
git = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
programs.zoxide = {
|
programs.zoxide = {
|
||||||
enable = true;
|
enable = true;
|
||||||
enableBashIntegration = false;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
programs.direnv = {
|
programs.direnv = {
|
||||||
enable = true;
|
enable = true;
|
||||||
enableBashIntegration = false;
|
|
||||||
nix-direnv.enable = true;
|
nix-direnv.enable = true;
|
||||||
config.global = {
|
config.global = {
|
||||||
hide_env_diff = true;
|
hide_env_diff = true;
|
||||||
|
|
|
||||||
|
|
@ -87,19 +87,17 @@ in
|
||||||
programs.bash = {
|
programs.bash = {
|
||||||
enable = true;
|
enable = true;
|
||||||
shellAliases = {
|
shellAliases = {
|
||||||
ls = "eza";
|
|
||||||
l = "ls --color=auto --group-directories-first";
|
|
||||||
ll = "l -alF";
|
|
||||||
la = "ll -R";
|
|
||||||
g = "git";
|
g = "git";
|
||||||
nv = "nvim";
|
nv = "nvim";
|
||||||
};
|
};
|
||||||
shellInit = ''
|
loginShellInit = ''
|
||||||
export INPUTRC="$HOME/.config/nix/config/bash/inputrc"
|
for _hm in "/etc/profiles/per-user/$(id -un)" "$HOME/.nix-profile"; do
|
||||||
export THEME="midnight"
|
[ -f "$_hm/etc/profile.d/hm-session-vars.sh" ] && . "$_hm/etc/profile.d/hm-session-vars.sh" && break
|
||||||
'';
|
done
|
||||||
interactiveShellInit = ''
|
unset _hm
|
||||||
[ -f "$HOME/.config/nix/config/bash/bashrc" ] && . "$HOME/.config/nix/config/bash/bashrc"
|
if [ "$(tty)" = "/dev/tty1" ]; then
|
||||||
|
exec Hyprland
|
||||||
|
fi
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
programs.hyprland = {
|
programs.hyprland = {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue