Skip to content

msys / cygwin support for pub #20822

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

Closed
DartBot opened this issue Sep 5, 2014 · 10 comments
Closed

msys / cygwin support for pub #20822

DartBot opened this issue Sep 5, 2014 · 10 comments
Labels
closed-not-planned Closed as we don't intend to take action on the reported issue type-enhancement A request for a change that isn't a bug

Comments

@DartBot
Copy link

DartBot commented Sep 5, 2014

This issue was originally filed by @MetaMemoryT


pub should support being ran on a cygwin terminal more easily.

npm "Node Package Manager" supports this by adding a "npm" shell script to the windows distribution that cygwin terminals can execute:

file npm:

'''

!/bin/sh

basedir=dirname "$0"

case uname in
    CYGWIN) basedir=cygpath -w "$basedir";;
esac

if [ -x "$basedir/node.exe" ]; then
  "$basedir/node.exe" "$basedir/node_modules/npm/bin/npm-cli.js" "$@"
else
  node "$basedir/node_modules/npm/bin/npm-cli.js" "$@"
fi
'''

@sethladd
Copy link
Contributor

sethladd commented Sep 8, 2014

Added Area-Pub, Triaged labels.

@DartBot
Copy link
Author

DartBot commented Oct 2, 2014

This comment was originally written by @seaneagan


This is also an issue with the new package executables implemented in issue #18539, they have to be called with my_executable.bat which also means they don't work with cygwin's tab completion.

The equivalent feature in npm does not have this issue.

Npm's generated "binstubs" for package executables look almost exactly like the npm shell script embedded above:

'''
#!/bin/sh
basedir=dirname "$0"

case uname in
    CYGWIN) basedir=cygpath -w "$basedir";;
esac

if [ -x "$basedir/node" ]; then
  "$basedir/node" "$basedir/node_modules/grunt-cli/bin/grunt" "$@"
  ret=$?
else
  node "$basedir/node_modules/grunt-cli/bin/grunt" "$@"
  ret=$?
fi
exit $ret
'''

@DartBot
Copy link
Author

DartBot commented Dec 15, 2014

This comment was originally written by @seaneagan


This also affects these executables:

dartfmt
dartanalyzer
dart2js

So not necessarily Area-Pub

@DartBot
Copy link
Author

DartBot commented Mar 27, 2015

This comment was originally written by @seaneagan


It would be nice to run the same build script from from travis-ci.org (linux, osx) and appveyor.com (windows), which could be done via the use of cygwin.

Appveyor has an image with cygwin preinstalled:

  http://help.appveyor.com/discussions/suggestions/427-pre-install-cygwin

However, due to this issue no pub commands, or pub global activated executables could be called from such a bash script.

For projects that use a task runner like grinder (https://github.com/google/grinder.dart) for their build, that can take care of most of the platform abstraction, but not all, and not all projects will use a task runner.

@nex3
Copy link
Member

nex3 commented Mar 27, 2015

Cygwin is not currently a supported platform for Dart. This means that we aren't going to allocate any resources towards it, including engineering time or test coverage. You're welcome to submit patches to improve support, but bear in mind that since they won't be tested, we can't guarantee that we won't break them in the future.


Added NotPlanned label.

@DartBot
Copy link
Author

DartBot commented Mar 27, 2015

This comment was originally written by @seaneagan


Ugh, this makes dart really painful to use from a windows machine. Using a standard windows shell like CMD might be bearable if at least color were supported (issue #21337).

@DartBot
Copy link
Author

DartBot commented Mar 27, 2015

This comment was originally written by @seaneagan


Thanks for the update though, I may take a crack at it after the move to github.

@MetaMemoryT
Copy link

Should this issue be re-opened? was it fixed, or did the DartBot close it when it moved it here?

@nex3
Copy link
Member

nex3 commented Jun 4, 2015

This isn't planned. See my comment above.

@DartBot
Copy link
Author

DartBot commented Jun 5, 2015

This issue has been moved to dart-lang/pub#1120.

@kevmoo kevmoo added type-enhancement A request for a change that isn't a bug and removed priority-unassigned labels Mar 1, 2016
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
closed-not-planned Closed as we don't intend to take action on the reported issue type-enhancement A request for a change that isn't a bug
Projects
None yet
Development

No branches or pull requests

5 participants