X-Git-Url: https://fleuret.org/cgi-bin/gitweb/gitweb.cgi?a=blobdiff_plain;f=bashrc;h=adef3169a48757c62ea7c79b45c019893b115d4b;hb=1f8ae8cc1c0b654adb99d40e2ad7e40414074732;hp=4e736e6fa0deafc8ce03af2246c89c183bbbbc13;hpb=39fd98a7b4ac3146d11f866ab41ca413fb280414;p=scripts.git diff --git a/bashrc b/bashrc index 4e736e6..adef316 100644 --- a/bashrc +++ b/bashrc @@ -54,6 +54,8 @@ shopt -s histappend setterm -blength 0 +# || setterm --blength 0 # Seriously? + ###################################################################### ## The interactive part @@ -367,7 +369,7 @@ function pho () { function dt () { echo "Local: $(date)" if [[ ${TZ} ]]; then - unset TZ + local TZ=$(cat /etc/timezone) echo "Home: $(date)" fi } @@ -543,12 +545,12 @@ function keep () { # I sometime burn CDs and DVDs function burn () { - DEVICE="/dev/cdrw1" + [[ "${DEV_BURNER}" ]] || DEV_BURNER="/dev/sr0" if [[ ! "$1" ]]; then echo "burn " >&2 elif [[ -f "$1" ]]; then if [[ $(file "$1" | \grep -E 'ISO 9660|UDF filesystem data') ]]; then - wodim -eject -v dev=${DEVICE} "$1" + wodim -eject -v dev=${DEV_BURNER} "$1" else echo "Do not know what to do with $1" >&2 fi @@ -557,7 +559,7 @@ function burn () { echo "Using ${TMP_ROOT} as temporary directory." TMP=$(mktemp ${TMP_ROOT}/cdimage.XXXXXX) && \ genisoimage -input-charset iso8859-1 -r -o ${TMP} "$1" && \ - wodim -eject -v dev=${DEVICE} ${TMP} + wodim -eject -v dev=${DEV_BURNER} ${TMP} rm -f ${TMP} else echo "Can not find $1" >&2 @@ -790,6 +792,8 @@ alias finddup='finddup -p' # # git clone http://fleuret.org/git/selector/ +export SELECTOR_CD_HISTORY_SIZE=10000 + source bash-selector.sh --hist --cd ###################################################################### @@ -882,7 +886,7 @@ PROMPT_COMMAND="prompt_command" # Displaying the timezone if it is set if [[ ${TZ} ]]; then - echo "${VT_BOLD}${VT_GREEN_FG}Time zone is ${TZ}.${VT_RESET}" + echo "${VT_BOLD}${VT_BLUE_FG}Time zone is ${TZ}.${VT_RESET}" fi ######################################################################