Details:
OS?
Windows 7, 8 or 10. Linux (which distribution). Mac OSX (Yosemite? El Capitan?)
Windows 7 Enterprise / 64 bitVersions.
Please run
ng --version. If there's nothing outputted, please run in a Terminal:node --versionand paste the result here:
node: v6.7.0
npm : 3.10.8
git: 2.10.1.Windows.1Repro steps.
Was this an app that wasn't created using the CLI? What change did you do on your code? etc.
- I have a project successfully running locally: Angular2 / Typescript / npm
- I did setup proxy for npm using command, so so npm install for other packages work fine
- Now to deploy I wanted to use angular-cli
- tried command: npm install -g angular-cli and got bunch of errors
- I thought may be angular-cli is not able to get webpack, so ran command npm install -g webpack and it worked fine
- I googles and lot of ppl said, its because of proxy, so ran following:
set HTTP_PROXY=http://[proxy user name]:[URL encoded password]@[proxy server]:[proxy port]set HTTPS_PROXY=%HTTP_PROXY% setx HTTP_PROXY %HTTP_PROXY% setx HTTPS_PROXY %HTTP_PROXY% npm config set proxy %HTTP_PROXY% npm config set https-proxy %HTTP_PROXY% npm config set strict-ssl false npm set registry https://registry.npmjs.org/ git config --global https.proxy %HTTP_PROXY% git config --global http.proxy %HTTP_PROXY% git config --global url."https://".insteadOf git:// git config --global url."https://github.com/".insteadOf [email protected]
### The log given by the failure.
c:\work\projects\gitRepo\AngularProjects\angular2-click>npm install -g angular-cli
npm WARN addRemoteGit Error: Command failed: git -c core.longpaths=true config --get remote.origin.url
npm WARN addRemoteGit
npm WARN addRemoteGit at ChildProcess.exithandler (child_process.js:206:12)
npm WARN addRemoteGit at emitTwo (events.js:106:13)
npm WARN addRemoteGit at ChildProcess.emit (events.js:191:7)
npm WARN addRemoteGit at maybeClose (internal/child_process.js:877:16)
npm WARN addRemoteGit at Socket.<anonymous> (internal/child_process.js:334:11)
npm WARN addRemoteGit at emitOne (events.js:96:13)
npm WARN addRemoteGit at Socket.emit (events.js:188:7)
npm WARN addRemoteGit at Pipe._handle.close [as _onclose] (net.js:493:12)
npm WARN addRemoteGit webpack/compression-webpack-plugin#7e55907cd54a2e91b96d25a660acc6a2a6453f54 resetting remote C:\Users\sd40040\AppData\Roaming\npm-cache
\_git-remotes\git-github-com-webpack-compression-webpack-plugin-git-7e55907cd54a2e91b96d25a660acc6a2a6453f54-ec76b2fe because of error: { Error: Command faile
d: git -c core.longpaths=true config --get remote.origin.url
npm WARN addRemoteGit
npm WARN addRemoteGit at ChildProcess.exithandler (child_process.js:206:12)
npm WARN addRemoteGit at emitTwo (events.js:106:13)
npm WARN addRemoteGit at ChildProcess.emit (events.js:191:7)
npm WARN addRemoteGit at maybeClose (internal/child_process.js:877:16)
npm WARN addRemoteGit at Socket.<anonymous> (internal/child_process.js:334:11)
npm WARN addRemoteGit at emitOne (events.js:96:13)
npm WARN addRemoteGit at Socket.emit (events.js:188:7)
npm WARN addRemoteGit at Pipe._handle.close [as _onclose] (net.js:493:12)
npm WARN addRemoteGit killed: false,
npm WARN addRemoteGit code: 1,
npm WARN addRemoteGit signal: null,
npm WARN addRemoteGit cmd: 'git -c core.longpaths=true config --get remote.origin.url' }
npm ERR! git clone --template=C:\Users\sd40040\AppData\Roaming\npm-cache\_git-remotes\_templates --mirror git://github.com/webpack/compression-webpack-plugin.
git C:\Users\sd40040\AppData\Roaming\npm-cache\_git-remotes\git-github-com-webpack-compression-webpack-plugin-git-7e55907cd54a2e91b96d25a660acc6a2a6453f54-ec7
6b2fe: Cloning into bare repository 'C:\Users\sd40040\AppData\Roaming\npm-cache\_git-remotes\git-github-com-webpack-compression-webpack-plugin-git-7e55907cd54
a2e91b96d25a660acc6a2a6453f54-ec76b2fe'...
npm ERR! git clone --template=C:\Users\sd40040\AppData\Roaming\npm-cache\_git-remotes\_templates --mirror git://github.com/webpack/compression-webpack-plugin.
git C:\Users\sd40040\AppData\Roaming\npm-cache\_git-remotes\git-github-com-webpack-compression-webpack-plugin-git-7e55907cd54a2e91b96d25a660acc6a2a6453f54-ec7
6b2fe: fatal: unable to access 'https://github.com/webpack/compression-webpack-plugin.git/': SSL certificate problem: self signed certificate in certificate chain
> ---------------------------------------------------------------
Sometimes the proxy login doesn't work well, and you need a proxy that does not need login. Many people use something called CNTLM for that (you set it as proxy, and enter the real proxy details inside it).
This happens when downloading one of the packages via git not npm registry, which is now changed (as of https://github.com/angular/angular-cli/pull/2709), but the change isn't released yet (will be part of beta-18, since it's in repo already). So, this issue is fixed already and can be closed.
But until beta-18 comes out, the fastest way would be to install from a network that doesn't require the proxy if this is possible.
At home for example of this a laptop. At my current customer they have a "Guest" network that cannot access email or anything but doesn't require the proxy, so some developers switch to it to install stuff and go to main network after done.
Another workaround is to fiddle with CNTLM as the proxy, or something similar.
Thanks for the reply Meligy, I have proxy that does not require login.
As I work for a bank, everything is very secure for the right reasons, so I can not download without proxy or run it using home network.
Seems like I'll have to wait for beta-18, I'll use some other tool (than cli) for now for my lil POC; unless somebody else here gives any other solution.
Thanks again.
Someone have any idea for the beta 18 release date?
@skdhir beta.18 was released with https://github.com/angular/angular-cli/pull/2709, which fixes this issue.
@filipesilva and @Meligy ...
Thanks for the replies but I'm lil confused.
So GIT beta 18 is released already? I couldn't find link to download beta 18, can you please post teh link here.
Thanks in Advance and Sorry for posting this on Sunday night.
https://git-scm.com/download/win says last release was 19 days ago.
after re-reading all teh messages several times, I understand it was fixed as part of #2709, but until and unless users are not able to download that version and test it, I think closing pre-release is little too early.
Appropriate status should be released to QA / Waiting for Prod-release or something similar.
@skdhir https://github.com/angular/angular-cli/pull/2709 was released in beta.18 of angular-cli, which is out now.
oh ok, my bad; I was under impression that I need newer git.
BTW I was able to install angular-cli now
Thanks again.
This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.
Read more about our automatic conversation locking policy.
_This action has been performed automatically by a bot._