From 86c7ba87cbfacaeebca4789699bcffb3933d27c4 Mon Sep 17 00:00:00 2001 From: Unitech Date: Tue, 3 Feb 2015 19:34:18 -0500 Subject: [PATCH] change tutorial link for installing nvm --- README.md | 4 ++-- examples/axm/auto-init.js | 14 ++++++++++++++ 2 files changed, 16 insertions(+), 2 deletions(-) create mode 100644 examples/axm/auto-init.js diff --git a/README.md b/README.md index 46b91df1..663d0e8f 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ Compatible with [io.js](https://github.com/iojs/io.js) and [Node.js](https://git Compatible with CoffeeScript. Works on Linux (stable) & MacOSx (stable) & Windows (bĂȘta). -[![NPM version](https://badge.fury.io/js/pm2.png)](http://badge.fury.io/js/pm2) [![Build Status](https://api.travis-ci.org/Unitech/PM2.png?branch=master)](https://travis-ci.org/Unitech/PM2) [![Gitter](https://badges.gitter.im/Join Chat.svg)](https://gitter.im/Unitech/PM2?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![pm2 API Documentation](https://www.omniref.com/js/npm/pm2.png)](https://www.omniref.com/js/npm/pm2) +[![NPM version](https://badge.fury.io/js/pm2.png)](http://badge.fury.io/js/pm2) [![Build Status](https://api.travis-ci.org/Unitech/PM2.png?branch=master)](https://travis-ci.org/Unitech/PM2) [![Gitter](https://badges.gitter.im/Join Chat.svg)](https://gitter.im/Unitech/PM2?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![NPM](https://nodei.co/npm/pm2.png?downloads=true&downloadRank=true)](https://nodei.co/npm/pm2/) @@ -19,7 +19,7 @@ Works on Linux (stable) & MacOSx (stable) & Windows (bĂȘta). $ npm install pm2 -g ``` -*npm is a builtin CLI when you install Node.js - [Installing Node.js or io.js with NVM](https://www.digitalocean.com/community/tutorials/how-to-install-node-js-on-an-ubuntu-14-04-server#how-to-install-using-nvm)* +*npm is a builtin CLI when you install Node.js - [Installing Node.js or io.js with NVM](https://keymetrics.io/2015/02/03/installing-node-js-and-io-js-with-nvm/)* ## Start an application diff --git a/examples/axm/auto-init.js b/examples/axm/auto-init.js new file mode 100644 index 00000000..76b043ce --- /dev/null +++ b/examples/axm/auto-init.js @@ -0,0 +1,14 @@ + + +var pmx = require('pmx').init(); + +var http = require('http'); + +http.createServer(function(req, res) { + res.writeHead(200); + res.end('hey'); +}).listen(8005); + +pmx.action('refresh:db2', {comment : 'Refresh main database'}, function(reply) { + throw new Error('hey'); +});