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

leading space in command line won't save command in history #1606

Closed
anddam opened this issue Aug 10, 2014 · 2 comments
Closed

leading space in command line won't save command in history #1606

anddam opened this issue Aug 10, 2014 · 2 comments

Comments

@anddam
Copy link

anddam commented Aug 10, 2014

Typing a command with a leading space prevents the command from being saved in history.

To reproduce print out the history file content, either using cat or tail -f and then run

echo "foo"
 echo "bar"

the first line is added to the file while the second isn't.
This can be reproduced with 2.0.0 and 2.1.0 on OS X and Arch Linux.

@ridiculousfish
Copy link
Member

Yes, this is a feature common across other shells. bash has it as HISTCONTROL=ignorespace. See #615

@anddam
Copy link
Author

anddam commented Aug 10, 2014

Ah, now I see it in Documentation > Command line editor:

Prefixing the commandline with a space will prevent the entire line from being stored in the history.

a classic case of "it's a feature, not a bug".

It'd be still nice to be able to turn the feature off as it's mentioned about in #615.

This ticket can be closed.

@krader1961 krader1961 modified the milestone: will-not-implement Nov 22, 2016
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants