Browse Source

functions add prefix "heck_" as namespacing

master
heck 8 months ago
parent
commit
eb0d436712
  1. 2
      bash_profile.d/00_base.sh
  2. 10
      bash_profile.d/convenience.sh

2
bash_profile.d/00_base.sh

@ -51,4 +51,4 @@ alias md='m develop'
# grep # grep
alias grep='grep --color=auto' alias grep='grep --color=auto'
alias toolchain_info='make -f ~/HeckBashSetup/scripts/ToolchainInfo' alias heck_toolchain_info='make -f ~/HeckBashSetup/scripts/ToolchainInfo'

10
bash_profile.d/convenience.sh

@ -1,19 +1,15 @@
#!/bin/bash #!/bin/bash
rmclassesrecursively() { function heck_rm_o_and_d_files_recurse() {
rm -vf $(find . | grep -E '\.class$')
}
rmdotoanddotdrecursively() {
rm -v $(find . | grep -E '\.o$|\.d$') rm -v $(find . | grep -E '\.o$|\.d$')
} }
function realpath() { function heck_realpath() {
python3 -c 'import sys, os; print(os.path.realpath(sys.argv[1]))' $1 python3 -c 'import sys, os; print(os.path.realpath(sys.argv[1]))' $1
} }
# Print filenames matching grep $1 # Print filenames matching grep $1
function fmatch() { function heck_fmatch() {
grep -ri $1 * | perl -pe 's/\:.*?\n/\n/g' | sort -u grep -ri $1 * | perl -pe 's/\:.*?\n/\n/g' | sort -u
} }

Loading…
Cancel
Save