Verified Commit 37ce1589 authored by Hermann Mayer's avatar Hermann Mayer
Browse files

BashRC: Updated the prompt and some default configurations.

parent 338f582a
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -55,4 +55,4 @@ export PRINT_HEADER=0

# Print prompt with directory information, eg amount of files and size
# Values: 0 | 1
export DIRECTORY_INFO_PROMPT=1
export DIRECTORY_INFO_PROMPT=0
+5 −1
Original line number Diff line number Diff line
@@ -3,6 +3,9 @@
    email = hermann.mayer92@gmail.com
    signingkey = 0x388D16A5B4C1CF12

[commit]
    gpgSign = true

[color]
    diff   = auto
    status = auto
@@ -10,6 +13,7 @@

[format]
    pretty = "%nCommit:  %C(bold white)%H%nRefs:   %C(cyan bold)%d%nDate:    (%C(red)%ar%Creset) %ai%nAuthor:  %C(yellow)%aN <%aE>%nSubject: %C(green)%B"
    signOff = true

[log]
    decorate = full
@@ -27,7 +31,7 @@

[alias]
    st = status
    ci = commit
    ci = commit -S -s
    br = branch
    co = checkout
    df = diff
+1 −1
Original line number Diff line number Diff line
@@ -142,4 +142,4 @@ done
# +-------------------------------------------------

# Rebind enter key to insert newline before command output
trap 'echo' DEBUG
trap 'echo -e "\e[0m"' DEBUG
+7 −4
Original line number Diff line number Diff line
@@ -36,9 +36,12 @@ if ${use_color} ; then
        RET_OUT="\n$RET_OUT"

        if [ "$DIRECTORY_INFO_PROMPT" -eq 0 ]; then
            PSL1A=' \[\e[0;31m\][\[\e[1;37m\]\[\e[0;36m\]\w\[\e[0;31m\]]\[\e[0;32m\]\033]2;\w\007'
            PSL1=${RET_OUT}${PSL1A}
            PSL2='\n\[\e[0;31m\][\u\[\e[0;33m\]@\[\e[0;37m\]\h\[\e[0;31m\]] \[\e[0;31m\]$\[\e[0;32m\] '
            _TIME='\t'
            _META="${_TIME} | \[\e[0;36m\]\w"
            META=" \[\e[0;31m\][ \[\e[1;37m\]${_META}\[\e[0;31m\] ]\[\e[0;32m\]\033]2;\w\007"

            PSL1=${RET_OUT}${META}
            PSL2="\n\[\e[0;31m\][\u\[\e[0;33m\]@\[\e[0;37m\]\h\[\e[0;31m\]] \[\e[0;31m\]$\[\e[0;32m\] "
        else
            _TIME='\t'
            _FILES="\$(ls -a1 | grep -vE '\.$' | wc -l)"