tried to get command logging working, but differences in docker and normal environment makes it behave differently. Unsure what the deal is right now.

This commit is contained in:
sog
2020-04-18 11:08:29 -04:00
parent ffe6f44e15
commit bb30b82b72
3 changed files with 7 additions and 8 deletions

View File

@@ -1,8 +1,7 @@
[ -z "$PS1" ] && return
HISTCONTROL=ignoredups:ignorespace
shopt -s histappend
HISTSIZE=5000
HISTFILESIZE=5000
export HISTCONTROL=ignoredups:ignorespace
export HISTSIZE=5000
export HISTFILESIZE=5000
if [ -x /usr/bin/dircolors ]; then
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
alias ls='ls --color=auto'
@@ -24,7 +23,7 @@ ps1_state(){
echo -e "[$(date +%H:%M:%S)]\xF0\x9F\x94\xB4->$ret "
fi
}
PS1='${debian_chroot:+($debian_chroot)}$(ps1_state)\[\033[01;31m\]\u\[\033[00m\][ \[\033[01;34m\]\w\[\033[00m\] ]\$ '
export PS1='${debian_chroot:+($debian_chroot)}$(ps1_state)\[\033[01;31m\]\u\[\033[00m\][ \[\033[01;34m\]\w\[\033[00m\] ]\$ '
# From https://twitter.com/n00py1/status/1230755337797394434
script -f /logs/$(date +"%d-%b-%y_%H-%M-%S")_shell.log