added a few helper scripts for npp/kate execution, and typical aliases

This commit is contained in:
Luke 2023-11-24 12:14:53 -08:00
parent 7063fc3930
commit 490849144c
4 changed files with 47 additions and 5 deletions

View file

@ -1 +0,0 @@
alias ls="ls -I 'NTUSER.DAT*' --color=auto"

View file

@ -0,0 +1,7 @@
#!/bin/bash
alias _wrapping_fix='kill -WINCH $$'
alias grep='grep --color=auto'
alias pip='python -m pip'
alias diff='diff --strip-trailing-cr'
alias ls="ls -I 'NTUSER.DAT*' --color=auto"

View file

@ -1,5 +1,33 @@
#!/bin/bash
# TODO
function npp() {
}
function qff() {
printf "searching for files named '*"$*"*'\n" >&2
find -type f -iname '*'$*'*'
}
function rv() {
RV=$?
if [[ $RV -eq 0 ]]; then
COLOR='2'
elif [[ $RV -eq 1 ]]; then
COLOR='3'
else
COLOR='1'
fi
printf '\e[4%dm' $COLOR
printf ' RV=%d \e[0m\n' $RV >&2
}
# When notepad++ is available, use it
function kate() {
export IFS=$'\n'
NOTEPADPP_EXE='/c/Program Files/Notepad++/notepad++.exe'
if [[ -e "${NOTEPADPP_EXE}" ]]; then
echo 'notepad++.exe '$*' &'
"${NOTEPADPP_EXE}" $* &
return 0
else
echo "notepad++ not found."
return 1
fi
}

8
templates/misc.bashrc.sh Normal file
View file

@ -0,0 +1,8 @@
#!/bin/bash
# prevent git from paging
export LESS='-rFX'
export HISTIGNORE='pwd:exit:fg:bg:top:clear:history:ls:uptime:df'