1
vote
2answers
833 views

Apple Mavericks - why doesn't this one-line BASH script set my Python virtual environment like I expect?

I have the following Bash script: #!/bin/bash echo $MYPROJECT_HOME/bin/myproject_venv/bin/activate source $MYPROJECT_HOME/bin/myproject_venv/bin/activate echo ...
0
votes
1answer
154 views

Understanding the scope and lifetime of environment variables in shell scripting

I'm pulling my hair out trying to understand shell scripting and passing environment variables, and what not. I'm trying to execute a PHP script from TextWrangler, that in it's turn opens a new PHP ...
1
vote
4answers
139 views

Mac OS X keeps “old” environment variable around

So far I had /Applications/play-1.2.5/ added to my $PATH variable. Now I'm working with 2.2.1, which I installed in /Applications/play-2.2.1 and changed in ~/.bash_profile (which is getting sourced at ...
2
votes
2answers
65 views

Change environment variable for Mac 10.7

I would like to set the PATH on my Mac 10.7. So in /etc/launchd.conf I wrote: setenv PATH /usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin/:/usr/local/sbin/ and I restarted Mac. However when I write ...
0
votes
0answers
17 views

rvm cluttering up my environment vars

I was trying to see a list of my environment variables in Bash (Mac Terminal) by typing set. But when I do, I am overwhelmed by a bunch of functions apparently defined by RVM. Is this supposed to ...
0
votes
1answer
434 views

Switch characters in MAC address from a variable

This batch is used with a few other files as start-up scripts as a part of the Symantec Ghost Cast re-imaging process for Windows 7 we are about to undertake. Together they totally automate the entire ...
2
votes
2answers
3k views

Setting proxy via http_proxy on Mac

I am using an HTTP proxy on MacOS 10.7 (which works for Safari.app, when set in the system preferences). I'm now trying to set the proxy for command-line applications using the $http_proxy environment ...
1
vote
0answers
224 views

Creating a shortcut in launcher to run a terminal command with more than one parameter as argument

How do you create a shortcut in launcher that lets you run a terminal command using more than one variable? For example, how do you create a launcher shortcut that will prompt you for varA and varB ...
2
votes
1answer
304 views

What prompt is sh using when you type sh into Terminal?

When using the default PS1 prompt that MAC OS/Terminal comes with, when you type sh you get a new style prompt. station-4:~ user$ sh sh-3.2$ When you export your own PS1, this functionality goes ...
7
votes
3answers
22k 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 ...
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 ...
8
votes
2answers
5k 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.
2
votes
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. ...
1
vote
4answers
1k views

Shell environment for su

I have some aliases and modifications to ls that I'd like available at all times. Is it possible to set environment variables for use when I am logged in as root after I sudo up with sudo su?