[opensuse] Extremely hideous mishandling of history in bash
Hi, wandering through countless distributions I'd never seen this most hideous handling of the bash history: in OpenSuse when you select a previous command with the up-arrow key, then modify it in some manner and run it this last command is forgotten. If you press once again the up-arrow key the command you see is not the last you ran, but the one before it. Is there any setting I can use to restore the only sane behaviour? Thanks, Nico -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
Nico Sabbi
Hi, wandering through countless distributions I'd never seen this most hideous handling of the bash history: in OpenSuse when you select a previous command with the up-arrow key, then modify it in some manner and run it this last command is forgotten. If you press once again the up-arrow key the command you see is not the last you ran, but the one before it. Is there any setting I can use to restore the only sane behaviour?
I'm not sure I follow you (or I have old settings): $ ls -A [...] up-arrow, edit it to use: $ ls -Af [...] $ history |tail 1010 ls -a 1011 ls -af ... So, this works as expected for me... Andreas -- Andreas Jaeger, Director Platform / openSUSE, aj@suse.de SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg) Maxfeldstr. 5, 90409 Nürnberg, Germany GPG fingerprint = 93A3 365E CE47 B889 DF7F FED1 389A 563C C272 A126
Andreas Jaeger wrote:
So, this works as expected for me...
Also OK here. Nico: it would be helpful if you tell us which openSUSE version are you using and/or you could execute "rpm -q bash" to determine the version of bash package. -- Best Regards / S pozdravom, Pavol RUSNAK SUSE LINUX, s.r.o Package Maintainer Lihovarska 1060/12 PGP 0xA6917144 19000 Praha 9, CR prusnak[at]suse.cz http://www.suse.cz -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On Wednesday 30 July 2008 11:25:25 Pavol Rusnak wrote:
Andreas Jaeger wrote:
So, this works as expected for me...
Also OK here. Nico: it would be helpful if you tell us which openSUSE version are you using
10.3
and/or you could execute "rpm -q bash" to determine the version of bash package.
bash-3.2-61 -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
Pavol Rusnak wrote:
Andreas Jaeger wrote:
So, this works as expected for me...
Also OK here. Nico: it would be helpful if you tell us which openSUSE version are you using and/or you could execute "rpm -q bash" to determine the version of bash package.
Andreas, Pavel, I believe what Nico was referring to was the up-arrow history, which you did not mention in your replies. However, I tried it on my 11.0 kde3 system, and it works as I expect -- up-arrow gives ls -Af, then up-arrow again gives ls -A (using Andreas's example). So something is strange in Nico's system. John Perry -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
Andreas Jaeger wrote:
I'm not sure I follow you (or I have old settings): $ ls -A [...] up-arrow, edit it to use: $ ls -Af [...] $ history |tail 1010 ls -a 1011 ls -af ...
So, this works as expected for me...
I'm deeply concerned about your settings! They've somehow changed ls -A into ls -a :) On this 9.3 system, that sequence works as expected, but the following sequence produces a somewhat unexpected result: $ ls -A [...] up-arrow, edit it to use: $ ls -Af [...] up-arrow to the ls -Af line and add g to the end don't execute it, but up-arrow down arrow, the g is there don't execute, down-arrow to an empty prompt $ history |tail ... 1001 ls -A 1002* ls -Afg ... It appears to have completely lost the record of the ls -Af command that was executed and instead recorded a command that was never executed. It is occasionally annoying when I forget about it :( I've no idea if this occurs on newer systems. Cheers, Dave -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
Dave Howorth
Andreas Jaeger wrote:
I'm not sure I follow you (or I have old settings): $ ls -A [...] up-arrow, edit it to use: $ ls -Af [...] $ history |tail 1010 ls -a 1011 ls -af ...
So, this works as expected for me...
I'm deeply concerned about your settings! They've somehow changed ls -A into ls -a :)
I should have copied and paste everything ;)
On this 9.3 system, that sequence works as expected, but the following sequence produces a somewhat unexpected result:
9.3 is ancient and does not even get security fixes anymore...
$ ls -A [...] up-arrow, edit it to use: $ ls -Af [...] up-arrow to the ls -Af line and add g to the end don't execute it, but up-arrow down arrow, the g is there don't execute, down-arrow to an empty prompt $ history |tail ... 1001 ls -A 1002* ls -Afg ...
It appears to have completely lost the record of the ls -Af command that was executed and instead recorded a command that was never executed.
Yes, happens on my 11.0 system as well - and it looks like this is intented, it's history editing IMO.
It is occasionally annoying when I forget about it :(
I've no idea if this occurs on newer systems.
Andreas -- Andreas Jaeger, Director Platform / openSUSE, aj@suse.de SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg) Maxfeldstr. 5, 90409 Nürnberg, Germany GPG fingerprint = 93A3 365E CE47 B889 DF7F FED1 389A 563C C272 A126
Andreas Jaeger wrote:
9.3 is ancient and does not even get security fixes anymore...
Feel free to attack the m/c if you think that's a problem. It works for now :( Perhaps I'll upgrade it to 11.1
It appears to have completely lost the record of the ls -Af command that was executed and instead recorded a command that was never executed.
Yes, happens on my 11.0 system as well - and it looks like this is intented, it's history editing IMO.
Yes, that's why British and American history books read differently :) It would be better if it kept the original edited line and inserted the new one at the end, IMHO. As a workaround, if I realize I've made a mistake whilst editing a command, I don't abandon the edit. I add something else to make it harmless, such as a nonexistent command at the beginning, and then execute it. That way, I can recover the original history. Cheers, Dave -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
Dave Howorth wrote:
Andreas Jaeger wrote:
9.3 is ancient and does not even get security fixes anymore...
Feel free to attack the m/c if you think that's a problem. It works for now :( Perhaps I'll upgrade it to 11.1
It appears to have completely lost the record of the ls -Af command that was executed and instead recorded a command that was never executed. Yes, happens on my 11.0 system as well - and it looks like this is intented, it's history editing IMO.
Yes, that's why British and American history books read differently :)
It would be better if it kept the original edited line and inserted the new one at the end, IMHO.
As a workaround, if I realize I've made a mistake whilst editing a command, I don't abandon the edit. I add something else to make it harmless, such as a nonexistent command at the beginning, and then execute it. That way, I can recover the original history.
Cheers, Dave
I've given the mysterious commands a go and all is fine on an 11.0 laptop, 10.3 server, 10.3 desktop, and 10.0 server. All produce the following in the history list: 3015 ls -A 3016 ls -Af 3017 history I agree with Dave. I had a 9.3 server until just a few months ago. I found no real reason to change it other than to avoid becoming a dinosaur...Dave? -- David C. Rankin, J.D., P.E. Rankin Law Firm, PLLC 510 Ochiltree Street Nacogdoches, Texas 75961 Telephone: (936) 715-9333 Facsimile: (936) 715-9339 www.rankinlawfirm.com -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
Dave Howorth a écrit :
It appears to have completely lost the record of the ls -Af command that was executed and instead recorded a command that was never executed.
I always see this feature. It's a problem if you make a mistake and type an arrow, the original line is lost jdd -- Jean-Daniel Dodin Président du CULTe www.culte.org -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
participants (7)
-
Andreas Jaeger
-
Dave Howorth
-
David C. Rankin
-
jdd sur free
-
John E. Perry
-
Nico Sabbi
-
Pavol Rusnak