Strange behavior with Atom

Questions, glitches, bugs and crashes
Post Reply
don
Posts: 130
Joined: Sat Jul 18, 2015 11:03 am
Location: Sydney, AU

Strange behavior with Atom

Post by don » Sun Feb 05, 2017 12:56 am

Good day.

Would you be familiar with the username "kn" ?

The reason I am asking is that I am trying to make Atom work with Hydrogen plugin. And when started from the iTerm2 or Alfred - all works well.
When started from Nimble Commander - the local python install is not found and the plugin refers to "Users/kn"

Just wanted to understand a bit better as to how NImble inherits the environment?

don
Posts: 130
Joined: Sat Jul 18, 2015 11:03 am
Location: Sydney, AU

Re: Strange behavior with Atom

Post by don » Sun Feb 05, 2017 10:28 am

Okey, the environment variable list as seen in Atom is a lot shorter when started through NC.
Quite a few missing.

Not sure where to start. May be PATH? NC uses its own - shorter version. Where could I set PATH for NC?
How does it inherit one?

The other one is ATOM_DISABLE_SHELLING_OUT_FOR_ENVIRONMENT set to "true" when started through NC. Could I change it somehow?

User avatar
mike
Posts: 803
Joined: Thu Jul 16, 2015 5:35 am
Location: Exeter, UK

Re: Strange behavior with Atom

Post by mike » Wed Feb 08, 2017 2:46 pm

don wrote:
Sun Feb 05, 2017 12:56 am
Would you be familiar with the username "kn" ?
Nope, there're no hardcoded usernames in NC.
don wrote:
Sun Feb 05, 2017 12:56 am
Just wanted to understand a bit better as to how NImble inherits the environment?
It copies current environment (in which NC itself works) and restoring it for terminal forks.
I.e. for the fork with a shell and for single-task forks, like external editors running in terminal emulator.
don wrote:
Sun Feb 05, 2017 10:28 am
Okey, the environment variable list as seen in Atom is a lot shorter when started through NC.
Quite a few missing.
Shorter when compared with what?
On my setup it's actually a bit longer, due to fact it sets a bunch of "LC_*" variables.
In Terminal.app:

Code: Select all

lucyfire:~ migun$ env | wc -l
      20
In NC's terminal:

Code: Select all

lucyfire:~ migun$ env | wc -l
      25
don wrote:
Sun Feb 05, 2017 10:28 am
Not sure where to start. May be PATH? NC uses its own - shorter version. Where could I set PATH for NC?
How does it inherit one?
Hmm, it uses the exact value of PATH provided by system:

Terminal.app:

Code: Select all

lucyfire:~ migun$ env | grep PATH
PATH=/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/Applications/Server.app/Contents/ServerRoot/usr/bin:/Applications/Server.app/Contents/ServerRoot/usr/sbin
NC:

Code: Select all

lucyfire:~ migun$ env | grep PATH
PATH=/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/Applications/Server.app/Contents/ServerRoot/usr/bin:/Applications/Server.app/Contents/ServerRoot/usr/sbin
don wrote:
Sun Feb 05, 2017 10:28 am
The other one is ATOM_DISABLE_SHELLING_OUT_FOR_ENVIRONMENT set to "true" when started through NC. Could I change it somehow?
Why not just set it globally on system or user level?

Post Reply