diff --git a/DanTup.BrowserSelector/Program.cs b/DanTup.BrowserSelector/Program.cs index cad10b1..ed16c41 100644 --- a/DanTup.BrowserSelector/Program.cs +++ b/DanTup.BrowserSelector/Program.cs @@ -230,7 +230,7 @@ static void LaunchBrowser(string url, bool waitForClose = false) if (urlPattern.StartsWith("/") && urlPattern.EndsWith("/")) { // The domain from the INI file is a regex.. - domain = uri.Authority + uri.AbsolutePath; + domain = uri.Authority + uri.PathAndQuery; pattern = urlPattern.Substring(1, urlPattern.Length - 2); } else diff --git a/README.md b/README.md index 3493ed1..5d9580d 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ -> NOTE: This software is not being actively developed or maintained. +> NOTE: This is a clone of [DanTup/BrowserSelector](https://github.com/DanTup/BrowserSelector) enhanced by comparing the full URI (including query part) against a regex pattern. -# Browser Selector [![Build status](https://ci.appveyor.com/api/projects/status/github/DanTup/BrowserSelector?svg=true)](https://ci.appveyor.com/project/DanTup/browserselector) +# Browser Selector [![Build status](https://ci.appveyor.com/api/projects/status/github/pstodulka/BrowserSelector?svg=true)](https://ci.appveyor.com/project/pstodulka/browserselector) Small utility to launch a different browser depending on the domain of the url being launched. @@ -8,7 +8,7 @@ Small utility to launch a different browser depending on the domain of the url b ## Setting Up -1. Grab the [latest release](https://github.com/DanTup/BrowserSelector/releases) and extract to a folder somewhere on your PC. +1. Grab the [latest release](https://github.com/pstodulka/BrowserSelector/releases) and extract to a folder somewhere on your PC. 2. Open the BrowserSelector.ini file and customise paths to your browsers and domain patterns (see below). 3. Run `BrowserSelector.exe --register` from this folder to register the tool in Windows as a web browser. 4. Open the "Choose a default browser" screen in Windows (you can simply search for "default browser" from the start screen). @@ -121,5 +121,5 @@ There are two ways to specify an Url. You can use simple wildcards or full regul ``` - Full regular expressions are specified by wrapping it in /'s. -- The domain _and_ path are used in the Url comparison. +- The domain _and_ path _and_ query are used in the Url comparison. - The regular expression syntax is based on the Microsoft .NET implementation.