dwb / atom-xterm

Open terminal tabs in Atom. Fork of term3 and all who went before.
Other
9 stars 2 forks source link

Electron can't run in xTerm #6

Open antonbrams opened 7 years ago

antonbrams commented 7 years ago

Hi, if i try to run Electron, the require('electron') part instead of a module returns just a path, where this module is stored. Is it possible to fix? Thanks!

dwb commented 7 years ago

I'm sorry, I don't really understand what you mean. Can you detail the steps to reproduce this please?

antonbrams commented 6 years ago

take a look at this issue please https://github.com/electron/electron/issues/8200

CaptainBeyondDS8 commented 6 years ago

Hi,

I ran into this issue recently and would like to share my workaround for it. It's not possible to run an Electron app from inside another Electron app (Atom). The workaround for me is to unset ELECTRON_RUN_AS_NODE before running the child Electron process in the terminal, either with unset ELECTRON_RUN_AS_NODE or by prepending ELECTRON_RUN_AS_NODE= (blank value) to the command to launch the Electron process

It would be possible for atom-xterm to strip this variable out automatically, but whether it's really appropriate of atom-xterm to do so is, to me, an open question - although I do notice it already does so with NODE_ENV (which was an issue for me with term3).