0.0.7 • Published 7 years ago

mamp v0.0.7

Weekly downloads
5
License
MIT
Repository
-
Last release
7 years ago

MAMP

Manage your MAMP server from your node app or the CLI. Contains a CLI to start a MAMP server from the command line and a nodejs library to manage in your own scripts.

CLI

Install this library globally:

$ npm install -g mamp

Start a MAMP server by using this globally installed command:

$ mamp .

This will start MAMP in your current directory, and will keep running while the script is running. To stop MAMP, just press CTRL + C or close the terminal window.

You can specify a different document root as an argument for the CLI:

$ mamp ~/Documents/htdocs

Another option is running Apache on a different port, by specifying -p or --port:

$ mamp . -p 9000

See all available options by running the command with --help:

$ mamp --help

Node Library

Another option is to start / stop the MAMP server from your own scripts:

var path = require('path'),
  mamp = require('mamp'),
  mampServer = mamp();

mampServer.start({
  documentRoot: path.resolve(__dirname, 'public')
});

Be aware: you will need to stop the mamp server yourself when using it in your own scripts:

mampServer.stop();
0.0.7

7 years ago

0.0.6

7 years ago

0.0.5

7 years ago

0.0.4

7 years ago

0.0.3

7 years ago

0.0.2

7 years ago

0.0.1

7 years ago