ceylon / ceylon-common

DEPRECATED
Apache License 2.0
14 stars 9 forks source link

Tools accepting URIs don't handle Windows paths correctly #34

Closed quintesse closed 11 years ago

quintesse commented 11 years ago

They only accept POSIX style paths and not Windows style paths.

tombentley commented 11 years ago

Well, that's because a windows path is not a URI.

FroMage commented 11 years ago

Can we have more specific examples?

tombentley commented 11 years ago

Should be a simple hack in StandardArgumentParsers.

tombentley commented 11 years ago

Though, looking at it we already have such a hack in there...?

quintesse commented 11 years ago

I made it a bit more hackish.

The hack that is in place turns paths like "foo/bar" into "file://C|some/absolute/path/foo/bar" which is not what we want because the CMR only understand file paths or remote repository URLs (of the form "http://", "mvn:" etc, not "file://")

A nicer solution might be to introduce our own PathOrURI class that encapsulates this behaviour, but for now this works.