ctrl+shift+p filters: :st2 :st3 :win :osx :linux
Browse

Open​In​Browser

by bteryek ALL

On save opens up a user defined URL in your default web browser

Details

Installs

  • Total 36K
  • Win 25K
  • Mac 8K
  • Linux 4K
Jun 5 Jun 4 Jun 3 Jun 2 Jun 1 May 31 May 30 May 29 May 28 May 27 May 26 May 25 May 24 May 23 May 22 May 21 May 20 May 19 May 18 May 17 May 16 May 15 May 14 May 13 May 12 May 11 May 10 May 9 May 8 May 7 May 6 May 5 May 4 May 3 May 2 May 1 Apr 30 Apr 29 Apr 28 Apr 27 Apr 26 Apr 25 Apr 24 Apr 23 Apr 22
Windows 0 4 1 3 3 2 5 4 3 3 0 2 2 3 1 0 0 5 3 6 1 2 0 4 2 2 4 1 2 3 2 1 7 4 5 1 2 1 0 3 1 0 4 1 4
Mac 0 1 0 0 0 1 2 1 0 0 0 0 0 2 0 1 0 0 0 2 0 1 0 0 1 0 0 0 0 0 2 0 3 0 0 0 1 2 2 1 0 0 0 1 1
Linux 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 2 1 1 0 0 0 2 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 2 0 0 0 0 0

Readme

Source
bitbucket.​org

OpenInBrowser

On save opens up a user defined URL in your default web browser.

Introduction

There are several plugins out there that will refresh or open up a file in the browser. However, they are usually limited to opening open the file you are working on.

With OpenInBrowser, when you save a file, we scan your configuration settings and look for a match against the current file. If the file you saved matches the pattern you specified, OpenInBrowser will open up the associated url in your default web browser.

Configuration

The configuration file is an array of objects. Each object has a single key, which is the pattern to test the saved file against. The value is the associated url you want to open if the file is matched.

Each object is checked in the order they appear in the array. Once it finds a match, it will execute and open up the associated url.

[

    {"index.html": "http://idevelopsolutions.com"},
    {"index.(html|php)": "http://idevelopsolutions.com"},
    {"index.(html|php)": "http://idevelopsolutions.com/index.$1"}

]

Simple Match

{"index.html": "http://idevelopsolutions.com"}

If you are working on a file that matches the “index.html” pattern, it will open up http://idevelopsolutions.com

Regex Match

{"index.(html|php)": "http://idevelopsolutions.com"}

Files that match “index.html” or “index.php” will open up http://idevelopsolutions.com

Advanced Regex Match

If you want to use groups from the regex pattern in the url you wish to open, use $n syntax to backreference a group.

{"index.(html|php)": "http://idevelopsolutions.com/index.$1"}

Files that match index.html or index.php will open up

Install From Package Control

  1. Search for OpenInBrowser.

Install Manually:

  1. Create a folder in the packages directory called “OpenInBrowser”
  2. Download the latest tag, unzip and place the files in the “OpenInBrowser” directory.

Video Tutorial

http://www.youtube.com/watch?v=MCmIazjhq9A

Install Duplicate Tab Plugin for your Browser

It is highly recommended you install a duplicate tab plugin for your web browser if you do not want to keep opening up the same url(s) in new tabs.

I wrote a Chrome plugin that works with OpenInBrowser Plugin:

Check out my other plugin: