Minor adjustment in solarize scheme and helper functions.
This commit is contained in:
parent
a975c68b11
commit
f5e0ae3e43
@ -12,5 +12,5 @@ else
|
||||
echo -e "$SSH_AUTH_SOCK"
|
||||
export SSH_AUTH_SOCK
|
||||
ssh-add ~/.ssh/daimler_rsa
|
||||
ssh-add ~/.ssh/id_materna
|
||||
ssh-add ~/.ssh/materna-ecdsa
|
||||
fi
|
||||
|
||||
@ -4,6 +4,10 @@
|
||||
# Inspired by https://cheat.sh/openssl
|
||||
#
|
||||
|
||||
# Alternativen aus https://www.feistyduck.com/library/openssl-cookbook/online/ch-testing-with-openssl.html
|
||||
# echo | openssl s_client -connect www.gaiselmann.de:443 2>&1 | openssl x509 -noout -text -fingerprint -sha256
|
||||
# echo | openssl s_client -connect www.gaiselmann.de:443 2>&1 | sed --quiet '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p'
|
||||
#
|
||||
function show-cert() {
|
||||
local host=$1
|
||||
local port=${2:-443}
|
||||
|
||||
@ -50,6 +50,18 @@ alias findAgent='find-agent.sh'
|
||||
# ip
|
||||
alias ips='ip --brief -c address'
|
||||
|
||||
alias sol-light='set-scheme.sh solarized.light'
|
||||
alias sol-dark='set-scheme.sh solarized.dark'
|
||||
|
||||
# if tldr++ is installed, use it the static way
|
||||
if tldr --version &> /dev/null
|
||||
then
|
||||
tldrVersion="$(tldr --version 2>&1)"
|
||||
if [[ $tldrVersion =~ tldr\+\+.* ]]; then
|
||||
alias tldr='tldr --static'
|
||||
fi
|
||||
fi
|
||||
|
||||
{{ if eq .bash.prompt.category "Uberspace" -}}
|
||||
alias quota='quota -gls'
|
||||
{{ end -}}
|
||||
|
||||
@ -104,4 +104,13 @@ enqueueFiles() {
|
||||
done
|
||||
}
|
||||
|
||||
# List SSH keys
|
||||
# See https://prefetch.net/blog/index.php/2010/12/13/locating-the-ssh-key-type-and-key-size-from-a-public-key-file/
|
||||
list-ssh-keys() {
|
||||
for f in ~/.ssh/*.pub
|
||||
do
|
||||
printf "%-50s -> $(ssh-keygen -l -f $f)\n" $f
|
||||
done
|
||||
}
|
||||
|
||||
PATH=$PATH:$HOME/bin
|
||||
|
||||
@ -52,7 +52,7 @@ function statusPrompt() {
|
||||
echo "\[$(colf "$PROMPT_COLOR")\] \$(lastExitCode)\[$(colf "$PROMPT_COLOR")\] $type \[$(res)\]\[$(colf 7)\]▓▒░"
|
||||
}
|
||||
function userPrompt() {
|
||||
echo "\[$(res)\]\[$(colf 2)\]\u@\h \[$(colf 1)\]☆ \[$(colf 2)\]\w \[$(colf 1)\]☆ \[$(colf "$PROMPT_COLOR")\]\$(parse_git_branch) "
|
||||
echo "\[$(res)\]\[$(colf 2)\]\u@\h \[$(colf 1)\]☆ \[$(colf 2)\]\w \[$(colf 1)\]☆ \[$(colf 4)\]\$(parse_git_branch) "
|
||||
}
|
||||
function datePrompt() {
|
||||
echo "\[$(colf 2)\]\D{%Y-%m-%d %H:%M:%S}"
|
||||
|
||||
@ -19,3 +19,24 @@ echo -ne '\eP\e]4;6;#2AA198\a' # cyan -> cyan
|
||||
echo -ne '\eP\e]4;14;#93A1A1\a' # bold cyan -> base1 *
|
||||
echo -ne '\eP\e]4;7;#EEE8D5\a' # white -> Base2
|
||||
echo -ne '\eP\e]4;15;#FDF6E3\a' # bold white -> Base3
|
||||
|
||||
# Test, overwrite bold colors (from mintty)
|
||||
echo -ne '\e]4;8;#404040\a' # bold black (i.e. dark grey)
|
||||
echo -ne '\e]4;9;#FF4040\a' # bold red
|
||||
echo -ne '\e]4;10;#40FF40\a' # bold green
|
||||
echo -ne '\e]4;11;#FFFF40\a' # bold yellow
|
||||
echo -ne '\e]4;12;#6060FF\a' # bold blue
|
||||
echo -ne '\e]4;13;#FF40FF\a' # bold magenta
|
||||
echo -ne '\e]4;14;#40FFFF\a' # bold cyan
|
||||
echo -ne '\e]4;15;#FFFFFF\a' # bold white
|
||||
|
||||
# Test II, use same color for bold, mintty should show bold
|
||||
echo -ne '\e]4;8;#073642\a' # bold black (i.e. dark grey)
|
||||
echo -ne '\e]4;9;#DC322F\a' # bold red
|
||||
echo -ne '\e]4;10;#859900\a' # bold green
|
||||
echo -ne '\e]4;11;#B58900\a' # bold yellow
|
||||
echo -ne '\e]4;12;#268BD2\a' # bold blue
|
||||
echo -ne '\e]4;13;#D33682\a' # bold magenta
|
||||
echo -ne '\e]4;14;#2AA198\a' # bold cyan
|
||||
echo -ne '\e]4;15;#EEE8D5\a' # bold white
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user