1
0
Fork 0

home dir cleanup

This commit is contained in:
Luca Bilke 2023-02-09 14:50:48 +01:00
parent 9126b569aa
commit 69c3b0a825
4 changed files with 66 additions and 59 deletions

2
.config/git/config Normal file
View File

@ -0,0 +1,2 @@
[init]
defaultBranch = main

4
.config/npm/npmrc Normal file
View File

@ -0,0 +1,4 @@
prefix=${XDG_DATA_HOME}/npm
cache=${XDG_CACHE_HOME}/npm
tmp=${XDG_RUNTIME_DIR}/npm
init-module=${XDG_CONFIG_HOME}/npm/config/npm-init.js

View File

@ -2,8 +2,9 @@
# sudo not required for some system commands
for command in mount umount sv pacman apt updatedb su shutdown poweroff reboot; do
alias $command="sudo $command"
done; unset command
command -v $command 1>/dev/null 2>&1 && alias $command="sudo $command"
done
unset command
# Verbosity and settings that you pretty much just always are going to want.
alias \
@ -18,7 +19,7 @@ alias \
ls="ls -hN --color=auto --group-directories-first" \
grep="grep --color=auto" \
diff="diff --color=auto" \
nvidia-settings="nvidia-settings --config=$XDG_CONFIG_HOME/nvidia/settings"
# Colorize commands when possible.
alias \

View File

@ -15,26 +15,28 @@ export BROWSER="librewolf"
export XDG_CONFIG_HOME="$HOME/.config"
export XDG_DATA_HOME="$HOME/.local/share"
export XDG_CACHE_HOME="$HOME/.cache"
export PYENVS_DIR="${XDG_DATA_HOME:-$HOME/.local/share}/virtualenv"
export PYENVS_DIR="$XDG_DATA_HOME/virtualenv"
export KEYMAPS_DIR="$HOME/.local/bin/keymaps"
export ZSH_COMPDUMP="${XDG_CACHE_HOME:-$HOME/.cache}/zcompdump"
export NOTMUCH_CONFIG="${XDG_CONFIG_HOME:-$HOME/.config}/notmuch-config"
export GTK2_RC_FILES="${XDG_CONFIG_HOME:-$HOME/.config}/gtk-2.0/gtkrc-2.0"
export ZSH_COMPDUMP="$XDG_CACHE_HOME/zcompdump"
export NOTMUCH_CONFIG="$XDG_CONFIG_HOME/notmuch-config"
export GTK2_RC_FILES="$XDG_CONFIG_HOME/.config}/gtk-2.0/gtkrc-2.0"
export LESSHISTFILE="-"
export WGETRC="${XDG_CONFIG_HOME:-$HOME/.config}/wget/wgetrc"
export INPUTRC="${XDG_CONFIG_HOME:-$HOME/.config}/shell/inputrc"
export ZDOTDIR="${XDG_CONFIG_HOME:-$HOME/.config}/zsh"
export GNUPGHOME="${XDG_CONFIG_HOME:-$HOME/.config}/gnupg"
export WINEPREFIX="${XDG_DATA_HOME:-$HOME/.local/share}/wineprefixes/default"
export WGETRC="$XDG_CONFIG_HOME/wget/wgetrc"
export INPUTRC="$XDG_CONFIG_HOME/shell/inputrc"
export ZDOTDIR="$XDG_CONFIG_HOME/zsh"
export GNUPGHOME="$XDG_CONFIG_HOME/gnupg"
export WINEPREFIX="$XDG_DATA_HOME/wineprefixes/default"
export TMUX_TMPDIR="$XDG_RUNTIME_DIR"
export ANDROID_SDK_HOME="${XDG_CONFIG_HOME:-$HOME/.config}/android"
export CARGO_HOME="${XDG_DATA_HOME:-$HOME/.local/share}/cargo"
export GOPATH="${XDG_DATA_HOME:-$HOME/.local/share}/go"
export ANSIBLE_CONFIG="${XDG_CONFIG_HOME:-$HOME/.config}/ansible/ansible.cfg"
export UNISON="${XDG_DATA_HOME:-$HOME/.local/share}/unison"
export HISTFILE="${XDG_DATA_HOME:-$HOME/.local/share}/history"
export GRADLE_USER_HOME="${XDG_DATA_HOME:-$HOME/.local/share}/gradle"
export ANDROID_HOME="$XDG_DATA_HOME/android"
export CARGO_HOME="$XDG_DATA_HOME/cargo"
export GOPATH="$XDG_DATA_HOME/go"
export ANSIBLE_CONFIG="$XDG_CONFIG_HOME/ansible/ansible.cfg"
export ANSIBLE_HOME="$XDG_DATA_HOME/ansible"
export UNISON="$XDG_DATA_HOME/unison"
export HISTFILE="$XDG_DATA_HOME/history"
export GRADLE_USER_HOME="$XDG_DATA_HOME/gradle"
export XAUTHORITY="$XDG_RUNTIME_DIR/Xauthority" # WARN: This line can break some display managers
export NPM_CONFIG_USERCONFIG="$XDG_CONFIG_HOME"/npm/npmrc
# Other program settings:
export FZF_DEFAULT_OPTS="--layout=reverse --height 40%"
@ -49,6 +51,4 @@ export LESS_TERMCAP_ue="$(printf '%b' '')"
export LESSOPEN="| /usr/bin/highlight -O ansi %s 2>/dev/null"
export ANSIBLE_NOCOWS=1 # Stop those fucking cows in Ansible
[ ! -f "${XDG_CONFIG_HOME:-$HOME/.config}/shell/shortcutrc" ] && shortcuts >/dev/null 2>&1 &
[ -z "${DISPLAY}" ] && [ "${XDG_VTNR}" -eq 1 ] && ! pidof -s Xorg >/dev/null 2>&1 && exec startgraphical