Bug in !! expansion, bash 4.4-beta

2015-10-25 Thread Keith Thompson
I'm running bash 4.4 beta, built from source (bash-4.4-beta.tar.gz) on Linux Mint 17.2. !! history expansion works correctly in simple cases, but not when part of a $(...) expansion. This problem does not occur with bash 4.3.11 The last error message shown occurred when I typed Esc Ctrl-E (shell

Re: PROMPT_COMMAND and PS1 error

2015-10-25 Thread Andreas Schwab
Florian Mayer writes: > file: first.sh > . second.sh > > sl-get(){ > sl-set > sl-notify-change > echo $? > } > > sl-set-prompt(){ > PS1=$(sl-get)" >>" sl-get is executed in a subshell, and any effect on the state of the shell is forgotten after expansion. Andreas. --

PROMPT_COMMAND and PS1 error

2015-10-25 Thread Florian Mayer
Hello, I'm currently finishing my work building my own "prompt-lib". This, of course, involves manipulating the variables PROMPT_COMMAND and PS{1,2}. Problem description: Imagine a new interactive session where you source one file (first.sh). first.sh also sources another file (second.sh) which