- commit
- c2bccdc
- parent
- 744252c
- author
- xxwhirlpool
- date
- 2025-09-21 12:26:12 -0400 EDT
bashrc fixes
4 files changed,
+497,
-205
+241,
-0
1@@ -0,0 +1,241 @@
2+# ~/.bashrc: executed by bash(1) for non-login shells.
3+# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
4+# for examples
5+
6+# If not running interactively, don't do anything
7+case $- in
8+ *i*) ;;
9+ *) return;;
10+esac
11+
12+# don't put duplicate lines or lines starting with space in the history.
13+# See bash(1) for more options
14+HISTCONTROL=ignoreboth
15+
16+# append to the history file, don't overwrite it
17+shopt -s histappend
18+
19+# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
20+HISTSIZE=1000
21+HISTFILESIZE=2000
22+
23+# check the window size after each command and, if necessary,
24+# update the values of LINES and COLUMNS.
25+shopt -s checkwinsize
26+
27+# If set, the pattern "**" used in a pathname expansion context will
28+# match all files and zero or more directories and subdirectories.
29+#shopt -s globstar
30+
31+# make less more friendly for non-text input files, see lesspipe(1)
32+[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
33+
34+# set variable identifying the chroot you work in (used in the prompt below)
35+if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then
36+ debian_chroot=$(cat /etc/debian_chroot)
37+fi
38+
39+# set a fancy prompt (non-color, unless we know we "want" color)
40+case "$TERM" in
41+ xterm-color|*-256color) color_prompt=yes;;
42+esac
43+
44+# uncomment for a colored prompt, if the terminal has the capability; turned
45+# off by default to not distract the user: the focus in a terminal window
46+# should be on the output of commands, not on the prompt
47+#force_color_prompt=yes
48+
49+if [ -n "$force_color_prompt" ]; then
50+ if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then
51+ # We have color support; assume it's compliant with Ecma-48
52+ # (ISO/IEC-6429). (Lack of such support is extremely rare, and such
53+ # a case would tend to support setf rather than setaf.)
54+ color_prompt=yes
55+ else
56+ color_prompt=
57+ fi
58+fi
59+
60+if [ "$color_prompt" = yes ]; then
61+ PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
62+else
63+ PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
64+fi
65+unset color_prompt force_color_prompt
66+
67+# If this is an xterm set the title to user@host:dir
68+case "$TERM" in
69+xterm*|rxvt*)
70+ PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"
71+ ;;
72+*)
73+ ;;
74+esac
75+
76+# enable color support of ls and also add handy aliases
77+if [ -x /usr/bin/dircolors ]; then
78+ test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
79+ alias ls='ls --color=auto'
80+ #alias dir='dir --color=auto'
81+ #alias vdir='vdir --color=auto'
82+
83+ alias grep='grep --color=auto'
84+ alias fgrep='fgrep --color=auto'
85+ alias egrep='egrep --color=auto'
86+fi
87+
88+# colored GCC warnings and errors
89+#export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'
90+
91+# some more ls aliases
92+alias ll='ls -alF'
93+alias la='ls -A'
94+alias l='ls -CF'
95+
96+# Add an "alert" alias for long running commands. Use like so:
97+# sleep 10; alert
98+alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')"'
99+
100+# Alias definitions.
101+# You may want to put all your additions into a separate file like
102+# ~/.bash_aliases, instead of adding them here directly.
103+# See /usr/share/doc/bash-doc/examples in the bash-doc package.
104+
105+if [ -f ~/.bash_aliases ]; then
106+ . ~/.bash_aliases
107+fi
108+
109+# enable programmable completion features (you don't need to enable
110+# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
111+# sources /etc/bash.bashrc).
112+if ! shopt -oq posix; then
113+ if [ -f /usr/share/bash-completion/bash_completion ]; then
114+ . /usr/share/bash-completion/bash_completion
115+ elif [ -f /etc/bash_completion ]; then
116+ . /etc/bash_completion
117+ fi
118+fi
119+
120+######################################
121+# aliases
122+######################################
123+
124+# general
125+
126+alias nano=micro
127+alias sudo="sudo "
128+alias pick="pastel pick"
129+alias icat="kitten icat"
130+alias freeze="freeze -c user $1"
131+alias fd="fdfind "
132+alias neofetch="hyfetch"
133+alias fastfetch="hyfetch"
134+
135+# lazy ass way for me to get my idol mp3s from youtube
136+# usage: ytmp3 url
137+alias ytmp3="yt-dlp -f ba -x --audio-format mp3"
138+
139+# some cd bookmarks
140+alias dotf="cd /home/kat/dotfiles"
141+alias gmine="cd /home/kat/Documents/Git/-mine"
142+
143+# weather stuff
144+alias wttr="curl https://wttr.in/New+York?F0AS"
145+alias weather=wttr
146+alias wttrlg="curl https://wttr.in/New+York?F1uq"
147+alias weatherlg=wttrlg
148+alias sun="daylight --short --timezone='America/New_York' | lolcat"
149+
150+# git
151+alias gitall="git remote | xargs -L1 git push --all"
152+alias gyolo="git add . && git commit -m 'yolo'"
153+alias pusheu="git push bytes main && cd /home/kat/Documents/Git/-mine/eunoia-astro/src/utils && node git-changelog.js"
154+
155+# vpn split tunnel aliases based on a small script @ ~/.local/bin/mvpn
156+alias mftp="mvpn filezilla"
157+alias mterm="mvpn kitty"
158+
159+# servers
160+alias fujo="kitty +kitten ssh fujo"
161+alias fujobuild="kitty +kitten ssh fujobuild"
162+alias fujohost="kitty +kitten ssh fujohost"
163+alias steff="kitty +kitten ssh steff"
164+
165+######################################
166+# variables
167+######################################
168+
169+export PATH=$PATH:/usr/local/go/bin
170+
171+export NVM_DIR="$HOME/.config/nvm"
172+[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
173+[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
174+
175+# set truecolor
176+export COLORTERM=truecolor
177+export MICRO_TRUECOLOR=1
178+
179+# catppuccin colors for fzf
180+export FZF_DEFAULT_OPTS=" \
181+--color=spinner:#F2D5CF,hl:#E78284 \
182+--color=fg:#C6D0F5,header:#E78284,info:#CA9EE6,pointer:#F2D5CF \
183+--color=marker:#BABBF1,fg+:#C6D0F5,prompt:#CA9EE6,hl+:#E78284 \
184+--color=border:#414559,label:#C6D0F5"
185+
186+if [ -f ~/.privatevars ]; then
187+ . ~/.privatevars
188+fi
189+
190+######################################
191+# functions
192+######################################
193+
194+# get a random free port. this is useful for my
195+# insane sysadmin website woman adventures
196+portfree() {
197+ while
198+ port=$(shuf -n 1 -i 49152-65535)
199+ netstat -atun | grep -q "$port"
200+ do
201+ continue
202+ done
203+ echo "$port"
204+}
205+
206+# print internal & external IPs
207+whatip() {
208+ # internal
209+ echo -n "internal IP: " | lolcat -p 0.7; hostname -I | awk '{print $1}'
210+ # external
211+ echo -n "external IP: " | lolcat -p 0.7; curl -4 icanhazip.com
212+}
213+
214+# password generator. takes input for password length by number
215+passgen() {
216+ PASSLENGTH=$(gum input --placeholder "type a number")
217+ date +%s | sha256sum | base64 | head -c $PASSLENGTH ; echo
218+}
219+
220+cdmess() {
221+ # from this blog post:
222+ # https://blog.larah.me/mess-directory/
223+ today_tmpdir="${TMPDIR-/tmp}/${USER}_mess/$(date +%F)"
224+ mkdir -p "$today_tmpdir"
225+ cd "$(mktemp -d -p "${today_tmpdir}" XXXX)"
226+}
227+
228+# to get quick notifs
229+# after long commands
230+notif() {
231+ notify-send "done!"
232+ aplay -q /usr/share/sounds/sound-icons/start
233+ spd-say -t female3 -r +25 "done!"
234+}
235+
236+######################################
237+# misc
238+######################################
239+
240+eval "$(starship init bash)"
241+
242+eval "$(fzf --bash)"
+256,
-0
1@@ -0,0 +1,256 @@
2+# ~/.bashrc: executed by bash(1) for non-login shells.
3+# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
4+# for examples
5+
6+# If not running interactively, don't do anything
7+case $- in
8+ *i*) ;;
9+ *) return;;
10+esac
11+
12+# don't put duplicate lines or lines starting with space in the history.
13+# See bash(1) for more options
14+HISTCONTROL=ignoreboth
15+
16+# append to the history file, don't overwrite it
17+shopt -s histappend
18+
19+# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
20+HISTSIZE=1000
21+HISTFILESIZE=2000
22+
23+# check the window size after each command and, if necessary,
24+# update the values of LINES and COLUMNS.
25+shopt -s checkwinsize
26+
27+# If set, the pattern "**" used in a pathname expansion context will
28+# match all files and zero or more directories and subdirectories.
29+#shopt -s globstar
30+
31+# make less more friendly for non-text input files, see lesspipe(1)
32+[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
33+
34+# set variable identifying the chroot you work in (used in the prompt below)
35+if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then
36+ debian_chroot=$(cat /etc/debian_chroot)
37+fi
38+
39+# set a fancy prompt (non-color, unless we know we "want" color)
40+case "$TERM" in
41+ xterm-color|*-256color) color_prompt=yes;;
42+esac
43+
44+# uncomment for a colored prompt, if the terminal has the capability; turned
45+# off by default to not distract the user: the focus in a terminal window
46+# should be on the output of commands, not on the prompt
47+#force_color_prompt=yes
48+
49+if [ -n "$force_color_prompt" ]; then
50+ if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then
51+ # We have color support; assume it's compliant with Ecma-48
52+ # (ISO/IEC-6429). (Lack of such support is extremely rare, and such
53+ # a case would tend to support setf rather than setaf.)
54+ color_prompt=yes
55+ else
56+ color_prompt=
57+ fi
58+fi
59+
60+if [ "$color_prompt" = yes ]; then
61+ PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
62+else
63+ PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
64+fi
65+unset color_prompt force_color_prompt
66+
67+# If this is an xterm set the title to user@host:dir
68+case "$TERM" in
69+xterm*|rxvt*)
70+ PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"
71+ ;;
72+*)
73+ ;;
74+esac
75+
76+# enable color support of ls and also add handy aliases
77+if [ -x /usr/bin/dircolors ]; then
78+ test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
79+ alias ls='ls --color=auto'
80+ #alias dir='dir --color=auto'
81+ #alias vdir='vdir --color=auto'
82+
83+ alias grep='grep --color=auto'
84+ alias fgrep='fgrep --color=auto'
85+ alias egrep='egrep --color=auto'
86+fi
87+
88+# colored GCC warnings and errors
89+#export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'
90+
91+# some more ls aliases
92+alias ll='ls -alF'
93+alias la='ls -A'
94+alias l='ls -CF'
95+
96+# Add an "alert" alias for long running commands. Use like so:
97+# sleep 10; alert
98+alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')"'
99+
100+# Alias definitions.
101+# You may want to put all your additions into a separate file like
102+# ~/.bash_aliases, instead of adding them here directly.
103+# See /usr/share/doc/bash-doc/examples in the bash-doc package.
104+
105+if [ -f ~/.bash_aliases ]; then
106+ . ~/.bash_aliases
107+fi
108+
109+# enable programmable completion features (you don't need to enable
110+# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
111+# sources /etc/bash.bashrc).
112+if ! shopt -oq posix; then
113+ if [ -f /usr/share/bash-completion/bash_completion ]; then
114+ . /usr/share/bash-completion/bash_completion
115+ elif [ -f /etc/bash_completion ]; then
116+ . /etc/bash_completion
117+ fi
118+fi
119+
120+######################################
121+# aliases
122+######################################
123+
124+# general
125+alias nano=micro
126+alias sudo="sudo TERMINFO=\"$TERMINFO\" "
127+alias pick='pastel pick'
128+alias fd='fdfind'
129+alias neofetch="hyfetch"
130+alias fastfetch="hyfetch"
131+alias bat="batcat"
132+alias cat="bat --paging=never"
133+alias iconsubfolalias iconsubfol="find . -mindepth 2 -type f -print -exec mv {} . \;"
134+
135+# lazy ass way for me to get my idol mp3s from youtube
136+# usage: ytmp3 url
137+alias ytmp3="yt-dlp -f ba -x --audio-format mp3"
138+
139+# weather stuff
140+alias wttr="curl https://wttr.in/New+York?F0AS"
141+alias weather=wttr
142+alias wttrlg="curl https://wttr.in/New+York?F1uq"
143+alias weatherlg=wttrlg
144+alias sun="daylight --short --timezone='America/New_York' | lolcat"
145+
146+# git
147+alias gitall="git remote | xargs -L1 git push --all"
148+alias gyolo="git add . && git commit -m 'yolo'"
149+alias pusheu="git push bytes main && cd /home/kat/Documents/Git/-mine/eunoia-astro/src/utils && node git-changelog.js"
150+
151+# vpn split tunnel aliases based on a small script @ ~/.local/bin/mvpn
152+alias mftp="mvpn filezilla"
153+alias mterm="mvpn kitty"
154+
155+# cd bookmarks
156+alias dotf="cd /home/kat/dotfiles"
157+alias gmine="cd /home/kat/Documents/Git/-mine"
158+
159+# servers
160+alias fujo="kitty +kitten ssh fujo"
161+alias fujohost="kitty +kitten ssh fujohost"
162+alias fujobuild="kitty +kitten ssh fujobuild"
163+alias steff="kitty +kitten ssh steff"
164+
165+######################################
166+# variables
167+######################################
168+
169+export EDITOR=/usr/local/bin/micro
170+export "MICRO_TRUECOLOR=1"
171+
172+# catppuccin colors for fzf
173+export FZF_DEFAULT_OPTS=" \
174+--color=spinner:#F2D5CF,hl:#E78284 \
175+--color=fg:#C6D0F5,header:#E78284,info:#CA9EE6,pointer:#F2D5CF \
176+--color=marker:#BABBF1,fg+:#C6D0F5,prompt:#CA9EE6,hl+:#E78284 \
177+--color=border:#414559,label:#C6D0F5"
178+
179+# Created by `pipx` on 2025-08-05 03:36:48
180+export PATH="$PATH:/home/kat/dotfiles/config/.local/bin"
181+export PATH=$PATH:/usr/local/go/bin
182+
183+if [ -f ~/.privatevars ]; then
184+ . ~/.privatevars
185+fi
186+
187+export NVM_DIR="$HOME/.config/nvm"
188+[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
189+[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
190+
191+. "$HOME/.cargo/env"
192+
193+######################################
194+# functions
195+######################################
196+
197+cdmess() {
198+ # from this blog post:
199+ # https://blog.larah.me/mess-directory/
200+ today_tmpdir="${TMPDIR-/tmp}/${USER}_mess/$(date +%F)"
201+ mkdir -p "$today_tmpdir"
202+ cd "$(mktemp -d -p "${today_tmpdir}" XXXX)"
203+}
204+
205+# get a random free port. this is useful for my
206+# insane sysadmin website woman adventures
207+portfree() {
208+ while
209+ port=$(shuf -n 1 -i 49152-65535)
210+ netstat -atun | grep -q "$port"
211+ do
212+ continue
213+ done
214+ echo "$port"
215+}
216+
217+# print internal & external IPs
218+whatip() {
219+ # internal
220+ echo -n "internal IP: " | lolcat -p 0.7; hostname -I | awk '{print $1}'
221+ # external
222+ echo -n "external IP: " | lolcat -p 0.7; curl -4 icanhazip.com
223+}
224+
225+# password generator. takes input for password length by number
226+passgen() {
227+ PASSLENGTH=$(gum input --placeholder "type a number")
228+ date +%s | sha256sum | base64 | head -c $PASSLENGTH ; echo
229+}
230+
231+# display random ASCII art from
232+# custom dir of art in dotfiles
233+# using arttime (github: poetaman/arttime)
234+playart() {
235+ ARTDIR="/home/kat/Documents/Code/Git/-mine/dotfiles/config/.local/share/arttime/textart"
236+ ARTSHUF=$(find "$ARTDIR" -type f | shuf -n1)
237+
238+ for art in "$ARTSHUF"; do
239+ arttime --nolearn -a ${art} --ac 5
240+ done
241+}
242+
243+# to get quick notifs
244+# after long commands
245+notif() {
246+ notify-send "done!"
247+ aplay -q /usr/share/sounds/sound-icons/start
248+ spd-say -t female3 -r +25 "done!"
249+}
250+
251+######################################
252+# misc
253+######################################
254+
255+eval "$(starship init bash)"
256+eval "$(fzf --bash)"
257+eval "$(batman --export-env)"
+0,
-88
1@@ -1,88 +0,0 @@
2-#!/bin/bash
3-
4-# from my laptop
5-
6-alias nano=micro
7-alias sudo="sudo "
8-alias pick="pastel pick"
9-alias gitall="git remote | xargs -L1 git push --all"
10-
11-alias fd="fdfind "
12-
13-alias neofetch="hyfetch"
14-alias fastfetch="hyfetch"
15-
16-cdmess() {
17- # from this blog post:
18- #
19- # https://blog.larah.me/mess-directory/
20- #
21- today_tmpdir="${TMPDIR-/tmp}/${USER}_mess/$(date +%F)"
22- mkdir -p "$today_tmpdir"
23- cd "$(mktemp -d -p "${today_tmpdir}" XXXX)"
24-}
25-
26-# don't log commands that start with a space
27-export HISTCONTROL=ignorespace
28-
29-# catppuccin colors for fzf
30-export FZF_DEFAULT_OPTS=" \
31---color=spinner:#F2D5CF,hl:#E78284 \
32---color=fg:#C6D0F5,header:#E78284,info:#CA9EE6,pointer:#F2D5CF \
33---color=marker:#BABBF1,fg+:#C6D0F5,prompt:#CA9EE6,hl+:#E78284 \
34---color=border:#414559,label:#C6D0F5"
35-
36-# lazy ass way for me to get my idol mp3s from youtube
37-# usage: ytmp3 url
38-alias ytmp3="yt-dlp -f ba -x --audio-format mp3"
39-
40-# some cd bookmarks
41-alias dotf="cd /home/kat/dotfiles"
42-alias gmine="cd /home/kat/Documents/Git/-mine"
43-
44-# weather stuff
45-alias wttr="curl https://wttr.in/New+York?F0AS"
46-alias weather=wttr
47-
48-alias wttrlg="curl https://wttr.in/New+York?F1uq"
49-alias weatherlg=wttrlg
50-
51-alias sun="daylight --short --timezone='America/New_York' | lolcat"
52-
53-# print internal & external IPs
54-whatip() {
55- # internal
56- echo -n "internal IP: " | lolcat -p 0.7; hostname -I | awk '{print $1}'
57- # external
58- echo -n "external IP: " | lolcat -p 0.7; curl -4 icanhazip.com
59-}
60-
61-# password generator. takes input for password length by number
62-passgen() {
63- PASSLENGTH=$(gum input --placeholder "type a number")
64- date +%s | sha256sum | base64 | head -c $PASSLENGTH ; echo
65-}
66-
67-# used to be a ~/.local/bin entry but that was dumb
68-alias pusheu="git push bytes main && cd /home/kat/Documents/Git/-mine/eunoia-astro/src/utils && node git-changelog.js"
69-
70-# vpn split tunnel aliases based on a small script @ ~/.local/bin/mvpn
71-alias mftp="mvpn filezilla"
72-alias mterm="mvpn kitty"
73-
74-# quickly look up a program on cheat.sh
75-cheatsh() {
76- curl "cheat.sh/$1"
77-}
78-
79-# to get quick notifs
80-# after long commands
81-notif() {
82- notify-send "done!"
83- aplay -q /usr/share/sounds/sound-icons/start
84- spd-say -t female3 -r +25 "done!"
85-}
86-
87-alias icat="kitten icat"
88-
89-alias gyolo="git add . && git commit -m 'yolo'"
+0,
-117
1@@ -1,117 +0,0 @@
2-#!/bin/bash
3-#
4-# from my pc
5-
6-eval "$(starship init bash)"
7-
8-export PATH=$PATH:/usr/local/go/bin
9-
10-export NVM_DIR="$HOME/.config/nvm"
11-[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
12-[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
13-
14-alias nano=micro
15-alias sudo="sudo TERMINFO=\"$TERMINFO\" "
16-alias pick='pastel pick'
17-alias fd='fdfind'
18-alias neofetch="hyfetch"
19-alias fastfetch="hyfetch"
20-alias gitall="git remote | xargs -L1 git push --all"
21-
22-# lazy ass way for me to get my idol mp3s from youtube
23-# usage: ytmp3 url
24-alias ytmp3="yt-dlp -f ba -x --audio-format mp3"
25-
26-# weather stuff
27-alias wttr="curl https://wttr.in/New+York?F0AS"
28-alias weather=wttr
29-
30-alias wttrlg="curl https://wttr.in/New+York?F1uq"
31-alias weatherlg=wttrlg
32-
33-alias sun="daylight --short --timezone='America/New_York' | lolcat"
34-
35-# vpn split tunnel aliases based on a small script @ ~/.local/bin/mvpn
36-alias mftp="mvpn filezilla"
37-alias mterm="mvpn kitty"
38-
39-export EDITOR=/usr/bin/micro
40-export "MICRO_TRUECOLOR=1"
41-
42-# catppuccin colors for fzf
43-export FZF_DEFAULT_OPTS=" \
44---color=spinner:#F2D5CF,hl:#E78284 \
45---color=fg:#C6D0F5,header:#E78284,info:#CA9EE6,pointer:#F2D5CF \
46---color=marker:#BABBF1,fg+:#C6D0F5,prompt:#CA9EE6,hl+:#E78284 \
47---color=border:#414559,label:#C6D0F5"
48-
49-cdmess() {
50- # from this blog post:
51- # https://blog.larah.me/mess-directory/
52- today_tmpdir="${TMPDIR-/tmp}/${USER}_mess/$(date +%F)"
53- mkdir -p "$today_tmpdir"
54- cd "$(mktemp -d -p "${today_tmpdir}" XXXX)"
55-}
56-
57-# get a random free port. this is useful for my
58-# insane sysadmin website woman adventures
59-portfree() {
60- while
61- port=$(shuf -n 1 -i 49152-65535)
62- netstat -atun | grep -q "$port"
63- do
64- continue
65- done
66- echo "$port"
67-}
68-
69-# print internal & external IPs
70-whatip() {
71- # internal
72- echo -n "internal IP: " | lolcat -p 0.7; hostname -I | awk '{print $1}'
73- # external
74- echo -n "external IP: " | lolcat -p 0.7; curl -4 icanhazip.com
75-}
76-
77-# password generator. takes input for password length by number
78-passgen() {
79- PASSLENGTH=$(gum input --placeholder "type a number")
80- date +%s | sha256sum | base64 | head -c $PASSLENGTH ; echo
81-}
82-
83-# cd bookmarks
84-alias dotf="cd /home/kat/dotfiles"
85-alias gmine="cd /home/kat/Documents/Git/-mine"
86-
87-alias pusheu="git push bytes main && cd /home/kat/Documents/Git/-mine/eunoia-astro/src/utils && node git-changelog.js"
88-
89-alias iconsubfol="find . -mindepth 2 -type f -print -exec mv {} . \;"
90-
91-# quickly look up a program on cheat.sh
92-cheat() {
93- curl cheat.sh/"$1"
94-}
95-
96-# display random ASCII art from
97-# custom dir of art in dotfiles
98-# using arttime (github: poetaman/arttime)
99-playart() {
100- ARTDIR="/home/kat/Documents/Code/Git/-mine/dotfiles/config/.local/share/arttime/textart"
101- ARTSHUF=$(find "$ARTDIR" -type f | shuf -n1)
102-
103- for art in "$ARTSHUF"; do
104- arttime --nolearn -a ${art} --ac 5
105- done
106-}
107-
108-# to get quick notifs
109-# after long commands
110-notif() {
111- notify-send "done!"
112- aplay -q /usr/share/sounds/sound-icons/start
113- spd-say -t female3 -r +25 "done!"
114-}
115-
116-alias icat="kitten icat"
117-
118-alias gyolo="git add . && git commit -m 'yolo'"