Skip to content
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

Cannot install angular-cli on Windows when Cygwin-Git is installed #2394

Closed
GregOnNet opened this issue Sep 28, 2016 · 5 comments · May be fixed by goorockey/angular-cli#56
Closed

Cannot install angular-cli on Windows when Cygwin-Git is installed #2394

GregOnNet opened this issue Sep 28, 2016 · 5 comments · May be fixed by goorockey/angular-cli#56

Comments

@GregOnNet
Copy link

GregOnNet commented Sep 28, 2016

Please provide us with the following information:

  1. OS? Windows 7, 8 or 10. Linux (which distribution). Mac OSX (Yosemite? El Capitan?)

    Windows 10 Cygwin
    
  2. Versions. Please run ng --version. If there's nothing outputted, please run
    in a Terminal: node --version and paste the result here:

    angular-cli: 1.0.0-beta.16
    node: 6.7.0
    os: win32 x64
    
  3. Repro steps. Was this an app that wasn't created using the CLI? What change did you
    do on your code? etc.
    Installing angular-cli using cygwin-git

    npm install angular-cli
  4. The log given by the failure. Normally this include a stack trace and some
    more information.

    npm-debug.txt

  5. Mention any other details that might be useful.

    Hey guys,

    every Windows user using Git installed via cygwin cannot install angular-cli right now.

    The problem is that a github-repository is referenced as dependency in package.json: see package.json

    When npm runs git the windows path of the cloned repository cannot be resolved because cygwin uses POSIX formatted paths.

6.Idea to get around the problem

Do you think it would be possible to release angular-cli only when all dependencies are packages hosted on npmjs.org?

Thanks in advance
Greg

@eight-molecules
Copy link
Contributor

eight-molecules commented Sep 28, 2016

It doesn't seem like this is really an issue. The linked repo is the newest version of a package that is currently on NPM, just out of date. It should be pulled in as a regular dependency as soon as the NPM version is at 0.3.2, up from 0.3.1.

To address your choice of Git software: The CLI team can't support every implementation, and Git has an official Windows binary out. Why would they fix something that honestly seems more like a Cygwin bug than a CLI or NPM bug?

@GregOnNet
Copy link
Author

Hi,

I agree that the issue is not directly related to angular-cli.
On the other hand why making an exception for compression-webpack-plugin when all other packages are referenced "directly".

I just want to make aware of this problem, because some users will run into it.

As I mentioned in the description: Referencing a npm-dependency pointing to a Git-Repository makes npm using Git.
Installing the dependencies having Git installed via cygwin causes the problem that the windows-path to the cloned repository cannot be resolved (conflict: POSIX- <-> Win32-Path).

That's why I asked for making releases only with npmjs.org hostet packages.
That would fix the problem.

Of cause @gelliott181 you are right, saying there is nothing to fix.

@eight-molecules
Copy link
Contributor

eight-molecules commented Sep 28, 2016

Here's the PR you'll want to check out for clarity: #2365

What happened was the node-zopfli in the dep at v0.3.1 (Current NPM) broke every Windows build (You'd still be SOL without it). To fix this the dep was moved up to the unreleased version which takes care of the node-zopfli issue, but clearly causes your issue when using Cygwin. Once the new version of the compression plugin makes it onto NPM this will be fixed, but I truly think you should open up a bug with the Cygwin team detailing the problem. It will affect every NPM package that pulls from a GitHub repo, and that's not good for the Cygwin project as a whole when it comes to JS.

EDIT: Also, I really really hate beating a dead horse, but the Angular2 project clearly states you need Git proper (From Git-SCM) or the Github app (https://github.com/angular/angular/blob/master/DEVELOPER.md) to install Angular2. This pushes the Cygwin problem way out of the scope of the Angular team.

@GregOnNet
Copy link
Author

@gelliott181 Thanks having a deeper look.

The issue is more related to the decission of the team behind npm to not support Cygwin: npm/npm#2465

I will now close this issue because we provided enough information for users having the same trouble like me.

The workaround I used is to download the Git for Windows Binary and temporarily use it with npm install

Thanks

@angular-automatic-lock-bot
Copy link

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.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 6, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants