Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Update README to show proxy usage.

  • Loading branch information...
commit f709084f464db202b9ce2895d9b9a3e74e3252b2 1 parent a1346f0
@omphalos authored
Showing with 18 additions and 17 deletions.
  1. +16 −15 README.markdown
  2. +1 −1  package.json
  3. +1 −1  universal-reloader.js
View
31 README.markdown
@@ -1,15 +1,15 @@
Universal Reloader
==================
-Universal reloader is a simple command line tool that refreshes your browser window when you change a file.
+Universal reloader is a command line tool that refreshes your browser window when you change a file.
Why use it?
===========
-This tools aims to be *super simple* and *compatible* with almost anything.
+This tools aims to be *simple to use* and *compatible* with almost anything.
-* It works with your editor (notepad, vim, Sublime, Visual Studio, Eclipse, anything else)
-* It works with your backend (PHP, ASP, Ruby, and more)
+* It works with your editor or IDE
+* It works with your web server
Quick Start
===========
@@ -30,7 +30,7 @@ How does it work?
=================
* You run the program on the command line
-* It hosts your page in an iframe
+* It hosts your page in an iframe or by reverse proxy
* It opens a websocket
* It watches the filesystem
* You open your browser to Universal Reloader's webpage
@@ -46,22 +46,23 @@ Then you can run:
universal-reloader [arguments]
- --debounce, -d Debounce interval for throttling websocket publications [default: 100]
- --folder, -f Root folder to watch for changes [default: "."]
- --mask, -m Pipe-delimited file patterns to watch (e.g., **/*.css|**/*.html) [default: "**/*"]
- --port, -p Port to run on [default: 8080]
- --recent, -r Interval of checks to the most-recently modified file [default: 100]
- --url, -u Url to auto-reload on file changes (e.g., http://example.com) [required]
- --verbose Toggle verbose logging
+ --debounce, -d Debounce interval for throttling websocket publications. [default: 100]
+ --folder, -f Root folder to watch for changes. [default: "."]
+ --host, -h Method to use to host your url: iframe or proxy. [default: "proxy"]
+ --mask, -m Pipe-delimited file patterns to watch (e.g., **/*.css|**/*.html). [default: "**/*"]
+ --port, -p Port to run on. [default: 8080]
+ --recent, -r Interval of checks to the most-recently modified file. [default: 100]
+ --url, -u Url to auto-reload on file changes (e.g., http://example.com). [required]
+ --verbose Toggle verbose logging.
-For example, the following would watch all js and css while hosting example.com at http://localhost:8080:
+For example, the following would watch all js and css while hosting http://your-dev-server at http://localhost:8080:
- universal-reloader --mask "**/*.js|**/*.css" --url http://example.com
+ universal-reloader --mask "**/*.js|**/*.css" --url http://your-dev-server
Limitations
===========
-Because this tool uses an iframe, sites that publish an "X-Frame-Options: SAMEORIGIN" header won't work with universal-reloader.
+Using --host iframe, sites that publish an "X-Frame-Options: SAMEORIGIN" header won't work with universal-reloader.
License
=======
View
2  package.json
@@ -1,7 +1,7 @@
{
"name": "universal-reloader",
"preferGlobal": true,
- "version": "0.2.0",
+ "version": "0.2.1",
"author": "omphalos",
"description": "Ultra-compatible command-line tool for autoreloading most browsers on file changes",
"contributors": [
View
2  universal-reloader.js
@@ -12,7 +12,7 @@ var argv = optimist.
usage('Automatically reload your browser when files change.\nUsage: $0').
options('debounce', { alias: 'd', default: 100, describe: 'Debounce interval for throttling websocket publications.' }).
options('folder', { alias: 'f', default: '.', describe: 'Root folder to watch for changes.' }).
- options('host', { alias: 'h', default: 'iframe', describe: 'Method to use to host your url: iframe or proxy.' }).
+ options('host', { alias: 'h', default: 'proxy', describe: 'Method to use to host your url: iframe or proxy.' }).
options('mask', { alias: 'm', default: '**/*', describe: 'Pipe-delimited file patterns to watch (e.g., **/*.css|**/*.html).' }).
options('port', { alias: 'p', default: 8080, describe: 'Port to run on.'}).
options('recent', { alias: 'r', default: 100, describe: 'Interval of checks to the most-recently modified file.' }).
Please sign in to comment.
Something went wrong with that request. Please try again.