public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* cygstart.exe can't open file:///C:/
@ 2016-07-03 23:51 Gene Pavlovsky
  2016-07-04  1:10 ` Juan Miguel Navarro Martínez
  0 siblings, 1 reply; 9+ messages in thread
From: Gene Pavlovsky @ 2016-07-03 23:51 UTC (permalink / raw)
  To: cygwin

cygstart‘s manpage says it’s similar to the Windows command-line start command.
It is indeed able to open http://example.com in the default browser.
However, cygstart file:///C:/ results in an error message:
Unable to start 'C:\cygwin\c\': The specified file was not found.
The Windows start command opens file:///C:/ links in the default
browser without a hitch.

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: cygstart.exe can't open file:///C:/
  2016-07-03 23:51 cygstart.exe can't open file:///C:/ Gene Pavlovsky
@ 2016-07-04  1:10 ` Juan Miguel Navarro Martínez
  2016-07-05 15:09   ` Gene Pavlovsky
  0 siblings, 1 reply; 9+ messages in thread
From: Juan Miguel Navarro Martínez @ 2016-07-04  1:10 UTC (permalink / raw)
  To: cygwin

Even if it's similar to Windows command-line, you are still in a POSIX
system, and Cygwin use /cygdrive/ for all the drive letters.

So for file:///C:/ you should use file:///cygdrive/c/

On 2016-07-04 at 01:51, Gene Pavlovsky wrote:
> cygstart‘s manpage says it’s similar to the Windows command-line start command.
> It is indeed able to open http://example.com in the default browser.
> However, cygstart file:///C:/ results in an error message:
> Unable to start 'C:\cygwin\c\': The specified file was not found.
> The Windows start command opens file:///C:/ links in the default
> browser without a hitch.
> 
> --
> Problem reports:       http://cygwin.com/problems.html
> FAQ:                   http://cygwin.com/faq/
> Documentation:         http://cygwin.com/docs.html
> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
> 

-- 
Juan Miguel Navarro Martínez

GPG Keyfingerprint:
5A91 90D4 CF27 9D52 D62A
BC58 88E2 947F 9BC6 B3CF

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: cygstart.exe can't open file:///C:/
  2016-07-04  1:10 ` Juan Miguel Navarro Martínez
@ 2016-07-05 15:09   ` Gene Pavlovsky
  2016-07-05 18:10     ` Brian Inglis
  0 siblings, 1 reply; 9+ messages in thread
From: Gene Pavlovsky @ 2016-07-05 15:09 UTC (permalink / raw)
  To: cygwin

Juan, thanks for this, it does work. (on my system I setup `cygdrive`
to be `/mnt` using fstab, though).
But I think the C:/ syntax should be supported as well. After all, `ls
C:/` works correctly on Cygwin.
Don't you think?

On 4 July 2016 at 04:10, Juan Miguel Navarro Martínez
<juanmi.3000@gmail.com> wrote:
> Even if it's similar to Windows command-line, you are still in a POSIX
> system, and Cygwin use /cygdrive/ for all the drive letters.
>
> So for file:///C:/ you should use file:///cygdrive/c/
>
> On 2016-07-04 at 01:51, Gene Pavlovsky wrote:
>> cygstart‘s manpage says it’s similar to the Windows command-line start command.
>> It is indeed able to open http://example.com in the default browser.
>> However, cygstart file:///C:/ results in an error message:
>> Unable to start 'C:\cygwin\c\': The specified file was not found.
>> The Windows start command opens file:///C:/ links in the default
>> browser without a hitch.
>>
>> --
>> Problem reports:       http://cygwin.com/problems.html
>> FAQ:                   http://cygwin.com/faq/
>> Documentation:         http://cygwin.com/docs.html
>> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
>>
>
> --
> Juan Miguel Navarro Martínez
>
> GPG Keyfingerprint:
> 5A91 90D4 CF27 9D52 D62A
> BC58 88E2 947F 9BC6 B3CF
>
> --
> Problem reports:       http://cygwin.com/problems.html
> FAQ:                   http://cygwin.com/faq/
> Documentation:         http://cygwin.com/docs.html
> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
>

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: cygstart.exe can't open file:///C:/
  2016-07-05 15:09   ` Gene Pavlovsky
@ 2016-07-05 18:10     ` Brian Inglis
  2016-07-06  1:56       ` Warren Young
  2016-07-07 14:35       ` Andrey Repin
  0 siblings, 2 replies; 9+ messages in thread
From: Brian Inglis @ 2016-07-05 18:10 UTC (permalink / raw)
  To: cygwin

Gene Pavlovsky <gene.pavlovsky <at> gmail.com> writes:
> On 4 July 2016 at 04:10, Juan Miguel Navarro Martínez <juanmi.3000 <at>
gmail.com> wrote:
>> On 2016-07-04 at 01:51, Gene Pavlovsky wrote:
>>> cygstart‘s manpage says it’s similar to the Windows command-line start
command.
>>> However, cygstart file:///C:/ results in an error message:
 Unable to start 'C:\cygwin\c\': The specified file was not found.
>>> The Windows start command opens file:///C:/ links in the default browser
without a hitch.

> Juan, thanks for this, it does work. (on my system I setup `cygdrive` to
be `/mnt` using fstab, though).
> But I think the C:/ syntax should be supported as well. After all, `ls
C:/` works correctly on Cygwin.

cygstart file://C:/ works - read the MS DN and MS KB articles on file URIs
and shlwapi

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: cygstart.exe can't open file:///C:/
  2016-07-05 18:10     ` Brian Inglis
@ 2016-07-06  1:56       ` Warren Young
  2016-07-07 14:35       ` Andrey Repin
  1 sibling, 0 replies; 9+ messages in thread
From: Warren Young @ 2016-07-06  1:56 UTC (permalink / raw)
  To: The Cygwin Mailing List

On Jul 5, 2016, at 12:10 PM, Brian Inglis <Brian.Inglis@SystematicSw.ab.ca> wrote:
> 
> cygstart file://C:/ works

Right.  The extra leading slash is causing the POSIX to DOS command conversion to effectively give you $(cygpath -m /c:/) rather than what you expected, which was $(cygpath -m c:/)

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: cygstart.exe can't open file:///C:/
  2016-07-05 18:10     ` Brian Inglis
  2016-07-06  1:56       ` Warren Young
@ 2016-07-07 14:35       ` Andrey Repin
  2016-07-07 17:01         ` Brian Inglis
  1 sibling, 1 reply; 9+ messages in thread
From: Andrey Repin @ 2016-07-07 14:35 UTC (permalink / raw)
  To: Brian Inglis, cygwin

Greetings, Brian Inglis!

> Gene Pavlovsky <gene.pavlovsky <at> gmail.com> writes:
>> On 4 July 2016 at 04:10, Juan Miguel Navarro Martínez wrote:
>>> On 2016-07-04 at 01:51, Gene Pavlovsky wrote:
>>>> cygstart‘s manpage says it’s similar to the Windows command-line start command.
>>>> However, cygstart file:///C:/ results in an error message:  Unable to
>>>> start 'C:\cygwin\c\': The specified file was not found.
>>>> The Windows start command opens file:///C:/ links in the default browser
>>>> without a hitch.

>> Juan, thanks for this, it does work. (on my system I setup `cygdrive` to be
>> `/mnt` using fstab, though).
>> But I think the C:/ syntax should be supported as well. After all, `ls C:/`
>> works correctly on Cygwin.

> cygstart file://C:/ works - read the MS DN and MS KB articles on file URIs
> and shlwapi

Which isn't quite right. "file:" is a protocol, "//" is the foreign host mark,
"[.]/" is "current host's filesystem root".
So, I guess, the CORRECT solution (or, rather, workaround) would be an
explicit "." in host name.

cygstart "file://./C:/"

Works here. Please try it yourself.


-- 
With best regards,
Andrey Repin
Thursday, July 7, 2016 17:29:00

Sorry for my terrible english...

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: cygstart.exe can't open file:///C:/
  2016-07-07 14:35       ` Andrey Repin
@ 2016-07-07 17:01         ` Brian Inglis
  2016-07-07 17:50           ` Andrey Repin
  0 siblings, 1 reply; 9+ messages in thread
From: Brian Inglis @ 2016-07-07 17:01 UTC (permalink / raw)
  To: cygwin

Andrey Repin writes:
>Brian Inglis writes:
>> cygstart file://C:/ works - read the MS DN and MS KB articles on file URIs
>> and shlwapi
> Which isn't quite right. "file:" is a protocol, "//" is the foreign host
mark, "[.]/" is "current host's filesystem root".
> So, I guess, the CORRECT solution (or, rather, workaround) would be an
explicit "." in host name.
> cygstart "file://./C:/"
> Works here. Please try it yourself.

MS approach makes some sense, as the RFCs e.g. 3986 define what you call the
the "host" as the namespace authority. In Unix systems, you have only one
unified local namespace (even though the mounted filesystems can have
radically different namespace rules e.g. fat, ufs, ext?, and the RFCs state
the authority may be delegated, so the rules can change along the path),
whereas on Windows, each device represents (possibly virtual e.g. subst)
separate filesystem namespaces. 

Where MS approach makes no sense, is that . is a (MS) kludge which works,
but other local synonyms: null/nothing, localhost, 127.0.0.1, [::1] do not,
whereas $BROWSER file://{,.,localhost,127.0.0.1,::1}/C{:,\|} displays
identical contents, differing only in whether a : or | follows the drive
letter in the address for each tab. 

I dealt with a Windows product where file: (but not ftp, http, or https) had
to have an initial cap File: to work. The vendor accepted a bug report but
made it a doc issue rather than doing a non-compliance fix. The company
and/or products were traded annually  like an end of career player! 


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: cygstart.exe can't open file:///C:/
  2016-07-07 17:01         ` Brian Inglis
@ 2016-07-07 17:50           ` Andrey Repin
  2016-07-08 17:18             ` Gene Pavlovsky
  0 siblings, 1 reply; 9+ messages in thread
From: Andrey Repin @ 2016-07-07 17:50 UTC (permalink / raw)
  To: Brian Inglis, cygwin

Greetings, Brian Inglis!

> Andrey Repin writes:
>>Brian Inglis writes:
>>> cygstart file://C:/ works - read the MS DN and MS KB articles on file URIs
>>> and shlwapi
>> Which isn't quite right. "file:" is a protocol, "//" is the foreign host
> mark, "[.]/" is "current host's filesystem root".
>> So, I guess, the CORRECT solution (or, rather, workaround) would be an
> explicit "." in host name.
>> cygstart "file://./C:/"
>> Works here. Please try it yourself.

> MS approach makes some sense, as the RFCs e.g. 3986 define what you call the
> the "host" as the namespace authority. In Unix systems, you have only one
> unified local namespace (even though the mounted filesystems can have
> radically different namespace rules e.g. fat, ufs, ext?, and the RFCs state
> the authority may be delegated, so the rules can change along the path),
> whereas on Windows, each device represents (possibly virtual e.g. subst)
> separate filesystem namespaces. 

> Where MS approach makes no sense, is that . is a (MS) kludge which works,
> but other local synonyms: null/nothing, localhost, 127.0.0.1, [::1] do not,
> whereas $BROWSER file://{,.,localhost,127.0.0.1,::1}/C{:,\|} displays
> identical contents, differing only in whether a : or | follows the drive
> letter in the address for each tab. 

file://localhost/C:/ works, at least for CMD call. Not for cygstart, though.
Using IP, of course, does not, which, again, makes sense.
Browsers, on the other hand, often have their own protocol translation, so you
can't quite compare their behavior to native API calls.

> I dealt with a Windows product where file: (but not ftp, http, or https) had
> to have an initial cap File: to work. The vendor accepted a bug report but
> made it a doc issue rather than doing a non-compliance fix. The company
> and/or products were traded annually  like an end of career player! 

*sigh*


-- 
With best regards,
Andrey Repin
Thursday, July 7, 2016 20:38:24

Sorry for my terrible english...


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: cygstart.exe can't open file:///C:/
  2016-07-07 17:50           ` Andrey Repin
@ 2016-07-08 17:18             ` Gene Pavlovsky
  0 siblings, 0 replies; 9+ messages in thread
From: Gene Pavlovsky @ 2016-07-08 17:18 UTC (permalink / raw)
  To: cygwin

Thanks for clarification, guys! Indeed it was my bad for including
customary three forward slashes. Both file://C:/ and file://./C:/ do
work with cygstart.
Appreciate the help.

On 7 July 2016 at 20:43, Andrey Repin <anrdaemon@yandex.ru> wrote:
> Greetings, Brian Inglis!
>
>> Andrey Repin writes:
>>>Brian Inglis writes:
>>>> cygstart file://C:/ works - read the MS DN and MS KB articles on file URIs
>>>> and shlwapi
>>> Which isn't quite right. "file:" is a protocol, "//" is the foreign host
>> mark, "[.]/" is "current host's filesystem root".
>>> So, I guess, the CORRECT solution (or, rather, workaround) would be an
>> explicit "." in host name.
>>> cygstart "file://./C:/"
>>> Works here. Please try it yourself.
>
>> MS approach makes some sense, as the RFCs e.g. 3986 define what you call the
>> the "host" as the namespace authority. In Unix systems, you have only one
>> unified local namespace (even though the mounted filesystems can have
>> radically different namespace rules e.g. fat, ufs, ext?, and the RFCs state
>> the authority may be delegated, so the rules can change along the path),
>> whereas on Windows, each device represents (possibly virtual e.g. subst)
>> separate filesystem namespaces.
>
>> Where MS approach makes no sense, is that . is a (MS) kludge which works,
>> but other local synonyms: null/nothing, localhost, 127.0.0.1, [::1] do not,
>> whereas $BROWSER file://{,.,localhost,127.0.0.1,::1}/C{:,\|} displays
>> identical contents, differing only in whether a : or | follows the drive
>> letter in the address for each tab.
>
> file://localhost/C:/ works, at least for CMD call. Not for cygstart, though.
> Using IP, of course, does not, which, again, makes sense.
> Browsers, on the other hand, often have their own protocol translation, so you
> can't quite compare their behavior to native API calls.
>
>> I dealt with a Windows product where file: (but not ftp, http, or https) had
>> to have an initial cap File: to work. The vendor accepted a bug report but
>> made it a doc issue rather than doing a non-compliance fix. The company
>> and/or products were traded annually  like an end of career player!
>
> *sigh*
>
>
> --
> With best regards,
> Andrey Repin
> Thursday, July 7, 2016 20:38:24
>
> Sorry for my terrible english...
>
>
> --
> Problem reports:       http://cygwin.com/problems.html
> FAQ:                   http://cygwin.com/faq/
> Documentation:         http://cygwin.com/docs.html
> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
>

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2016-07-08 17:18 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-07-03 23:51 cygstart.exe can't open file:///C:/ Gene Pavlovsky
2016-07-04  1:10 ` Juan Miguel Navarro Martínez
2016-07-05 15:09   ` Gene Pavlovsky
2016-07-05 18:10     ` Brian Inglis
2016-07-06  1:56       ` Warren Young
2016-07-07 14:35       ` Andrey Repin
2016-07-07 17:01         ` Brian Inglis
2016-07-07 17:50           ` Andrey Repin
2016-07-08 17:18             ` Gene Pavlovsky

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).