Customize the Command Prompt
Menu: System Menu -> Properties
Versions: 2008,2010
Published: 7/22/2010
Code: vstipTool0058
If you are going to use the command prompt you may want to customize it:
NOTE: If you want to customize the VS command window then you need to run it as administrator to do this:
Let's review some basic settings you will want to take advantage of so let's review some of them. First go to System Menu -> Properties:
On the Options Tab there are several items of interest:
Cursor Size-is just the size of the flashing cursor
Command History-deals with how many commands are remembered by setting the Buffer Size (number of commands to remember) X Number of Buffers. The default is 200 commands but this value can be changed to 999 for each value for a total of 998,001 commands that can be remembered. I typically will set Buffer Size to 100 and Number of Buffers to 5 for a total of 500 commands remembered.
I always select the Discard Old Duplicates option. Some people leave this off for running the same command several times so you may want to leave this off in some cases. This option will remove duplicates so they don't show up several times in the command history.
BEFORE
AFTER
Edit Options-These options define how you can do certain actions. Quick Edit Mode was described in vstipTool0057 and I suggest you use it. AutoComplete allows for TAB completion of file names (see vstipTool0056) you should always leave this setting on. Insert Mode is on by default and simply means that if you move the cursor into a command (using the ARROW keys):
You can type and it will insert (instead of overwrite) the text after it:
The Font Tab is pretty self-explanatory. It allows you to pick various font properties for the command window. Play with these to suit your needs.
The Layout Tab is very important. Let's look at some of these options.
Screen Buffer Size-allows you to set how wide and tall you want the WINDOW information to be. Width should be less than the Window Size Width you anticipate. Since I tend to maximize my command windows, I set this to 100. Height is how many lines you want to be able to scroll back to. I set this to 5000 for me just because I like large buffer sizes. Most folks tend to set this to around 1000 or so.
Window Size-sets the initial size of the command window. You can play with these settings to find a suitable size for you. Since I maximize my command windows I just leave this setting alone.
Window Position-the position you want the window to start in. I would leave this setting be but, if you want to change it, then set left and top to 0 then increase from there to fit your taste.
The Colors Tab allows you to change two major aspects of the color scheme for the command window. One for the regular window and one for the popup you get when you press F7.
These settings are completely personal preference so I would adjust them and see the previews at the bottom to see what schemes suit you. As you can see, I tend to favor the old school "green screen" colors on my command windows.
Reset Back To Default
If you totally mess up your settings, you can always get all the default settings back by going to System Menu -> Defaults:
This will show the Properties with ALL TABS SET TO THEIR DEFAULT SETTINGS. Just click OK and you have all your defaults back:
Comments
Anonymous
July 22, 2010
ALWAYS is a harsh term. If "Discard Old Duplicates" is on, you can't replay a series of commands. For example, with "Discard Old Duplicates" off, you can up arrow to the start of a series of commands, and press Enter, down arrow, Enter, down arrow repeatedly to replay the history sequence. With it on, that doesn't work. For that reason, I ALWAYS turn it off :^)Anonymous
July 22, 2010
Mark T. -- Good point. I always turn it on but you may not. I've updated the post. :)Anonymous
July 26, 2010
Hidden in your post is something I didn't know about: Pressing F7 gives a list of last commands.Anonymous
July 26, 2010
Hey Daniel :) Check out this post for info on F7: blogs.msdn.com/.../command-prompt-history-vstiptool0055.aspx Z