This package has been deprecated

Author message:

Never worked

@rwhogg/same-as-upstream

0.1.1 • Public • Published

same-as-upstream

same-as-upstream is a small library to verify if some given JavaScript source code has been modified from its upstream.

This is very useful for (for example):

  1. identifying bugs that you fixed in your copy that upstream might not have
  2. seeing if you can immediately upgrade to a newer version

This is just a library; I will try to make a CLI for it as a separate package.

Installation

$ npm install --save same-as-upstream

Usage

var SameAsUpstream = require("same-as-upstream");
var Library = SameAsUpstream.Library;
var NpmBasedLibrary = SameAsUpstream.NpmBasedLibrary;
var fs = require("fs");
var got = require("got"); // not included
var underscoreLib = new Library("underscore", "1.6.0", fs.readFileSync("node_modules/underscore/underscore.js"));
var underscoreNpm = new N

// FIXME: replace with NpmBasedLibrary usage
got("https://raw.githubusercontent.com/jashkenas/underscore/1.6.0/underscore.js").then(function(response)
{
    var remoteLib = new Library("underscore", "1.6.0", response.body);
    var sameAsUpstream = new SameAsUpstream(underscoreLib);
    console.log(sameAsUpstream.exactlyMatch(remoteLib));
});

License

Copyright © 2015 Bob W. Hogg. All Rights Reserved.

same-as-upstream is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

same-as-upstream is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.

Readme

Keywords

Package Sidebar

Install

npm i @rwhogg/same-as-upstream

Weekly Downloads

1

Version

0.1.1

License

GPL-3.0+

Last publish

Collaborators

  • rwhogg