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

0
votes
1answer
21 views

Adding App to Path on Mac OS X

I'm in the process of migrating from Windows to Mac OS X. Right now, I'm trying to use this plugin in an application. The plugin states: Make sure you can find Magick++-config in your PATH. My ...
0
votes
0answers
15 views

set/modify environment variable for gnome/kde at runtime

Is there a way to modify or set environment variables in gnome or kde at runtime, ie. after logging in? I specifically need this for gnome, but knowing the kde method would be really useful too. If ...
4
votes
3answers
3k views

Switching between Java 7 and 8 in OS X

I have installed Java-8. Now I wanted to go back to Java-7 by default so I type in... /usr/libexec/java_home -v 1.7.0_40 --exec java -version /usr/libexec/java_home -v 1.7.0_40 --exec javac -version ...
5
votes
5answers
1k views

When I run an app from the cmd-line, how do I find the exe's path?

When I run an app from the DOS Prompt in Windows, the command in question is often not in the current directory, but is found via the PATH environment variable. What's the quickest way to find the ...
0
votes
1answer
269 views

How to set path for MinTTY under windows/cygwin correctly?

I made windows shortcut with the following target: D:\APPS\cygwin64\bin\mintty.exe /bin/env PATH=/local/bin:/usr/local/bin:$PATH /bin/bash --login -i I was expecting it prepend path with my given ...
4
votes
1answer
56 views

When should you set PATH variables in “User variables” vs. “System variables”?

On a single-user system (Windows 7), does it matter whether you set PATH variables in User-variables or System-variables? Why choose one over the other?
6
votes
3answers
4k views

Why won't my Windows 8 Command line update its path

I needed to add a new entry to my PATH variable. This is a common activity for me in my job, but I've recently started using Windows 8. I assumed the process would be similar to Windows 7, Vista, ...
9
votes
8answers
4k views

$PATH in Vim doesn't match Terminal

I'm using MacVim and when I don't launch it from the Terminal (mvim) its $PATH does not include what I have set in my .bash_profile. It only seems to have the default values, ...
1
vote
1answer
13 views

env command shows 3 times same path

When i run env it shows 3 times /usr/bin under PATH . Same for every path under PATH title. For example - my scala bin directory shows 3 times . However, in my .bash_profile, it is written just one ...
0
votes
0answers
16 views

Java with multiple versions on Windows [duplicate]

I have both Java 6 & 7 installed on my machine. My Windows' PATH variable has Java 6 JRE's location added to it. But when I open Command Prompt or Windows PowerShell and type java -version it ...
16
votes
2answers
23k views

Can I change the PATH environmental variable in Windows 7 without restarting?

Is there anyway to change the PATH environment variable (or variables in general) on Windows 7 Exterprise (64 bit) and have it take effect in PowerShell or the command prompt (cmd.exe) without ...
35
votes
4answers
41k 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
0answers
35 views

Stop Windows %tmp% environment variable using short file name

I have a C++ application that is using the %tmp% variable (from the GetTempPath() function). Unfortunately there is a bug where it can't handle the tidle that may appear in the user's local temp ...
0
votes
0answers
29 views

Phusion Passenger Showing Environment Variables

I'm getting some Phusion Passenger errors with Ruby On Rails Problem is it's showing my environment variables in the error report. This is great in development, but what happens if my server faulters ...
3
votes
1answer
177 views

Powershell systemroot in $env:path different when AC elevated

I have a strange behavior with the environment variables at my Windows XP SP3. When I logon as Administrator, the %SystemRoot% strings in PATH are substituted to C:\WINDOWS, the value of the variable ...
1
vote
1answer
23 views

Apache VirtualHost - Specific Env Vars

Successfully using SetEnv with virtualhosts on Apache2 Wondering if there's a way to set virtualhost specific env vars, or whether setting them at Apache-level makes them "global" / system-wide? We ...
1
vote
0answers
46 views

Would a longer PATH environment variable slow down a system?

In Windows 7, will a long system PATH environment variable slow down the system in any noticeable/tangible way? My system PATH variable is 45-entries deep. I have an i7 930 @ 4.2GHz, but out of ...
0
votes
1answer
94 views

Change the timezone (TZ environment variable) for a running irssi session?

When travelling to other timezones, I set TZ=/usr/share/zoneinfo/current_timezone on remote shells where I log on to, including the shell in which I run irssi inside tmux. Can I change the TZ for a ...
7
votes
3answers
7k views

adding PATH with SETX or PATHMAN or something else?

I am trying to add a PATH from command line, as with SETX %PATH%... it always expands the PATH, which I don't want. PATHMAN is exactly for this purpose, but it doesn't work for me on Windows 7. It ...
1
vote
0answers
12 views

Environment variable with different value [duplicate]

I operate a windows system with several applications, that all need a special home variable. But if I set this "home" variable, all applications use the same value. Is there a way to set this ...
0
votes
3answers
145 views

How can I add a program path to the Windows environment variables for easy command line access?

Let's say I want to add the following path to the Windows environment variables: C:\Program Files (x86)\VideoLAN\VLC\vlc.exe Such that I can simply type the following from a command line without using ...
2
votes
1answer
140 views

What's the ZSH equivalent of BASH's $PROMPT_COMMAND?

BASH supports a $PROMPT_COMMAND environment variable that defines a command to be executed before any first-level interactive prompt. I'm looking for a ZSH equilvalent of that. The documentation says ...
0
votes
0answers
99 views

setting https_proxy environment variable in a secure way

The following is the standard way suggested to set the environment variable for the https_proxy: export https_proxy=<username>:<password>@<proxy>:<port> But it clearly ...
0
votes
1answer
37 views

Does the order of the directories listed in the Windows PATH variable affect system performance in any meaningful way?

I've noticed that when programs add their directory to the PATH environmental variable, most append it to the end but a few add it at the beginning, before the windows directory. So it made me wonder, ...
2
votes
1answer
41 views

Bash: Need to export variables to parent process. Is the parent the same process?

I'd like to launch a script that sets and/or updates some environment variables. Unlike this question, I don't mind launching the script as . /path/to/my/script/myScript.sh to force the script to ...
8
votes
2answers
10k 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 ...
2
votes
1answer
91 views

Export Command — Intended Effect?

In the FAQ article on aMSN, it states that if you have aMSN to "hang up" often and you have configured all of your sound options correctly to try running aMSN with this command: export ...
1
vote
3answers
259 views

PowerShell - environment vars - differentiating between user and system vars

How can I display environment variables in PowerShell, and be able to distinguish between which ones are "user" vars and which ones are "system" vars?
2
votes
3answers
521 views

How to delete a file from the file system in Linux when I don't have permission?

I re-installed ns2, but didn't delete a file from the filesystem with path: /usr/bin/ns So when I type on my terminal: which ns I get: /usr/bin/ns Instead of the path I have set which is: ...
4
votes
1answer
110 views

Using a system variable with spaces without truncating prematurely

I need to do something similar to this: dir > %USERNAME%.txt But what I get is that if the filename has a SPACE(" ") in it, then the name is cut there. I know that if I do this: set ...
1
vote
0answers
79 views

Nested environment variable does not expanded

I can't explain the below strange issue. I have two system variables: PYTHONHOME = D:\Tools\ISDC_Tools\Scripting\Python.2.7 PYTHONPATH = %PYTHONHOME%;%PYTHONHOME%\Lib After creating a new cmd ...
1
vote
2answers
570 views

Strange PATH issue in Windows 7 - goes null after being set

I have some sort of a problem with the PATH system variable. Since I use a lot of cmd apps and scripts I've added a lot to it. But the string's length is not the issue. I've worked around this ...
0
votes
0answers
24 views

In MacOSX Mavericks, launching an app from the command line versus by double-clicking [duplicate]

In MacOSX Mavericks, what are the differences between launching an app by double-clicking it or through Spotlight, and from the command line? By launching an app such as Emacs from the command ...
0
votes
1answer
261 views

Why are the PATH environment variables handled differently when I run cmd.exe as admin?

Original post: When I start cmd.exe normally, my PATH variable only contains the paths from the system environment variable. Only when I start cmd.exe as admin does PATH contain a concatenation of ...
1
vote
0answers
84 views

PATH variable - System vs User - why is it dangerous to modify System PATH on Windows?

While installing MinGW, the users are warned about making changes to the System PATH variable: You should not alter the system path variable in any manner, or you will cause all sorts of problems ...
2
votes
2answers
74 views

env -i zsh | How is this magic possible?

I'm currently working, for school, on a home-made shell, therefore I'm kind of curious nowadays about how shell vars are set. Yes, this can be really exciting ! Anyway, we obviously have to deal with ...
2
votes
1answer
426 views

Prevent Windows System %PATH% from being prepended to user %PATH?

I know how to set system or user specific environment variables: Now, the problem is that the PATH variable is treated such that the value you enter for the user PATH will be automatically appended ...
1
vote
4answers
4k views

How do I substitute environment variables when I ouput a file?

I'd like to somehow spit out a file (which has env variable references) and substitute the actual values. This is what I've tried, but as you can see it's not working. Any ideas? -bash-3.00$ cat ...
1
vote
3answers
5k 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. ...
2
votes
2answers
82 views

Name “wmplayer” is not recognized as an executable file

I cannot run wmplayer from either cmd or PowerShell. My OS is Windows 7 64 bit. I can do it using start wmplayer but I cannot use parameters. Please, help me to handle it.
0
votes
0answers
24 views

What environment variables are set when I use ssh?

When I use ssh, I notice that my TERM variable is forwarded automatically. This is quite useful, but I'm wondering what other variables are forwarded or set. So far I've found the following ...
0
votes
1answer
16 views

Should I make `emacs` a symlink or environment variable?

When I apt-get install emacs I can just type emacs and it launches. But I decided to replace the apt repository version (23 currently) with the latest stable release (24.3). Now, I'd still like to ...
0
votes
0answers
27 views

Shell hangs after passing STDIN to EDITOR with -w parameter

I want to edit svn's svn:ignore property: svn propedit svn:ignore . This doesn't work: None of the environment variables SVN_EDITOR, VISUAL or EDITOR is set, and no 'editor-cmd' run-time ...
1
vote
1answer
67 views

How do I extend my PATH environment variable?

Being a power user, my %PATH% variable just isn't long enough to install everything I want to install. Is there any way I can extend the effective length of the variable, or otherwise get more paths ...
0
votes
1answer
31 views

Set ENV variable for all commands in current directory in mac os

Is there a way to run all commands in current directory with some ENV variables predefined? Example of what I need: I put some file, say .env in my directory, with: export SECRET='abcd123' Then I ...
0
votes
1answer
3k views

changing /etc/profile does nothing to root PATH

rhel 5 root has /bin/bash for shell. I removed pathmunge /usr/local/sbin from /etc/profile. There is no /usr/local/sbin in /etc/profile.d/* /etc/bashrc /root/.bashrc /root/.bash_profile /root/.profile ...
7
votes
3answers
20k views

Where do I set DYLD_LIBRARY_PATH on Mac OS X, and is it a good idea?

I am trying to install a solver written in C++ on my Mac (OS X), for use with code I have written in XCode. The solver documentation says this: Be sure to have "." in your DYLD_LIBRARY_PATH in ...
1
vote
1answer
184 views

Awesome WM: execute my aliases via run prompt?

I have aliases in my bashrc for a few programs. One example is: alias chrome='google-chrome --disk-cache-size=1000000000' How can I call this alias from the run prompt (modkey+r)? Im running ...
0
votes
1answer
26 views

monit fails to support dbus session

I am trying to use monit to monitor and automatically issues like crashes, memory leaks and cpu hotspinning. For one application - one that uses DBus (serving and calling funcs) just will not start. ...
0
votes
0answers
72 views

Correct way of setting Ruby2.1 as the go-to application when it referenced to/called via shell?

I have installed Ruby 2.1 on my headless Debian server (7.4) by downloading the source from https://www.ruby-lang.org/en/downloads/ and then running the routine of ./configure make make install ...