hdy.brackets-shell icon indicating copy to clipboard operation
hdy.brackets-shell copied to clipboard

Fixed mac support

Open mvidmar opened this issue 9 years ago • 6 comments

Hi,

I fixed the enviroment issues with Mac not loading enviroment variables. Not the prettiest fix but I can confirm it working on my Mac.

mvidmar avatar Apr 24 '15 15:04 mvidmar

@mvidmar Thanks for pull-request. Great work, I have been struggling with Mac support being that I'm not a Mac user. I'll have a look at it this evening and see if I can have a new version out this weekend.

johnhidey avatar Apr 24 '15 15:04 johnhidey

Wasn't able to look at this over the weekend, I'll have to see how my upcoming week looks. :8ball:

johnhidey avatar Apr 27 '15 12:04 johnhidey

This doesn't work on my mac and seems to break it even further.

Here's the error I get for everything /bin/bash: /c: No such file or directory. Might be wrong but I don't think the /c should be there..

shaneparsons avatar May 28 '15 13:05 shaneparsons

Hoping to get some time this upcoming weekend to work on this. @shaneparsons The /c most for mac I believe should be a -c instead. I'll try to make that adjustment and push this upcoming weekend assuming I can find the time.

johnhidey avatar Jun 01 '15 13:06 johnhidey

OS X no longer uses $HOME/.MacOSX/environment to store environmental variables. ~/.launchd.conf is the modern equivalent, but it must be created manually. http://stackoverflow.com/questions/603785/environment-variables-in-mac-os-x/4567308#4567308

joshuaess avatar Jun 22 '15 00:06 joshuaess

I used this in Yosemite with a little trick. @joshuaess is right about the fact that $HOME/.MacOSX/environment.plist is no longer used by MacOSX so this might not be the final fix.

What I did to make it work is to crete by hand the $HOME/.MacOSX/environment.plist following this instructions: http://www.dowdandassociates.com/blog/content/howto-set-an-environment-variable-in-mac-os-x-home-slash-dot-macosx-slash-environment-dot-plist/

Bad part is that you need to create the file by hand and maintain the contents. What I did was to create a file like : { PATH = "/Library/Java/JavaVirtualMachines/jdk1.7.0_51.jdk/Contents/Home/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/git/bin:/Users/someuser/Development/apache-maven-3.2.3/bin"; }

As this is not a OS file any more probably it would be better to use a different name&path or even better setup this value directly as an addon variable... If I have time in the following day I might propose a pull request

carlosrubio avatar Jul 17 '15 22:07 carlosrubio