Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bash eternal history PROMPT_COMMAND escaping tweak #2

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

bowman
Copy link

@bowman bowman commented Jul 4, 2013

Handle the awk -F"\t" quirk using { echo -ne ... ; history 1} to avoid interpreting the history output.
Should not slow the prompt as they're all built-ins.

Seemed to work fine during my 30 seconds of testing, YMMV.

Brad Bowman added 2 commits July 4, 2013 21:34
Append the output of a group command to .bash_eternal_history
to avoid the history output getting interpreted by echo -e.
Added -n to echo to maintain the format.

PROMPT_COMMAND='{ echo -ne ...; history 1 }>>~/.bash_eternal_history''
roman-spiridonov referenced this pull request in roman-spiridonov/devops Mar 28, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant