views:

520

answers:

3

It seems random: after some amount of time / usage of any console I use on Windows Vista, I lose the ability to use the command-line history (or command buffer, if you prefer...), and hitting the up or down arrow no longer does anything at all, meaning there are essentially 0 items available in the history.

I've seen this behavior in Cygwin, CMD, and PowerShell.

Sometimes this behavior applies to processes running inside the console - Python, MySQL client, etc.

Is this an inherent problem in Windows? A setting somewhere? Are there other consoles that don't have this problem?

ps - if you think this is non-programming related, please see other questions regarding programming tools, for instance, nearly anything tagged "eclipse" which deal with how to use the IDE rather than programming for it.

+2  A: 

There's a maximum size of history buffer in a windows "DOS box" -- Upper left icon, right click, select properties and you'll see the Command History has a buffer size of 50 by default.

Steve Gilham
Yet this isn't exactly the problem -- you would expect this to imply a floating window of history, rather than the history **breaks** when you hit 50 -- the breakage is the noticed behavior, and sometimes well before 50.
wsorenson
what do you mean by breaks?
Toby Allen
The up arrow no longer recalls any items at all.
wsorenson
+2  A: 

What happens if you hit F7 to display the history, does it show the full list or only up to the point that the up arrow is stopping at?

/matt

Matt Dewey
As described, the up arrow doesn't do _anything_ -- it does not stop at a certain place in the history -- it no longer recalls anything.
wsorenson
I understand that the up arrow isn't doing anything, but does F7 display the history or does that also do nothing? Just trying to see if we can identify a common component.
Matt Dewey
+2  A: 

In PowerShell you can control the maximum size of history via the MaximumHistoryCount automatic variable (default is 64)

PS > $MaximumHistoryCount

Shay Levy