Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

To put it simple and short - I start my Windows command prompt from Win-R, then cmd, from several shortcuts with different enviromental variables, and from inside some editors (don't know how they start it).

Now, I need to set set term= in every of them cmds, without doing it down manually every time. Is there a way?

Are there some global options of cmd somewhere in the registry?

share|improve this question
add comment

4 Answers 4

up vote 4 down vote accepted

You are probably referring to environment variables.

The environment is inherited by each process from its parent. In Windows, the first environment is established by the logon process. So, if you launch any editor or other program, it will inherit from Windows its environment, add to it its own variables, and will pass them all to any cmd child that it launches on its own account.

If you want term to be always present in any cmd process that is ever launched on your login, go to Control Panel / System / Advanced / Environment variables. There you have the choice of setting term for you own logon or for the system (meaning every process launched with or without login).

If you are looking for a better GUI than that offered by Windows, the freeware Rapid Environment Editor is an excellent option.

share|improve this answer
    
Good grief. This sounds stupid but before I asked the question, I looked and didn't see it there. :( Must've missed it ... late hours, I guess ... –  Rook Nov 13 '10 at 15:05
add comment

I would strongly recommend switching to Cygwin. Take the power of the Unix terminal and plug it into Windows.

share|improve this answer
    
Got a lot of programs which are (so to speak) written for cmd environment, which I need for work. Can't switch. Otherwise, it would be an option. –  Rook Nov 13 '10 at 2:22
    
@Rook 99% of all DOS programs work in cygwin –  TheLQ Nov 13 '10 at 2:33
    
@TheLQ - Not when they have hardcoded paths and depend on DOS commands(some of which I've had to rewrite for cmd, since they were no longer available). Trust me on this one... –  Rook Nov 13 '10 at 2:47
    
@TheLQ: Who still uses DOS programs nowadays? –  Joey Nov 13 '10 at 11:06
1  
@TheLQ: they never said that. You might confuse Windows console programs with DOS. –  Joey Nov 13 '10 at 18:07
show 2 more comments

I'm not familiar with set term, but you can always set environment variables in the System control panel.

You were probably looking for the autorun value in the registry located here:

HKEY_LOCAL_MACHINE\Software\Microsoft\Command Processor

And/or:

HKEY_CURRENT_USER\Software\Microsoft\Command Processor

This should be a REG_SZ or a REG_EXPAND_SZ containing a command executable in Command Prompt. You may want to set this to, say %USERPROFILE%\autorun.bat to run a series of commands.

Note that the HKLM value will be run before the HKCU value if both are set.

Source: http://technet.microsoft.com/en-us/library/cc779439%28WS.10%29.aspx

Beware of http://blogs.msdn.com/b/oldnewthing/archive/2007/11/21/6447771.aspx though.

share|improve this answer
add comment

Install ConEmu. Native shell, nicer features, and a possibility to do a cool hack over FAR alt text

share|improve this answer
1  
Btw, there is sort of "Autoattach" feature (ConEmu may be started with cmd.exe), and you may attach any console to existing ConEmu instance. I'm great fan of Far Manager, but ConEmu may be used with any shell processor - cmd/powershell/bash/etc. –  Maximus Oct 14 '12 at 0:30
    
@Maximus, I know it is expected to be used with any shell, the answer's idea was to show some console eyecandy too. –  kagali-san Oct 14 '12 at 9:28
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.