@exaprint/serverless-pr-remover
NodeJS script that remove serverless PR deployment on closed PR
Last updated 3 years ago by l0gin .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @exaprint/serverless-pr-remover 
SYNC missed versions from official npm registry.

Serverless PR Remover

build status NPM link coverage report JsDoc report Plato report

NodeJS script that remove serverless PR deployment on closed PR.

Assuming you deployed a stage environment call PR1 (where 1 is the PR ID) with Serverless Framework, the script will try to remove this deployment.

Github is the only supported provider, Gitlab support comming soon

Note: The Github project is just a mirror. The upstream of this project hosted on Gitlab at: https://gitlab.com/L0gIn/serverless-pr-remover

Install

    $ npm i -g serverless-pr-remover

Usage

  Usage: sls-pr-rm [options]

  Get closed PR from Github repository and 
  try to remove there stage deployment using Serverless Framework by running cmd like 
  (where 13 is the PR ID): sls remove --stage pr13

  Options:

    -h, --help                          output usage information
    -V, --version                       output the version number
    --github-host <host>                Set Github host. defaults to should be api.github.com for GitHub
    --github-basic-username <username>  Set Github Basic Auth Username.
    --github-basic-password <password>  Set Github Basic Auth Password.
    --github-oauth-token <token>        Set Github OAuth Token.
    --github-owner <owner>              Github repository owner (Like 'a' if repo is: https://github.com/a/b). 
                                        If not provided with --github-repo, it will check for current remote value using git CLI.
    --github-repo <repo>                Repository name (Like 'b' if repo is: https://github.com/a/b). 
                                        If not provided with --github-owner, it will check for current remote value using git CLI.
    -d, --debug                         Enable debug mode. Default to disabled.
    -v, --verbose                       Enable verbose mode. Default to disabled.

Examples

Usage on public repository

    $ sls-pr-rm
    # Or for a the repository https://github.com/foo/bar.git
    $ sls-pr-rm --github-owner foo --github-repo bar

Usage on private repository using OAuth

    $ sls-pr-rm --github-oauth-token xxxxxxxxxxxxxx
    # Or for a the repository https://github.com/foo/bar.git
    $ sls-pr-rm --github-oauth-token xxxxxxxxxxxxxx --github-owner foo --github-repo bar

Usage on private repository using Basic Auth

    $ sls-pr-rm --github-basic-username MyAwesomeUsername --github-basic-password MyAwesomePasswd
    # Or for a the repository https://github.com/foo/bar.git
    $ sls-pr-rm --github-basic-username MyAwesomeUsername --github-basic-password MyAwesomePasswd --github-owner foo --github-repo bar

Debug and/or Verbose

    # Verbose only
    $ sls-pr-rm -v
    # Debug only
    $ sls-pr-rm -d
    # Verbose and Debug
    $ sls-pr-rm -vd

Current Tags

  • 1.3.0                                ...           latest (3 years ago)

9 Versions

  • 1.3.0                                ...           3 years ago
  • 1.2.2                                ...           3 years ago
  • 1.2.1                                ...           3 years ago
  • 1.2.0                                ...           3 years ago
  • 1.1.1                                ...           3 years ago
  • 1.1.0                                ...           3 years ago
  • 1.0.2                                ...           3 years ago
  • 1.0.1                                ...           3 years ago
  • 1.0.0                                ...           3 years ago
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 9
Dependencies (5)
Dev Dependencies (13)
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |