mirror of
https://gitlab.com/dabruh/dotfiles.git
synced 2024-12-27 12:28:11 +01:00
Compare commits
No commits in common. "00fe271f3494005930a557adfb596e0a11782fb8" and "b27eda32648b0f65984c9e390c9afb2d100ca7e8" have entirely different histories.
00fe271f34
...
b27eda3264
7 changed files with 45 additions and 62 deletions
|
@ -1,28 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
# shellcheck disable=SC2139
|
|
||||||
# Verbosity and settings that you pretty much just always are going to want.
|
|
||||||
alias \
|
|
||||||
bc="bc -ql" \
|
|
||||||
cp="cp -iv" \
|
|
||||||
df='df -h' \
|
|
||||||
e="${EDITOR:-vim}" \
|
|
||||||
ffmpeg="ffmpeg -hide_banner" \
|
|
||||||
free='free -m' \
|
|
||||||
g="git" \
|
|
||||||
ka="killall" \
|
|
||||||
mkd="mkdir -pv" \
|
|
||||||
mv="mv -iv" \
|
|
||||||
rm="rm -vI" \
|
|
||||||
shrd="shred -zuvn3" \
|
|
||||||
tmux='tmux -f ~/.config/tmux/tmux.conf'
|
|
||||||
|
|
||||||
# Misc
|
|
||||||
alias \
|
|
||||||
w='curl https://wttr.in/'
|
|
||||||
|
|
||||||
which codium >/dev/null && alias code=codium c=codium
|
|
||||||
which pacman >/dev/null && alias p=pacman
|
|
||||||
which zathura >/dev/null && alias z=zathura
|
|
||||||
which ranger >/dev/null && alias r=ranger
|
|
||||||
[ -s "$NVM_DIR/nvm.sh" ] && alias load-nvm="source '$NVM_DIR/nvm.sh'"
|
|
|
@ -1,9 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
# Kubernetes things
|
|
||||||
alias \
|
|
||||||
cx="kubectl-ctx" \
|
|
||||||
f='flux' \
|
|
||||||
h='helm' \
|
|
||||||
k='kubectl' \
|
|
||||||
v='velero'
|
|
|
@ -1,7 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
# Verbosity and settings that you pretty much just always are going to want.
|
|
||||||
alias \
|
|
||||||
yt="yt-dlp --embed-metadata -i" \
|
|
||||||
yta="yt -x -f bestaudio/best -o '%(uploader)s - %(title)s [%(id)s].%(ext)s'" \
|
|
||||||
ytmp3="yta --audio-format mp3 --audio-quality 192K"
|
|
41
.config/shell/aliasrc
Normal file
41
.config/shell/aliasrc
Normal file
|
@ -0,0 +1,41 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Verbosity and settings that you pretty much just always are going to want.
|
||||||
|
alias \
|
||||||
|
bc="bc -ql" \
|
||||||
|
cp="cp -iv" \
|
||||||
|
ffmpeg="ffmpeg -hide_banner" \
|
||||||
|
mkd="mkdir -pv" \
|
||||||
|
mv="mv -iv" \
|
||||||
|
rm="rm -vI" \
|
||||||
|
shrd="shred -zuvn3" \
|
||||||
|
yt="yt-dlp --embed-metadata -i" \
|
||||||
|
yta="yt -x -f bestaudio/best -o '%(uploader)s - %(title)s [%(id)s].%(ext)s'" \
|
||||||
|
ytmp3="yta --audio-format mp3 --audio-quality 192K"
|
||||||
|
|
||||||
|
# Kubernetes things
|
||||||
|
alias \
|
||||||
|
cx="kubectl-ctx" \
|
||||||
|
f='flux' \
|
||||||
|
h='helm' \
|
||||||
|
k='kubectl' \
|
||||||
|
v='velero'
|
||||||
|
|
||||||
|
# These common commands are just too long! Abbreviate them.
|
||||||
|
alias \
|
||||||
|
ka="killall" \
|
||||||
|
g="git" \
|
||||||
|
e="${EDITOR:-vim}" \
|
||||||
|
p="pacman" \
|
||||||
|
z="zathura"
|
||||||
|
|
||||||
|
# Misc
|
||||||
|
alias \
|
||||||
|
tmux='tmux -f ~/.config/tmux/tmux.conf' \
|
||||||
|
df='df -h' \
|
||||||
|
free='free -m' \
|
||||||
|
r='ranger' \
|
||||||
|
w='curl https://wttr.in/'
|
||||||
|
|
||||||
|
which codium >/dev/null && alias code=codium
|
||||||
|
[ -s "$NVM_DIR/nvm.sh" ] && alias load-nvm="source '$NVM_DIR/nvm.sh'"
|
|
@ -147,7 +147,4 @@ bindkey '^[[B' history-substring-search-down
|
||||||
|
|
||||||
RPROMPT='$(git_prompt_string)'
|
RPROMPT='$(git_prompt_string)'
|
||||||
[ -f "$ZDOTDIR/completion" ] && . "$ZDOTDIR/completion" # Additional ZSH completion
|
[ -f "$ZDOTDIR/completion" ] && . "$ZDOTDIR/completion" # Additional ZSH completion
|
||||||
|
[ -f "${XDG_CONFIG_HOME:-$HOME/.config}/shell/aliasrc" ] && . "${XDG_CONFIG_HOME:-$HOME/.config}/shell/aliasrc"
|
||||||
find "${XDG_CONFIG_HOME:-$HOME/.config}/shell/aliases" -type f | while read -r alias_file; do
|
|
||||||
source "$alias_file"
|
|
||||||
done
|
|
||||||
|
|
|
@ -17,8 +17,5 @@ autocorrect = 40
|
||||||
[core]
|
[core]
|
||||||
editor = vim
|
editor = vim
|
||||||
|
|
||||||
[gitreview]
|
|
||||||
remote = origin
|
|
||||||
|
|
||||||
[include]
|
[include]
|
||||||
path = ~/.config/git/.gitconfig
|
path = ~/.config/git/.gitconfig
|
||||||
|
|
14
.local/bin/t
14
.local/bin/t
|
@ -1,14 +1,6 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
# TITLE : t
|
|
||||||
# DESCRIPTION : Creates and re-opens tmux sessions
|
|
||||||
# AUTHOR : edabrows
|
|
||||||
# DATE : 20230828
|
|
||||||
# VERSION : 0.1.0
|
|
||||||
# USAGE : t <session-name>
|
|
||||||
# BASH_VERSION : 5.1.16(1)-release
|
|
||||||
|
|
||||||
EXISTS=false
|
EXISTS=false
|
||||||
tmux ls | cut -d: -f1 | grep -q "^${1:?}$" && EXISTS=true # Get open sessions
|
tmux ls | cut -d: -f1 | grep -q "^${1:?}$" && EXISTS=true
|
||||||
$EXISTS && tmux a -t "$1" # Attatch to existing session
|
$EXISTS && tmux a -t "$1"
|
||||||
$EXISTS || tmux new -s "$1" # Create a new session
|
$EXISTS || tmux new -s "$1"
|
||||||
|
|
Loading…
Reference in a new issue