Environment variables are system-wide variables which share the same value. These variables are often parsed by the shell when executing commands, and are expanded into their appropriate variable. For example, this allows users to move file locations without needing to update hard-coded paths in ...

learn more… | top users | synonyms

3
votes
2answers
8k views

c shell environment variable error: “Bad : modifier in $”

I am using tcsh and define an environmental variable as follows: setenv mycomp myusername@my.computer.com so that when I need to copy files from the remote my.computer.com, I type the following: ...
3
votes
2answers
2k views

Windows 7 PATH not expanding

I am using the following to create and edit environment variables for Windows 7. Control Panel\All Control Panel Items\System -> Advanced system settings -> Environment Variables Under System ...
37
votes
4answers
69k views

How do I make sudo preserve my environment variables?

Using sudo 1.7.4p4 on Solaris 5.10 and sudo 1.6.7p5 on RHEL4 u6 I can't see how to preserve my environment variables, for instance $PYTHONPATH. I've added this line to sudoers, but it doesn't make any ...
0
votes
3answers
251 views

The Consequence of Deleting System Variables

Is there any serious consequence if I accidentally delete environmental variable in Windows 7? I know some program might not be able to run, but will that cause the system to crash at startup?
19
votes
7answers
12k views

Adding an .exe to default path without adding the directory

For example, I want to add notepad++ to my PATH, however the directory also contains uninstall.exe and several other files/executables and I don't want them to "pollute" my path. Can I just add the ...
8
votes
1answer
2k views

Running shortcut from command prompt without the .lnk extension (Windows)

I have created a folder (d:\shortcuts), created shortcuts for most applications in this folder and appended the folder path to the Path environment variable. Now all my applications are available from ...
1
vote
1answer
60 views

overload environment

I've recently switched across to nesting my home directory across all my machines in an svn repo, meaning that my utility scripts, configuration (irssi, vim, zsh, screen etc) as well as my .profile ...
2
votes
5answers
7k views

When someone says “in your path,” what does this mean exactly?

New at programming here. I couldn't find this when I searched google and SO, but I was wondering what programmers mean when they say "put X in your path." Is this the usr/bin? Any other resources I ...
1
vote
2answers
219 views

Path not being searched in Windows XP

I am trying to add the Android Debug Bridge to my PATH in Win XP so that Eclipse won't complain about not being able to find it. Even after I add the platform-tools directory to the path and reset ...
1
vote
1answer
335 views

How can I avoid having to reload my environment?

I'm not sure why, but I keep having to type 'source /etc/environment' in order for my path to be updated correctly. I don't want to type this inside of my bashrc, since I don't want it related to that....
3
votes
3answers
3k views

Where is the Official list of Windows Environment Variables?

I'm working on some .bat stuff created in a legacy application, which uses many environment variables. I need to know exactly what is every one of them (%windir%, %os%, etc.). So I need the official ...
66
votes
3answers
90k views

Is there a list of Windows special directories/shortcuts (like %TEMP%)?

I'm looking for a reference list of shortcuts like %TEMP%. When I'm using Windows+R or Windows Explorer and type %temp%, the Windows Explorer takes me to the Temp directory. Are there more of these ...
1
vote
1answer
2k views

Set environment variable for another user (Standalone Trac problem)

I'd like to run tracd (Trac in standalone mode) with custom template for multiple repository list: $ tracd -p 8080 -e /my/projects/path For custom template, I need an environment variable (as said ...
6
votes
1answer
8k views

What is the purpose of the environment variable asl.log?

I run Windows 7. I notice that there's an environment variable called asl.log. What is this thing? Who puts it there? What's the purpose of it? I searched and found only references to MacOS and ...
12
votes
1answer
11k views

How can I set environment variables for a remote rsync process?

When I use rsync to copy files from one computer to another, an rsync process is started on both ends. However, on the remote end, shell initialization files are apparently not read, so I cannot set ...
7
votes
4answers
235 views

Unexpected behavior in Bash

From man bash: A simple command is a sequence of optional variable assignments followed by blank-separated words and redirections, and terminated by a control operator. The first word specifies the ...
0
votes
2answers
2k views

How do I set an environment variable in tcsh that dynamically references other env vars?

I'm using tcsh here, and am trying to get an environment variable that references another one dynamically... I want to be able to do the following, and I'm sure I've seen it done before elsewhere: $ ...
2
votes
1answer
185 views

Windows: Finding application that set environment variables

Is there a way on Windows to trace the changes from applications or scripts to environment variables on startup? I changed an environment variable in the System->Advanced->Environment Variables ...
3
votes
1answer
3k views

Why can't my bash script export variables?

I am using MSYS and have a file vars.txt with variable, value keys like: WINDIR C:/WINDOWS STS_BUILD_DIRECTORY D:/STS/TMP ALLUSERSPROFILE C:/Documents and Settings/All Users I want to read this in ...
2
votes
2answers
4k views

How to get access to environment variables in Windows?

I have borrowed a laptop with Windows XP from a company that I will do a project for. They say that I have almost Admiinistrator rights on the computer so that I can install software. Now I have ...
3
votes
6answers
2k views

Are there any alternatives to adding to the PATH environment variable in Windows?

Many applications (specially developer tools) require that you add the path to the PATH enviroment variable in Windows. I know what is does, but for me this feels low-level Aren't there any ...
2
votes
1answer
1k views

How to set PATH to run programs outside of default path?

I'm working on a project on my school's linux servers. I have a program deep in a directory, we'll say it's /afs/csic.umd.edu/class/cmsc311/0101/cs311xxx/class/cmsc311/0101/cs311xxx/datalab-handout/...
2
votes
1answer
4k views

Setting (permenant) environment variables in Ubuntu 10.0.4

I am running an application which requires setting environment variables to be set. At the moment, the way I am achieving this is by exporting the EV at the command line, and then running the app ...
1
vote
1answer
257 views

Why PATH variable is different between 'launching from command line' and 'click the icon' in Mac OS X?

As I asked in here, I learned that the environment variable of PATH is different depending on how I launch the app. Using 'aquamacs' from command line is run on top of bash, so the PATH variable is ...
0
votes
1answer
827 views

In Windows XP environment variables, what is the difference between user and system variables?

Is there a reason to add a variable to one over the other if I only ever use one user account?
4
votes
3answers
4k views

Setting environment variables Mac 10.6 [duplicate]

Possible Duplicate: What are PATH and other environment variables, and how can I set or use them? How to set an environment variable in Mac OS 10.6. I am finding it difficult or the options ...
3
votes
4answers
310 views

Why is it bad to add '.' to PATH?

I've read one explanation saying it can allow malicious executables that are in the cwd to run in place of similarly named built-ins and core utilities. For something to wreak true havoc, wouldn't ...
1
vote
1answer
643 views

Problem isolating the environment variable in a shell script

Hey superuser, I’m a novice here but stackoverflow has helped me in the past. I’m writing a bash shell script to generate a makefile (starting small). echo "\ include \$(GNUSTEP_MAKEFILES)/common....
3
votes
1answer
9k views

Windows Server 2008 R2 Environment Variables

How do you set environment variables on Windows Server 2008 R2, specifically the PATH variable? The Microsoft Help source provides advice that doesn't match the screens and options I see on my server.
7
votes
1answer
7k views

How to export Environment variables to a text file

I want to have a look into my Environment variables as a text file into XP Professional. Is there any way?
3
votes
3answers
2k views

Use ~.ssh/config to always set TERM=cygwin for certain hosts?

I use WinSSHd on several Windows servers. To access them from my Mac (and presumably, just about any Unix-based terminal), I need to set the TERM environment variable to cygwin, e.g.: TERM=cygwin ssh ...
0
votes
5answers
4k views

Ubuntu: Edit environment variables via command line

How can you edit the environment variables via command line in ubuntu?
4
votes
3answers
2k views

how to set path environment variable

I want to compile a code in software which is needed to call visual c++;My Os is windows cp professional; I've installed visual studio professional v10.but it still shows an error message indicating "...
4
votes
4answers
366 views

How to get an .exe file to execute no matter where the user types its name in command shell on windows 7?

I have Windows 7. I have a .exe file here: c:\tools\dailybackup.exe When I am in the CMD window, I want to be able to type "dailybackup" in any directory and have it execute. Do I still need to ...
0
votes
1answer
134 views

What is “set environment” variables for?

hey, i noticed that whenever I execute *.bin files, it is needed to run command setenv PATH... Can anybody explain me what is the usage of this command? cheers
10
votes
2answers
11k views

.profile or .bash_profile

I'm confused, where do I set environmental variables? In .profile or in .bash_profile? I am using both mac osx and ubuntu. Confused as to which one I use here.
5
votes
2answers
8k views

How can I set up the python environment variable on Windows 7?

I would sure like to be able to type "python" on my command line instead of C:\Python27\python.exe. So to that end I'm trying to get the environment variable set up for myself. Problem is, I can't ...
17
votes
2answers
23k views

How can I set user environmental variables (such as PATH) from a non-administrator account on Windows 7

How can I set user environmental variables (such as PATH) from a non-administrator account on Windows 7? On Windows XP I could go into the Advanced Settings in the System Control panel. However, on ...
0
votes
1answer
2k views

How can I restore my Vista PATH environment variable when System Restore is not available?

After installing IShadow I found out that my PATH environment variable was changed from some 20 paths to only one path: c:\program files\ishadow\system32. Many Windows tools stopped working, well ...
3
votes
3answers
1k views

If I change an environment variable can that be reflected in cygwin without restarting?

If I have an environment variable set up in windows xp, e.g. JAVA_HOME I can access this from cygwin. But if I change that environment variable through My Computer whilst cygwin is running, cygwin ...
6
votes
5answers
17k views

Windows XP environment variable for “local setting” folder

There's an environment variable, %appdata%, equal to C:\Documents and Settings\<username>\Application Data\ Is there a variable for either C:\Documents and Settings\<username>\Local ...
2
votes
2answers
861 views

mac, when adding environmental variables using 'export ABC=/var/blah/ where is this stored?

when adding env varialbes like: export JAVA_HOME=/usr/java/skd/bin where is this stored if I want to edit it later? is it a file somewhere?
2
votes
3answers
727 views

macbook, messed up my .profile and now no commands work like nano, rm, etc

I messed up a .profile and now I can't even get nano to work. I was trying to add git to my environment variable whenever I start terminal, and I messed the command up obviously and no nothing works. ...
0
votes
4answers
10k views

set JAVA_HOME in windows but “ant build” still fails

I've set JAVA_HOME in my Windows environment preferences: echo %JAVA_HOME% C:\Program Files (x86)\Java\jdk1.6.0_20 However whenever I try to run ant build I get the following: Perhaps ...
2
votes
1answer
1k views

/etc/environment and cron

I've got two machines: Fedora and CentOS. And a cronjob 0-59 * * * * env > /home/me/env.log On CentOS I can see that /etc/environment is affecting the output while on Fedora it does not. I want ...
1
vote
1answer
2k views

Exporting Environment Variables in Ubuntu Linux

I know many people have asked about environment variables before, but I am having a hard time dealing with these paths while ensuring I don't mess around with the original settings. How would you go ...
1
vote
1answer
68 views

Weird behavior with Bash

I recently changed my .bashrc and tweaked how my PS1 looks, but now it has a very weird problem. Before the end of the line in terminal (about 2 3rds of the way in) it jumps back to the begining of ...
2
votes
3answers
7k views

Setting environment variables in OS X /etc/launchd.conf

I'm trying to set some env variable in OS X 10.6 (/etc/launchd.conf) setenv M2_HOME /usr/share/maven setenv M2 $M2_HOME/bin setenv MAVEN_OPTS '-Xms256m -Xmx512m' M2 and MAVEN_OPTS are not working. ...
4
votes
4answers
7k views

cmd.exe SET command does not save values for new cmd.exe sessions [duplicate]

Possible Duplicates: Set Permanent Environmental Variable in Windows XP Is there a way to set Windows environment variables from the command line PERMANENTLY The set command does not save ...
1
vote
1answer
452 views

environment variable issue in shell

I am using Red Hat Linux Enterprise 5. I know the theory that -- using export to set environment variable, the environment variable will apply to current and child environment, but without using ...