Compare commits

...

7 Commits

10 changed files with 97 additions and 223 deletions

42
.bash_aliases Normal file
View File

@@ -0,0 +1,42 @@
#!/bin/bash
#
# ~/.bash_aliases
# this file is sourced in ~/.bashrc and defines aliases used by the shell.
#
# replace some default tools with different ones
alias grep='rg'
alias ls='eza -Abhg --colour=auto'
# set default options
alias dir='dir --color=auto'
alias vdir='vdir --color=auto'
alias diff='diff --color'
alias info='info --vi-keys'
alias make='make -j'
alias ip='ip -c'
# aliases to avoid mistakes
alias cp='cp -i'
alias mv='mv -i'
alias rm='rm -I'
# aliases for quitting
alias :qa='exit'
alias :q='exit'
alias qa='exit'
alias q='exit'
alias quit='exit'
# alternate versions of writing the same thing
alias lls='ls -l'
alias ll='ls -l'
# aliases basically for things that I am too lazy to type fully
alias py3='python3'
alias batman='bat -l man'
alias icat='kitten icat'
alias ..='cd ..'
alias ....='cd ../..'
alias ......='cd ../../..'
alias ........='cd ../../../..'

View File

@@ -1,4 +1,4 @@
# shellcheck shell=bash #!/bin/sh
# #
# ~/.bash_logout # ~/.bash_logout
# sourced when an interactive login shell exits, or a non-interactive login shell executes `exit` # sourced when an interactive login shell exits, or a non-interactive login shell executes `exit`

View File

@@ -1,4 +1,4 @@
# shellcheck shell=bash #!/bin/sh
# shellcheck disable=1091 # shellcheck disable=1091
# #
# ~/.bash_profile # ~/.bash_profile
@@ -13,7 +13,7 @@ export XDG_STATE_HOME="$HOME/var/lib" # state data that should persist between
export XDG_CACHE_HOME="$HOME/var/cache" # user-specific non-essential (cached) data. export XDG_CACHE_HOME="$HOME/var/cache" # user-specific non-essential (cached) data.
export PATH="$XDG_BIN_HOME:$PATH" # add our bin in front of PATH, making it take precedence export PATH="$XDG_BIN_HOME:$PATH" # add our bin in front of PATH, making it take precedence
if command -v nvim &>/dev/null; then if command -v nvim >/dev/null; then
export EDITOR=nvim # use neovim as an editor export EDITOR=nvim # use neovim as an editor
export VISUAL=nvim # use neovim for visual-based editors export VISUAL=nvim # use neovim for visual-based editors
export MANPAGER='nvim +Man!' # use neovim as a manual pager export MANPAGER='nvim +Man!' # use neovim as a manual pager
@@ -22,14 +22,16 @@ fi
# coloured GCC warnings and errors # coloured GCC warnings and errors
export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01' export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'
# export Microsoft's bullshit outta here # Microsoft bullshit
export DOTNET_CLI_TELEMETRY_OPTOUT=1 export DOTNET_CLI_TELEMETRY_OPTOUT=1
export VCPKG_DISABLE_METRICS=1 export VCPKG_DISABLE_METRICS=1
export VCPKG_ROOT="$XDG_DATA_HOME/vcpkg" export VCPKG_ROOT="$XDG_DATA_HOME/vcpkg"
export PATH+=":$VCPKG_ROOT" export PATH="$PATH:$VCPKG_ROOT"
# if executing interactively # if executing interactively
# execute .bashrc in the current login context # execute .bashrc in the current login context
[[ $- != *i* ]] && return case $- in
[[ -z ${PS1-} ]] && retrun *i*) return ;;
[[ -f $HOME/.bashrc ]] && . "$HOME/.bashrc" esac
[ -z "${PS1-}" ] && return
[ -f "$HOME/.bashrc" ] && . "$HOME/.bashrc"

122
.bashrc
View File

@@ -1,35 +1,22 @@
# shellcheck shell=bash #!/bin/bash
# shellcheck disable=SC1090,SC1091 # shellcheck disable=SC1091,SC2155
# #
# ~/.bashrc # ~/.bashrc
# sourced upon launch of an interactive shell, which isn't a login shell has been executed # sourced upon launch of an interactive shell, which isn't a login shell has been executed
# #
# If not running interactively, don't do anything case $- in
[[ $- != *i* ]] && return *i*) return ;;
[[ -z "${PS1-}" ]] && return esac
[ -z "${PS1-}" ] && return
# wrapper for lazily loading __git_ps1 whenever it is actually needed
_lazy_git_ps1() {
if [[ -z $__GIT_PROMPT_SOURCED ]]; then
. /usr/share/bash-completion/completions/git &>/dev/null
. /usr/share/git/completion/git-prompt.sh &>/dev/null
if [ -d .git ] || git worktree list &>/dev/null; then
export __GIT_PROMPT_SOURCED=1
__git_ps1 "$@"
fi
else
__git_ps1 "$@"
fi
}
# lazy loading of ssh agents # lazy loading of ssh agents
_lazy_ssh() { _lazy_ssh() {
if [[ -z $SSH_AUTH_SOCK ]]; then if [ -z "$SSH_AUTH_SOCK" ]; then
eval "$(ssh-agent -s)" &>/dev/null eval "$(ssh-agent -s)" >/dev/null
ssh-add "$HOME/.ssh/github" &>/dev/null ssh-add "$HOME/.ssh/github" >/dev/null
ssh-add "$HOME/.ssh/gitea" &>/dev/null ssh-add "$HOME/.ssh/gitea" >/dev/null
ssh-add "$HOME/.ssh/admin@homeserver" &>/dev/null ssh-add "$HOME/.ssh/admin@homeserver" >/dev/null
fi fi
} }
# aliases so the function is called beforehand # aliases so the function is called beforehand
@@ -42,68 +29,49 @@ _make() {
-e "s/^([Mm]akefile:[0-9]+:.*)/\x1b[33m\1\x1b[0m/" \ -e "s/^([Mm]akefile:[0-9]+:.*)/\x1b[33m\1\x1b[0m/" \
-e "s/^.*error.*$/\x1b[31m&\x1b[0m/I" >&2) -e "s/^.*error.*$/\x1b[31m&\x1b[0m/I" >&2)
} }
alias make='_make'
# # lazily loads the git utilities, to prevent slowdowns
# envs __lazy_git_ps1() {
# if [ -z "$__GIT_PROMPT_SOURCED__" ]; then
# set PS1 if [ -d .git ] || git worktree list &>/dev/null; then
PS1='\[\033[?25h\]' # show cursor . /usr/share/bash-completion/completions/git &>/dev/null
PS1="$PS1"'\[\033[01;35m\]\u@\h' # user@host . /usr/share/git/completion/git-prompt.sh &>/dev/null
PS1="$PS1"'\[\033[00m\]:' # separator export __GIT_PROMPT_SOURCED__=1
PS1="$PS1"'\[\033[01;34m\]\w' # working directory __git_ps1
PS1="$PS1"'\[\033[01;93m\]$(_lazy_git_ps1)' # github branch fi
PS1="$PS1"'\[\033[00m\]\$ ' # shell sign else __git_ps1; fi
return 0
}
# regenerates the PS1 prompt
__regenprompt() {
local err=$? # acquire the error code of the last executed command
local git=$(__lazy_git_ps1)
if [ $err -ne 0 ]; then
err="\033[s\033[$((COLUMNS - 4))G${err}\033[u"
else unset err; fi
PS1="\[\033[?25h\]" # show cursor
PS1="$PS1\[\033[01;35m\]\u@\h" # user@host
PS1="$PS1\[\033[00m\]:" # separator
PS1="$PS1\[\033[01;34m\]\w" # working directory
PS1="$PS1\[\033[01;93m\]$git" # git branch
PS1="$PS1\[\033[01;31m\]\[$err\]" # error code
PS1="$PS1\[\033[00m\]\$ " # shell sign
}
PROMPT_COMMAND=__regenprompt
# history settings # history settings
HISTSIZE=2048 HISTSIZE=2048
HISTCONTROL=erasedups:ignoredups:ignorespace HISTCONTROL=erasedups:ignoredups:ignorespace
HISTIGNORE='exit*:clear*:\:*:echo*' HISTIGNORE='exit*:clear*:\:*:echo*'
#
# bash completion
#
. /home/user/.local/share/vcpkg/scripts/vcpkg_completion.bash &>/dev/null # fucking vcpkg
shopt -s checkwinsize # check the window size after each command (and if necessary, the values of LINES and COLUMNS) shopt -s checkwinsize # check the window size after each command (and if necessary, the values of LINES and COLUMNS)
shopt -s globstar # enable globstar (**/*) shopt -s globstar # enable globstar (**/*)
# [ -f "$HOME/.bash_aliases" ] && . .bash_aliases
# aliases
#
# aliases for colour
alias dir='dir --color=auto'
alias vdir='vdir --color=auto'
alias ls='eza -Abhg --colour=auto'
alias grep='rg'
alias diff='diff --color'
alias ip='ip -c'
# application aliases
alias ncdu='ncdu --color=dark -t 16'
alias bat='bat --wrap never --tabs 4 --theme gruvbox-dark'
alias make='_make -j'
# aliases to avoid mistakes
alias cp='cp -i'
alias mv='mv -i'
alias rm='rm -I'
alias :qa='exit'
alias qa='exit'
alias :q='exit'
alias q='exit'
alias py3='python3'
alias info='info --vi-keys'
alias batman='bat -l man'
# quality of life short-hands
alias ..='cd ..'
alias ....='cd ../..'
alias ......='cd ../../..'
alias ........='cd ../../../..'
alias lls="ls -l"
alias ll="ls -l"
# cute lil hyfetch :3 # cute lil hyfetch :3
[[ $TERM == "xterm-kitty" ]] && fastfetch [ "$TERM" == "xterm-kitty" ] && fastfetch

6
.gitmodules vendored
View File

@@ -1,6 +0,0 @@
[submodule "etc/nvim"]
path = etc/nvim
url = git@thepigeongenerator.xyz:thepigeongenerator/nvim-conf.git
[submodule "etc/i3"]
path = etc/i3
url = git@thepigeongenerator.xyz:thepigeongenerator/i3-conf.git

View File

@@ -1,19 +0,0 @@
# DO NOT EDIT! This file will be overwritten by LXAppearance.
# Any customization should be done in ~/.gtkrc-2.0.mine instead.
include "/home/furry/.gtkrc-2.0.mine"
gtk-theme-name="Gruvbox-Dark"
gtk-icon-theme-name="Gruvbox-Plus-Dark"
gtk-font-name="NotoSans Nerd Font 11"
gtk-cursor-theme-name="Breeze"
gtk-cursor-theme-size=0
gtk-toolbar-style=GTK_TOOLBAR_BOTH
gtk-toolbar-icon-size=GTK_ICON_SIZE_LARGE_TOOLBAR
gtk-button-images=1
gtk-menu-images=1
gtk-enable-event-sounds=1
gtk-enable-input-feedback-sounds=1
gtk-xft-antialias=1
gtk-xft-hinting=1
gtk-xft-hintstyle="hintfull"
gtk-xft-rgba="none"

2
.nv/.gitignore vendored
View File

@@ -1,2 +0,0 @@
# do not track NVIDIA cache
/ComputeCache/

View File

@@ -1,45 +0,0 @@
{
"rules": [
{
"pattern": {
"feature": "true",
"matches": "java"
},
"profile": "games"
},
{
"pattern": {
"feature": "true",
"matches": "steam"
},
"profile": "games"
}
],
"profiles": [
{
"name": "games",
"settings": [
{
"key": "GLSyncToVblank",
"value": true
},
{
"key": "GLThreadedOptimizations",
"value": true
},
{
"key": "GLShaderDiskCache",
"value": true
},
{
"key": "GLGSYNCAllowed",
"value": true
},
{
"key": "GLAllowFXAAUsage",
"value": true
}
]
}
]
}

View File

@@ -1,45 +0,0 @@
{
"rules": [
{
"pattern": {
"feature": "true",
"matches": "Java"
},
"profile": "games"
},
{
"pattern": {
"feature": "true",
"matches": "steam"
},
"profile": "games"
}
],
"profiles": [
{
"name": "games",
"settings": [
{
"key": "GLSyncToVblank",
"value": true
},
{
"key": "GLThreadedOptimizations",
"value": true
},
{
"key": "GLShaderDiskCache",
"value": true
},
{
"key": "GLGSYNCAllowed",
"value": true
},
{
"key": "GLAllowFXAAUsage",
"value": true
}
]
}
]
}

View File

@@ -1,21 +0,0 @@
#
# /home/user/.nvidia-settings-rc
#
# Configuration file for nvidia-settings - the NVIDIA Settings utility
# Generated on Tue Apr 22 22:08:51 2025
#
# ConfigProperties:
RcFileLocale = C
DisplayStatusBar = Yes
SliderTextEntries = Yes
IncludeDisplayNameInConfigFile = No
UpdateRulesOnProfileNameChange = Yes
Timer = PowerMizer_Monitor_(GPU_0),Yes,1000
Timer = Thermal_Monitor_(GPU_0),Yes,1000
Timer = Memory_Used_(GPU_0),Yes,3000
# Attributes:
[GPU:0]/GPUPowerMizerMode=2