/libgrabber

Keeps projects hosted in jsDelivr updated

Primary LanguageJavaScript

libgrabber

Work in Progress

Usage

Requirements

  • node 0.10.x

Instalation

Global package installation
$ npm install -g libgrabber
# 'libgrabber' will be in $PATH
Local package installation
$ mkdir libgrabber && cd libgrabber
$ npm install libgrabber
# Run it by executing 'node ./node_modules/libgrabber/bin/libgrabber.js'

Configuration

Repo
  1. Properly configured git account (user.name, user.email, ssh key with empty ssh passphrase)
  2. Forked jsdelivr repo
  3. Upstream set to jsdelivr repo
$ git remote add upstream git@github.com:jsdelivr/jsdelivr.git
Libgrabber config
{
"github-access-token": "<secret>",
"pull-request-repo": "https://github.com/jsdelivr/jsdelivr",
"origin-repo": "<forked-repo-https-endpoint>",
"mention-repo-owner": false,
"papertrail-url": "<optional>",
"papertrail-hostname": "<optional>"
}

Running

# --jsdelivr-path <path to the cloned forked repo>
# --config <path to the above mention config file>
$ libgrabber --jsdelivr-path jsdelivr/ --config jsdelivr/libgrabber.config.json

Updating Package

When your SemVer is updated on the master branch, libgrabber will automatically update your package on jsDelivr.