From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24103 invoked by alias); 14 Jul 2012 07:25:00 -0000 Received: (qmail 24093 invoked by uid 22791); 14 Jul 2012 07:24:58 -0000 X-SWARE-Spam-Status: No, hits=-3.7 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,KHOP_RCVD_TRUST,KHOP_THREADED,RCVD_IN_DNSWL_LOW,RCVD_IN_HOSTKARMA_YE X-Spam-Check-By: sourceware.org Received: from mail-qa0-f43.google.com (HELO mail-qa0-f43.google.com) (209.85.216.43) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sat, 14 Jul 2012 07:24:45 +0000 Received: by qadb33 with SMTP id b33so858676qad.2 for ; Sat, 14 Jul 2012 00:24:44 -0700 (PDT) MIME-Version: 1.0 Received: by 10.229.135.198 with SMTP id o6mr2151040qct.147.1342250684272; Sat, 14 Jul 2012 00:24:44 -0700 (PDT) Received: by 10.229.53.211 with HTTP; Sat, 14 Jul 2012 00:24:44 -0700 (PDT) In-Reply-To: <500020DA.5040008@cs.utoronto.ca> References: <50002053.4050706@cs.utoronto.ca> <500020DA.5040008@cs.utoronto.ca> Date: Sat, 14 Jul 2012 07:25:00 -0000 Message-ID: Subject: Re: Open URLs with # using cygstart.exe From: Dima Pasechnik To: cygwin@cygwin.com, Alexander Konovalov Content-Type: text/plain; charset=UTF-8 X-IsSubscribed: yes Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com X-SW-Source: 2012-07/txt/msg00297.txt.bz2 Alex, On 13 July 2012 21:21, Ryan Johnson wrote: > On 13/07/2012 9:19 AM, Ryan Johnson wrote: >> >> Cygstart does not actually parse general URIs. For a long time it had a >> special case that tested explicitly for `http:', and recently added >> `mailto:' after a similar issue arose [1]. Ironically, most URIs seem to >> work precisely because cygstart *doesn't* know what to do with them and >> passes them along as-is, giving Windows a chance to do the right thing. > > Actually, you can probably ignore this and go with what Adam posted... At least you can use cygwin do find out the default browser to launch $ cat /proc/registry/HKEY_CURRENT_USER/Software/Classes/http/shell/open/command/@ "C:\Program Files\Mozilla Firefox\firefox.exe" -requestPending -osint -url "%1" $ You can use this info to create a script that would launch the browser with the argument file:///C:/somepath/doc/ref/chap31.htm#X84F59A2687C62763 (note that you might need to rename the files from .html to .htm) It should be doable, as at Windows command prompt the following works: C:\>"C:\Program Files\Mozilla Firefox\firefox.exe" file://C:/tmp/chap39.htm#X79C44528864044C5 HTH, Dima -- 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