add base home config

This commit is contained in:
Freya Murphy 2024-10-22 22:45:46 -04:00
parent bece464df6
commit 64d3d91014
Signed by: freya
GPG key ID: 744AB800E383AE52
2 changed files with 94 additions and 66 deletions

75
home/base.scm Normal file
View file

@ -0,0 +1,75 @@
;; This "home-environment" file can be passed to 'guix home reconfigure'
;; to reproduce the content of your profile. This is "symbolic": it only
;; specifies package names. To reproduce the exact same profile, you also
;; need to capture the channels being used, as returned by "guix describe".
;; See the "Replicating Guix" section in the manual.
;; Guix base home config
;; Used for root
(use-modules (gnu home)
(gnu packages)
(gnu services)
(guix packages)
(guix gexp)
(gnu home services shells)
(gnu home services desktop)
(gnu home services)
(freya packages vim)
(freya packages shells)
(freya packages certs))
(home-environment
;; Below is the list of packages that will show up in your
;; Home profile, unser ~/.guix-home/profile.
(packages (append (specifications->packages (list ; devtools
"binutils"
"make"
"node"
"pkg-config"
"python-pynvim"
"git"
"openssl"
; langs
"gcc-toolchain"
"clang-toolchain"
"rust"
"python"
; shell
"zsh-syntax-highlighting"
"tree-sitter-cli"
"neofetch"
"pfetch"
"fd"))
(list ; system
freya-ca-certs
; programs
neovim-new
; shell
zsh-autosuggestions
vim-plug)))
;; Below is the list of Home services. To search for available
;; services, run 'guix home search KEYWORD' in a terminal.
(services
(list (service home-zsh-service-type
(home-zsh-configuration
(zshrc (list (local-file "config/zsh/zshrc")))
(zprofile (list (local-file "config/zsh/zprofile")))))
(service home-xdg-configuration-files-service-type
`(("nvim" ,(local-file "config/nvim" #:recursive? #t))))
(service home-files-service-type
`((".local/share/nvim/site/autoload/plug.vim" ,(file-append vim-plug "/share/vim/plug.vim"))
(".ssh/config" ,(local-file "config/ssh/config"))
(".gitconfig" ,(local-file "config/git/gitconfig"))))
(service home-dbus-service-type)
)))

View file

@ -23,13 +23,18 @@ set -o vi
set show-mode-in-prompt on
# Set shell prompt using starship
if command -v "starship" > /dev/null; then
eval "$(starship init zsh)"
else
export PS1="$$USER: "
fi
# Set guix reconfigure aliases
# reconfigure aliases
alias reconfigure-system="sudo -E guix system -L $HOME/.config/guix/modules reconfigure $HOME/.config/guix/systems/$(hostname).scm"
alias reconfigure-user="guix home -L $HOME/.config/guix/modules reconfigure $HOME/.config/guix/home/home.scm && home-manager switch"
alias reconfigure-user="guix home -L $HOME/.config/guix/modules reconfigure $HOME/.config/guix/home/home.scm"
alias reconfigure-nix="home-manager switch"
# Set other usefull aliases
# aliases
alias neo="pfetch"
alias rf="rm -fr" # remove le french hon hon hon
alias ls="ls --color=auto"
@ -38,10 +43,8 @@ alias grep="grep --color=auto"
alias diff="diff --color=auto"
alias ccat="highlight --out-format=ansi"
alias vim="nvim"
#alias show="kitten icat --align=left"
#alias ssh="kitten ssh"
# Have manpages use colors
# manpages
export LESS_TERMCAP_md=$'\e[1;36m'
export LESS_TERMCAP_me=$'\e[0m'
export LESS_TERMCAP_se=$'\e[0m'
@ -50,18 +53,14 @@ export LESS_TERMCAP_ue=$'\e[0m'
export LESS_TERMCAP_us=$'\e[1;35m'
export GROFF_NO_SGR=1
.reload() {
# Enable zsh auto suggestions
# enable zsh auto suggestions
autoload compinit && compinit
source $GUIX_PROFILE/share/zsh/zsh-autosuggestions/zsh-autosuggestions.zsh
source $GUIX_PROFILE/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE="fg=#696e8a"
ZSH_AUTOSUGGEST_STRATEGY=(completion history)
}
.reload
# Enable zsh keybinds for home, end, and other movement keybinds
# keybinds
bindkey "\e[1;5D" backward-word
bindkey "\e[1;5C" forward-word
bindkey "\e[3;5~" kill-word
@ -71,6 +70,7 @@ bindkey "\e[H" beginning-of-line
bindkey "\e[F" end-of-line
bindkey "\e\d" undo
# ranger
.ranger() {
ranger --choosedir=$HOME/.rangerdir < $TTY
LASTDIR=$(cat $HOME/.rangerdir)
@ -78,62 +78,15 @@ bindkey "\e\d" undo
zle reset-prompt
}
zle -N reload .reload
bindkey "^R" reload
zle -N ranger .ranger
bindkey "^F" range
# GPG SETUP FOR SSH
# gpg
export GPG_TTY=$(tty)
#export SSH_AUTH_SOCK=$(gpgconf --list-dirs agent-ssh-socket)
# ricing
export PF_CUSTOM_LOGOS="/home/freya/.config/zsh/pfetch_logos"
_wine() {
export WINEPREFIX="$HOME/.wine$1"
export WINEARCH="win$1"
/usr/bin/wine "${@:2}"
unset WINEARCH
unset WINEPREFIX
}
alias wine32="_wine 32"
alias wine64="_wine 64"
_winetricks() {
export WINEPREFIX="$HOME/.wine$1"
export WINEARCH="win$1"
/usr/bin/winetricks "${@:2}"
unset WINEARCH
unset WINEPREFIX
}
alias winetricks32="_winetricks 32"
alias winetricks64="_winetricks 64"
proton() {
if [ $# -lt 1 ]; then
return
fi
export STEAM_TMP_DIR="$HOME/.local/share/Steam/steamapps/compatdata/$1"
mkdir -p "$STEAM_TMP_DIR"
export STEAM_COMPAT_DATA_PATH="$STEAM_TMP_DIR"
export STEAM_COMPAT_CLIENT_INSTALL_PATH="$STEAM_TMP_DIR"
protonenv "$1"
$HOME/.local/share/Steam/steamapps/common/Proton\ -\ Experimental/proton run ${@:2}
}
protontricks() {
if [ $# -lt 1 ]; then
return
fi
export STEAM_TMP_DIR="$HOME/.local/share/Steam/steamapps/compatdata/$1"
mkdir -p "$STEAM_TMP_DIR"
export WINEPREFIX="$STEAM_TMP_DIR"
winetricks ${@:2}
}
pfetch
PWD="$HOME"