mirror of
https://github.com/kevinnlsamuel/bak-old.git
synced 2025-12-06 10:05:58 +05:30
set up for debugging/dev
- rearranged comments around debug brace expansion so it doesn't look bad when printed due to the `-v` flag
This commit is contained in:
@@ -15,7 +15,6 @@ set -e
|
|||||||
#####################
|
#####################
|
||||||
|
|
||||||
debug(){ ### function to call when $DEBUG is set
|
debug(){ ### function to call when $DEBUG is set
|
||||||
|
|
||||||
set -xv
|
set -xv
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -175,9 +174,9 @@ parse_combined(){
|
|||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
### enable debugging ###
|
### enable debugging if ###
|
||||||
${DEBUG+debug} ###
|
${DEBUG+debug} ###
|
||||||
### if $DEBUG is set ###
|
### $DEBUG is set ###
|
||||||
|
|
||||||
###############################################################################
|
###############################################################################
|
||||||
# SANITISING PARAMS AND OPTIONS
|
# SANITISING PARAMS AND OPTIONS
|
||||||
|
|||||||
23
install.sh
Normal file → Executable file
23
install.sh
Normal file → Executable file
@@ -5,4 +5,25 @@
|
|||||||
# authored by github.com/kevinnls #
|
# authored by github.com/kevinnls #
|
||||||
# - another Linux user tired of #
|
# - another Linux user tired of #
|
||||||
# type cp file file.bak #
|
# type cp file file.bak #
|
||||||
###################################
|
###################################
|
||||||
|
|
||||||
|
work_dir=/tmp/bak-old_installation/
|
||||||
|
|
||||||
|
debug(){ ### function to call when $DEBUG is set
|
||||||
|
set -xv
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
### enable debugging if ###
|
||||||
|
${DEBUG+debug} ###
|
||||||
|
### $DEBUG is set ###
|
||||||
|
|
||||||
|
# create dir for installation work
|
||||||
|
|
||||||
|
mkdir -p $work_dir
|
||||||
|
cd $work_dir
|
||||||
|
|
||||||
|
# cleanup
|
||||||
|
|
||||||
|
cd $HOME
|
||||||
|
rm -rf $work_dir
|
||||||
Reference in New Issue
Block a user