This package has been deprecated

Author message:

Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.

orangevolt-livereload

0.2.3 • Public • Published

Dependency status NPM version Bitdeli Badge

orangevolt-livereload lets you easily edit your Github wiki pages (aka Markdown / gfm files) in your favorite editor while having live preview in the browser.

orangevolt-livereload screencast

You dont need Gollum anymore - use your favorite editor. Just save the file and the browser reloads it automatically.

Features

Requirements

orangevolt-livereload requires Grunt.

Installation

$ npm install orangevolt-livereload -g

If you want to use orangevolt-livereload in your Grunt file you should install it locally (without -g option).

Usage

Command line

Go to your project directory and execute

$ orangevolt-livereload

A new browser window will appear displaying the contents of the directory.

Select the file to watch and you're done !

Grunt project integration

Add

watch : {
  all : {
    options: {
      livereload : 9091
    },
    files: [ 'README.md', /* add more files/directories to watch here */]
  }
},
connect : {
  all : {
    options : {
      port        : 9090,
      middleware  : require( 'orangevolt-livereload').grunt.livereload.middleware(),
      hostname    : '*',
      livereload  : 9091,
      directory   : __dirname
    }        
  }
}

to your grunt.initConfig( ...) section and

...
grunt.loadNpmTasks( 'grunt-contrib');
grunt.loadNpmTasks( 'grunt-open'); 

grunt.registerTask( 'livereload', ['connect', 'open', 'watch']);
...

to the bottom of your Grunt file. Execute

grunt livereload

and a new browser tab will appear. Select the file to watch and you're done !

See Gruntfile.js as a working example for the Grunt integration.

Caveats

When grunt aborts with Fatal error: watch ENOSPC message you're system is getting out of inotify watche handles.

Go to the terminal and enter

echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p

to increase inotify watche handles (See http://stackoverflow.com/questions/16748737/grunt-watch-error-waiting-fatal-error-watch-enospc).

License

orangevolt-livereload is dual licensed under

Package Sidebar

Install

npm i orangevolt-livereload

Weekly Downloads

0

Version

0.2.3

License

none

Last publish

Collaborators

  • lgersman