server-ready-cli

    0.1.0 • Public • Published

    server-ready-cli

    Run commands only when a server is available

    Useful if you want to run things in parallel but need to wait for a server to be ready.

    Install

    $ npm install -g server-ready-cli

    Usage

    $ server-ready --port 3000 -- some-command

    Example

    In your package.json, you can use server-ready-cli to run client only when server is available.

    {
      "scripts": {
        "client": "server-ready --port 3000 -- node client.js",
        "server": "node server.js",
        "start": "npm run server & npm run client & wait"
      }
    }

    See also

    License

    MIT - Typicode 🌵

    Keywords

    none

    Install

    npm i server-ready-cli

    DownloadsWeekly Downloads

    2

    Version

    0.1.0

    License

    MIT

    Last publish

    Collaborators

    • typicode