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

cli365

v1.1.1

Published

A cli used to manage the rede365 projects

Downloads

2

Readme

cli365

A cli used to manage the rede365 projects

oclif Version Downloads/week License

Usage

$ npm install -g cli365
$ cli365 COMMAND
running command...
$ cli365 (-v|--version|version)
cli365/1.1.1 linux-x64 node-v13.3.0
$ cli365 --help [COMMAND]
USAGE
  $ cli365 COMMAND
...

Commands

cli365 help [COMMAND]

display help for cli365

USAGE
  $ cli365 help [COMMAND]

ARGUMENTS
  COMMAND  command to show help for

OPTIONS
  --all  see all commands in CLI

See code: @oclif/plugin-help

cli365 list

List all projects found based on the cli365.json

USAGE
  $ cli365 list

OPTIONS
  -c, --config=config  [default: cli365.json] cli365 config file

DESCRIPTION
  ...
  Extra documentation goes here

See code: src/commands/list.js

cli365 list:groups

List all groups and its projects

USAGE
  $ cli365 list:groups

OPTIONS
  -c, --config=config  [default: cli365.json] cli365 config file

DESCRIPTION
  ...
  Extra documentation goes here

See code: src/commands/list/groups.js

cli365 run

Run a custom script on all the projects defined on the config file

USAGE
  $ cli365 run

OPTIONS
  -c, --config=config  [default: cli365.json] cli365 config file
  -g, --group=group    run script only on selected group
  -s, --script=script  script that will be ran on the projects

DESCRIPTION
  ...
  If a group is passed, only the group projects will get the script ran

See code: src/commands/run.js

cli365 start

Start all the projects defined on the config file

USAGE
  $ cli365 start

OPTIONS
  -c, --config=config  [default: cli365.json] cli365 config file
  -g, --group=group    start only a specific group

DESCRIPTION
  ...
  If a group is passed, only the group projects will be started

See code: src/commands/start.js

cli365 stop

Stop all the projects defined on the config file

USAGE
  $ cli365 stop

OPTIONS
  -c, --config=config  [default: cli365.json] cli365 config file
  -g, --group=group    start only a specific group

DESCRIPTION
  ...
  If a group is passed, only the group projects will be stopped

See code: src/commands/stop.js

Config

The config file is a json, it supports the following attributes:

{
  "defaults": {}, 
  "projects": [],
  "groups": []
}

Defaults

The defaults is an object that defines the default behavior for start/stop scripts, the default group to which projects will belong and also the default scripts that will be inherited by all the projects

example

{
  "defaults": {
    "group": "full-stack",
    "start": "make start",
    "stop": "make stop",
    "scripts": {
      "push": "git push",
      "pull": "git pull"
    }
  }
}

Projects

Projects is an array of objects that defines how the project should be interpreted by the cli (path, name, scripts (start/stop/custom)) the only argument that is required for the projects definition is the project path which may be passed through the config object or directly as one of the projects item

examples

{
  "projects": [
    "auth-service", // Here the project name and path will be the same, scripts (start/stop/custom) will use the defaults
    {
       "name": "auth", // Custom name, optional, will use path basename if not defined
       "path": "./auth-service" // the path is required when you are using a config object, and the ./ is optional
    },
    {
      "path": "auth-service",
      "start": "yarn start", // custom start script, will override the defaults.start definition
      "stop": "yarn stop" // custom stop command, same as custom start
    },
    {
      "path": "auth-service",
      "scripts": {
        "pull": "git pull origin develop" // custom pull script, will override defaults.scripts.pull definition if defined
      }
    }
  ]
}

Groups

Groups is an array of objects that defines the project groups to allow easy start/stop and execution of custom scripts in pre-defined groups like frontend, backend, databases...

example

{
  "groups": [
    {
      "name": "full-stack",
      "projects": "*" // the * wildcard is used to indicate the cli that this group will have all defined projects
    },
    {
        "name": "frontend",
        "projects": ["frontend-1", "frontend-1"] // all the project names defined in the projects.* section
    }   
  ]
}

An important thing to be aware of is that inside groups.*.projects you should put the project name defined in projects.*.name, if you haven't defined a custom name for the project, the path basename will be used as project name so this is the one you should use here.