npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

ambient-cli

v0.8.8

Published

Cli tool for interacting with development environments from anywhere

Downloads

57

Readme

ambient-cli

Cli tool for interacting with development environments from anywhere

Command list

Cli tool for interacting with development environments from anywhere.

Usage:
ambient [command] --flags

Available commands:

  - add      Add an ambient environment to list of know environments
  - remove   Remove an environment from ambients known environments
  - update   Update an environment
  - list|ls  List all known environments
  - use      Specify a default environment
  - start    Start a server
  - stop     Stop ambient servers
  - restart  Restart ambient servers
  - run      Run a command on an environments root relative root. -b, --base to run at projects real base
  - install  Install a package using npm [or --jspm]
  - logs     Display logs for a given process

Available flags:

 -a, --alias        Set an alias name for the environment
 -u, --use          Set this environment as default.
 -f, --force        Force an action to happen. Commonly used to overwrite an existing environment
 --name             Specify a new name when updating an environment
 --dir              Explicitly set the root directory of an environment when adding or updating it
 -l, --logs         Directory to store logs when running processes
 -R, --reuse        Reuse an old process (including its runtime options and arguments)
 -b, --base         Reference an environments base
 -i, --interactive  Run a command in interactive mode
 -t, --timeout      Set a timeout for operations
 --running          Filter by environments' running status
 -d, --daemon       Start a server as a daemon
 --no-parse         When listing running environments, display a direct listing of running processes
 --no-save          Install a module without saving it

Specifying custom runtime settings.

ambient-cli will look for a .ambient file in your projects root. In this file you can configure how ambient must run your project

{
  "command": "node", // The service to run your script with. Defaults to node
  "script": "core/server.js", // The location of your script relative to root
  "root": "src", // The root of your project. Set it to the directory of your node_modules if using node.
  "args": ["--production"], // additional arguments to run with the script
  "logs": "logs", // custom location for logs. defaults to ~/.ambient/logs
  
  // You can also predefine commands. These commands can be run using `ambient run build` or `ambient run start`
  "commands": {
    "build": {
        "plainCommand": "npm run build",
        "root": "src"
    },
    
    "start": {
        "command": "node",
        "script": "core/server.js",
        "root": "src"
    }
  }
}

If you want ambient list to keep track of running environments that are container based, then do not run them as daemons. eg:

{
  "command": "docker-compose up container", // instead of `docker-compose up -d container`
}

If no .ambient file is found, the cli will look for a package.json in either your projects root or in a src sub directory. It will then run the script at main using node.