🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

1 total messages Started by Kayvan Sylvan Thu, 11 Jan 1990 20:12
Bug report (!!:p strange behavior)
#1135
Author: Kayvan Sylvan
Date: Thu, 11 Jan 1990 20:12
53 lines
2107 bytes
Bash 1.04.5 on Xenix 2.3.2 running on Everex Step/25 (intel386).

I went to use the "!!:p" history recalling feature.
I have "alias hi=history" in my .bash_aliases.

I also have history_control=ignoredups (which seems to work *after*
the first duplicate entry is entered into the history - Is this
intentional?).

I was doing this from within Emacs (Outside Emacs, the difference
seems to be that the command "!!:p" or "!num:p" is re-echoed at each
prompt).

	bash:529$ : Testing bash history recall
	bash:530$ hi 3
	  528  hi 10
	  529  : Testing bash history recall
	  530  hi 3
	bash:531$ !529:p
	: Testing bash history recall

So far so good. Now I just hist return.

	bash:531$ 
	: Testing bash history recall
	bash:531$ 
	: Testing bash history recall
	bash:531$ 
	: Testing bash history recall
	bash:531$ 

At this point I hit C-c C-c within Emacs to get the shell to stop
echoing. If I type something in at this point, It would get it appended
to the line that is being echoed. (Outside of Emacs, a simple C-u
clears the line). The history number gets changed now to 535.

	bash:535$ hi 7
	  529  : Testing bash history recall
	  530  hi 3
	  531  : Testing bash history recall
	  532  : Testing bash history recall
	  533  : Testing bash history recall
	  534  : Testing bash history recall
	  535  hi 7
	bash:536$ 

It seems that the ignoredups variable had no effect in this case.

This whole sequence was somewhat confusing the first time I ran into
it (within Emacs) since there was no indication that the "!529:p" was
still being acted on upon subsequent RET or newlines.

			---Kayvan
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads