-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Show in local terminal should update PATH #93
Comments
From Terminal opened when creating the project (global node.js installed version): ~/development/eclipse/4.7.0_base/workspace/prueba$ node --version From Terminal opened when performing a "Run as" --> "ng build" (built in version): ~/development/eclipse/4.7.0_base/workspace/prueba$ node --version |
Tried to fix it, tell me if it's OK for you.
I know this problem. The problem is that TM terminal project doesn't provide an extension point kind to intialize PATH env before terminal is opened. Today PATH are initialized by the wizard which opens the terminal. Perhaps we could create our own |
~/development/eclipse/4.7.0_base/workspace/prueba$ node --version From Terminal opened when performing a "Run as" --> "ng build" (built in version): ~/development/eclipse/4.7.0_base/workspace/prueba$ node --version Yes it's normal, launch initialize PATH with embed dir. You can check the PATH variable once terminal is opened. |
Just installed again from http://oss.opensagres.fr/angular2-eclipse/1.3.0-SNAPSHOT/ but same result... On Terminal oppened to create the project: ~/development/eclipse/4.7.0_base/workspace/prueba$ node --version Could be network cache problem on my side or just not "really" fixed? |
Update site was not built. Please wait for that following job https://opensagres.ci.cloudbees.com/job/angular2-eclipse/311/ is finished. |
Now it work like a charm! Thanks @angelozerr !! NOTE:
I thinks It should be a good solution (as running a ng build is not so intuitive to open a new Terminal with the right PATH). NOTE2: And what about "reuse" existing (if that is the case) Terminal used for previous execution and not opening a new one? |
You don't like use launch to do An another idea is to provide ng build, tests, etc as children of the .angular-cli.json the project explorer like the scripts of package.json: Please create new issue if you like this idea.
It should work like this. If you redo a ng build, it should use the same terminal, no? |
No, I said that if I only want to open a terminal (but with the right PATHs set), It is not easy to guess that I must execute an ng command (using Eclipse). Other way, If y open a new Terminal, the PATH is not set.
Not exactly. I think that there should be one Terminal linked with one Angular Project. If there is currently a linked Terminal opened, reuse. If there is no one (never opened or just closed), create a new one and link with the project (for future re-use). I'll create a new issue for this. |
As there is now way to configure the Terminal, opened by "Show in Local Terminal", I guess it would be the best to provide a custom "Open in Terminal" for the plugins. |
New update on these. It seems that some of the latter changes broke the PATH setup as for now (when Run As --> ng build) It doesn't include current project "node_modules/.bin" directory in the PATH. Only ".metadata/.plugins/ts.eclipse.ide.server.nodejs.embed.linux.gtk.x86_64/node-v6.9.4-linux-x64/bin" is included before current PATH. Didn't notice the change till now that I closed all Terminal's and tried to open a new one. UPDATE!!:
|
If you:
Select project in Project Explorer ---> Right Click --> Show in local Terminal --> Terminal
the new terminal windows does not have PATH variable updated.
When creating an Angular Project, there is issued a command that sets the PATH environment variable to include node path (I think there is a bug here as, at least if you have configured embedded node.js, seems to include the path to node executable not to the bin directory that contains node executable an npm link -so for creating the project is using my global configured node.js, not the specified "embedded" one-) and project node_modules/.bin directory.
I think that, if possible, this setup should be issued "always" when opening a terminal for the project or, at least, provide a way to do it "alone" (as you can "force" an AngularCLI run that also opens a new terminal with the PATH updated -in this case the path includes the embedded node bin directory, not only the executable, which I think is the right way-).
The text was updated successfully, but these errors were encountered: