Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

isomorphic-git

Package Overview
Dependencies
Maintainers
1
Versions
408
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

isomorphic-git - npm Package Compare versions

Comparing version 0.0.30 to 0.0.31

189

dist/for-browserify/models.js

@@ -274,11 +274,9 @@ 'use strict';

/**
* A convenience helper that makes a bunch of directories at once.
* Delete a file without throwing an error if it is already deleted.
*/
}, {
key: 'mkdirs',
key: 'rm',
value: function () {
var _ref5 = _asyncToGenerator(_regeneratorRuntime.mark(function _callee5(filepaths /*: string[] */) {
var _this = this;
var _ref5 = _asyncToGenerator(_regeneratorRuntime.mark(function _callee5(filepath) {
return _regeneratorRuntime.wrap(function _callee5$(_context5) {

@@ -288,62 +286,31 @@ while (1) {

case 0:
return _context5.abrupt('return', _Promise.all(filepaths.map(function (filepath) {
return _this.mkdir(filepath);
})));
case 1:
case 'end':
return _context5.stop();
}
}
}, _callee5, this);
}));
function mkdirs(_x9) {
return _ref5.apply(this, arguments);
}
return mkdirs;
}()
/**
* Delete a file without throwing an error if it is already deleted.
*/
}, {
key: 'rm',
value: function () {
var _ref6 = _asyncToGenerator(_regeneratorRuntime.mark(function _callee6(filepath) {
return _regeneratorRuntime.wrap(function _callee6$(_context6) {
while (1) {
switch (_context6.prev = _context6.next) {
case 0:
_context6.prev = 0;
_context6.next = 3;
_context5.prev = 0;
_context5.next = 3;
return this._unlink(filepath);
case 3:
_context6.next = 9;
_context5.next = 9;
break;
case 5:
_context6.prev = 5;
_context6.t0 = _context6['catch'](0);
_context5.prev = 5;
_context5.t0 = _context5['catch'](0);
if (!(_context6.t0.code !== 'ENOENT')) {
_context6.next = 9;
if (!(_context5.t0.code !== 'ENOENT')) {
_context5.next = 9;
break;
}
throw _context6.t0;
throw _context5.t0;
case 9:
case 'end':
return _context6.stop();
return _context5.stop();
}
}
}, _callee6, this, [[0, 5]]);
}, _callee5, this, [[0, 5]]);
}));
function rm(_x10) {
return _ref6.apply(this, arguments);
function rm(_x9) {
return _ref5.apply(this, arguments);
}

@@ -363,53 +330,53 @@

value: function () {
var _ref7 = _asyncToGenerator(_regeneratorRuntime.mark(function _callee8(dir) {
var _this2 = this;
var _ref6 = _asyncToGenerator(_regeneratorRuntime.mark(function _callee7(dir) {
var _this = this;
var subdirs, files;
return _regeneratorRuntime.wrap(function _callee8$(_context8) {
return _regeneratorRuntime.wrap(function _callee7$(_context7) {
while (1) {
switch (_context8.prev = _context8.next) {
switch (_context7.prev = _context7.next) {
case 0:
_context8.next = 2;
_context7.next = 2;
return this._readdir(dir);
case 2:
subdirs = _context8.sent;
_context8.next = 5;
subdirs = _context7.sent;
_context7.next = 5;
return _Promise.all(subdirs.map(function () {
var _ref8 = _asyncToGenerator(_regeneratorRuntime.mark(function _callee7(subdir) {
var _ref7 = _asyncToGenerator(_regeneratorRuntime.mark(function _callee6(subdir) {
var res;
return _regeneratorRuntime.wrap(function _callee7$(_context7) {
return _regeneratorRuntime.wrap(function _callee6$(_context6) {
while (1) {
switch (_context7.prev = _context7.next) {
switch (_context6.prev = _context6.next) {
case 0:
res = dir + '/' + subdir;
_context7.next = 3;
return _this2._stat(res);
_context6.next = 3;
return _this._stat(res);
case 3:
if (!_context7.sent.isDirectory()) {
_context7.next = 7;
if (!_context6.sent.isDirectory()) {
_context6.next = 7;
break;
}
_context7.t0 = _this2.readdirDeep(res);
_context7.next = 8;
_context6.t0 = _this.readdirDeep(res);
_context6.next = 8;
break;
case 7:
_context7.t0 = res;
_context6.t0 = res;
case 8:
return _context7.abrupt('return', _context7.t0);
return _context6.abrupt('return', _context6.t0);
case 9:
case 'end':
return _context7.stop();
return _context6.stop();
}
}
}, _callee7, _this2);
}, _callee6, _this);
}));
return function (_x12) {
return _ref8.apply(this, arguments);
return function (_x11) {
return _ref7.apply(this, arguments);
};

@@ -419,4 +386,4 @@ }()));

case 5:
files = _context8.sent;
return _context8.abrupt('return', files.reduce(function (a, f) {
files = _context7.sent;
return _context7.abrupt('return', files.reduce(function (a, f) {
return a.concat(f);

@@ -427,10 +394,10 @@ }, []));

case 'end':
return _context8.stop();
return _context7.stop();
}
}
}, _callee8, this);
}, _callee7, this);
}));
function readdirDeep(_x11) {
return _ref7.apply(this, arguments);
function readdirDeep(_x10) {
return _ref6.apply(this, arguments);
}

@@ -443,10 +410,10 @@

value: function () {
var _ref9 = _asyncToGenerator(_regeneratorRuntime.mark(function _callee9(filename) {
var _ref8 = _asyncToGenerator(_regeneratorRuntime.mark(function _callee8(filename) {
var triesLeft = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 3;
return _regeneratorRuntime.wrap(function _callee9$(_context9) {
return _regeneratorRuntime.wrap(function _callee8$(_context8) {
while (1) {
switch (_context9.prev = _context9.next) {
switch (_context8.prev = _context8.next) {
case 0:
if (!delayedReleases.has(filename)) {
_context9.next = 4;
_context8.next = 4;
break;

@@ -457,7 +424,7 @@ }

delayedReleases.delete(filename);
return _context9.abrupt('return');
return _context8.abrupt('return');
case 4:
if (!(triesLeft === 0)) {
_context9.next = 6;
_context8.next = 6;
break;

@@ -469,24 +436,24 @@ }

case 6:
_context9.prev = 6;
_context9.next = 9;
_context8.prev = 6;
_context8.next = 9;
return this.mkdir(filename + '.lock');
case 9:
_context9.next = 18;
_context8.next = 18;
break;
case 11:
_context9.prev = 11;
_context9.t0 = _context9['catch'](6);
_context8.prev = 11;
_context8.t0 = _context8['catch'](6);
if (!(_context9.t0.code === 'EEXIST')) {
_context9.next = 18;
if (!(_context8.t0.code === 'EEXIST')) {
_context8.next = 18;
break;
}
_context9.next = 16;
_context8.next = 16;
return utils_js.sleep(100);
case 16:
_context9.next = 18;
_context8.next = 18;
return this.lock(filename, triesLeft - 1);

@@ -496,10 +463,10 @@

case 'end':
return _context9.stop();
return _context8.stop();
}
}
}, _callee9, this, [[6, 11]]);
}, _callee8, this, [[6, 11]]);
}));
function lock(_x14) {
return _ref9.apply(this, arguments);
function lock(_x13) {
return _ref8.apply(this, arguments);
}

@@ -512,12 +479,12 @@

value: function () {
var _ref10 = _asyncToGenerator(_regeneratorRuntime.mark(function _callee11(filename) {
var _this3 = this;
var _ref9 = _asyncToGenerator(_regeneratorRuntime.mark(function _callee10(filename) {
var _this2 = this;
var delayRelease = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 50;
return _regeneratorRuntime.wrap(function _callee11$(_context11) {
return _regeneratorRuntime.wrap(function _callee10$(_context10) {
while (1) {
switch (_context11.prev = _context11.next) {
switch (_context10.prev = _context10.next) {
case 0:
if (!delayedReleases.has(filename)) {
_context11.next = 2;
_context10.next = 2;
break;

@@ -531,17 +498,17 @@ }

// But really we wait a bit to see if you want to acquire it again.
delayedReleases.set(filename, setTimeout(_asyncToGenerator(_regeneratorRuntime.mark(function _callee10() {
return _regeneratorRuntime.wrap(function _callee10$(_context10) {
delayedReleases.set(filename, setTimeout(_asyncToGenerator(_regeneratorRuntime.mark(function _callee9() {
return _regeneratorRuntime.wrap(function _callee9$(_context9) {
while (1) {
switch (_context10.prev = _context10.next) {
switch (_context9.prev = _context9.next) {
case 0:
delayedReleases.delete(filename);
_context10.next = 3;
return _this3._rmdir(filename + '.lock');
_context9.next = 3;
return _this2._rmdir(filename + '.lock');
case 3:
case 'end':
return _context10.stop();
return _context9.stop();
}
}
}, _callee10, _this3);
}, _callee9, _this2);
})), delayRelease));

@@ -551,10 +518,10 @@

case 'end':
return _context11.stop();
return _context10.stop();
}
}
}, _callee11, this);
}, _callee10, this);
}));
function unlock(_x16) {
return _ref10.apply(this, arguments);
function unlock(_x15) {
return _ref9.apply(this, arguments);
}

@@ -561,0 +528,0 @@

@@ -56,3 +56,5 @@ import path from 'path';

folders = folders.map(dir => gitdir + '/' + dir);
await fs.mkdirs(folders);
for (let folder of folders) {
await fs.mkdir(folder);
}
await fs.write(gitdir + '/config', '[core]\n' + '\trepositoryformatversion = 0\n' + '\tfilemode = false\n' + '\tbare = false\n' + '\tlogallrefupdates = true\n' + '\tsymlinks = false\n' + '\tignorecase = true\n');

@@ -59,0 +61,0 @@ await fs.write(gitdir + '/HEAD', 'ref: refs/heads/master\n');

@@ -99,9 +99,2 @@ import path from 'path';

/**
* A convenience helper that makes a bunch of directories at once.
*/
async mkdirs(filepaths /*: string[] */) {
return Promise.all(filepaths.map(filepath => this.mkdir(filepath)));
}
/**
* Delete a file without throwing an error if it is already deleted.

@@ -108,0 +101,0 @@ */

@@ -62,3 +62,5 @@ 'use strict';

folders = folders.map(dir => gitdir + '/' + dir);
await fs.mkdirs(folders);
for (let folder of folders) {
await fs.mkdir(folder);
}
await fs.write(gitdir + '/config', '[core]\n' + '\trepositoryformatversion = 0\n' + '\tfilemode = false\n' + '\tbare = false\n' + '\tlogallrefupdates = true\n' + '\tsymlinks = false\n' + '\tignorecase = true\n');

@@ -65,0 +67,0 @@ await fs.write(gitdir + '/HEAD', 'ref: refs/heads/master\n');

@@ -105,9 +105,2 @@ 'use strict';

/**
* A convenience helper that makes a bunch of directories at once.
*/
async mkdirs(filepaths /*: string[] */) {
return Promise.all(filepaths.map(filepath => this.mkdir(filepath)));
}
/**
* Delete a file without throwing an error if it is already deleted.

@@ -114,0 +107,0 @@ */

@@ -1,1 +0,1 @@

{"name":"isomorphic-git","version":"0.0.30","description":"A pure JavaScript implementation of git for node and browsers!","typings":"./src/index.d.ts","main":"dist/for-node/","browser":"dist/for-browserify/","module":"dist/for-future/","unpkg":"dist/bundle.umd.min.js","bin":{"isogit":"./cli.js"},"engines":{"node":">=7.6.0"},"scripts":{"start":"nps","test":"nps test","precommit":"nps format toc","semantic-release":"semantic-release pre && npm publish && semantic-release post"},"repository":{"type":"git","url":"https://github.com/wmhilton/isomorphic-git.git"},"keywords":["git"],"author":"William Hilton <wmhilton@gmail.com>","license":"Unlicense","bugs":{"url":"https://github.com/wmhilton/isomorphic-git/issues"},"homepage":"https://github.com/wmhilton/isomorphic-git#readme","files":["dist","cli.js"],"dependencies":{"async-lock":"^1.0.0","await-stream-ready":"^1.0.1","babel-runtime":"^6.26.0","buffer":"^5.0.7","buffer-peek-stream":"^1.0.1","buffercursor":"0.0.12","gartal":"^1.1.2","git-apply-delta":"0.0.7","git-list-pack":"0.0.10","ignore":"^3.3.6","ini":"^1.3.4","marky":"^1.2.0","minimisted":"^2.0.0","openpgp":"^2.5.10","pad":"^2.0.1","pako":"^1.0.5","pify":"^3.0.0","shasum":"^1.0.2","simple-concat":"^1.0.0","simple-get":"^2.7.0","through2":"^2.0.3"},"devDependencies":{"babel-plugin-external-helpers":"^6.22.0","babel-plugin-transform-es2015-modules-commonjs":"^6.24.1","babel-plugin-transform-object-rest-spread":"^6.23.0","babel-plugin-transform-runtime":"^6.23.0","babel-preset-env":"^1.6.0","babel-preset-flow":"^6.23.0","ban-sensitive-files":"^1.9.0","browserfs":"^1.4.3","browserify":"^14.4.0","browserify-shim":"^3.8.14","codecov":"^3.0.0","doctoc":"^1.3.0","esdoc":"^1.0.4","esdoc-ecmascript-proposal-plugin":"^1.0.0","esdoc-importpath-plugin":"^1.0.1","esdoc-standard-plugin":"^1.0.0","husky":"^0.14.3","jest":"^21.2.1","jest-fixtures":"^0.6.0","jsonfile":"^4.0.0","karma":"^1.7.1","karma-browserify":"^5.1.1","karma-chrome-launcher":"^2.2.0","karma-firefox-launcher":"^1.0.1","karma-sauce-launcher":"^1.2.0","karma-tap":"^3.1.1","lodash":"^4.17.4","nock":"^9.0.17","npm-run-all":"^4.1.1","nps":"^5.7.1","nps-utils":"^1.4.0","parse-header-stream":"^1.1.1","prettier-standard":"^7.0.3","rollup":"^0.51.6","rollup-plugin-babel":"^3.0.2","rollup-plugin-json":"^2.3.0","standard":"^10.0.3","stream-equal":"^1.0.1","tape":"^4.8.0","uglify-es":"^3.1.2","watch":"^1.0.2","watchify":"^3.9.0","semantic-release":"^8.2.0"},"ava":{"source":["dist/for-node/*"]},"browserify":{"transform":["browserify-shim"]},"browserify-shim":{"fs":"global:fs"},"testling":{"files":"testling/basic-test.js","browsers":["chrome/latest","firefox/latest","ie/latest"]},"jest":{"testPathIgnorePatterns":["__helpers__"],"testEnvironment":"node"}}
{"name":"isomorphic-git","version":"0.0.31","description":"A pure JavaScript implementation of git for node and browsers!","typings":"./src/index.d.ts","main":"dist/for-node/","browser":"dist/for-browserify/","module":"dist/for-future/","unpkg":"dist/bundle.umd.min.js","bin":{"isogit":"./cli.js"},"engines":{"node":">=7.6.0"},"scripts":{"start":"nps","test":"nps test","precommit":"nps format toc","semantic-release":"semantic-release pre && npm publish && semantic-release post"},"repository":{"type":"git","url":"https://github.com/wmhilton/isomorphic-git.git"},"keywords":["git"],"author":"William Hilton <wmhilton@gmail.com>","license":"Unlicense","bugs":{"url":"https://github.com/wmhilton/isomorphic-git/issues"},"homepage":"https://github.com/wmhilton/isomorphic-git#readme","files":["dist","cli.js"],"dependencies":{"async-lock":"^1.0.0","await-stream-ready":"^1.0.1","babel-runtime":"^6.26.0","buffer":"^5.0.7","buffer-peek-stream":"^1.0.1","buffercursor":"0.0.12","gartal":"^1.1.2","git-apply-delta":"0.0.7","git-list-pack":"0.0.10","ignore":"^3.3.6","ini":"^1.3.4","marky":"^1.2.0","minimisted":"^2.0.0","openpgp":"^2.5.10","pad":"^2.0.1","pako":"^1.0.5","pify":"^3.0.0","shasum":"^1.0.2","simple-concat":"^1.0.0","simple-get":"^2.7.0","through2":"^2.0.3"},"devDependencies":{"babel-plugin-external-helpers":"^6.22.0","babel-plugin-transform-es2015-modules-commonjs":"^6.24.1","babel-plugin-transform-object-rest-spread":"^6.23.0","babel-plugin-transform-runtime":"^6.23.0","babel-preset-env":"^1.6.0","babel-preset-flow":"^6.23.0","ban-sensitive-files":"^1.9.0","browserfs":"^1.4.3","browserify":"^14.4.0","browserify-shim":"^3.8.14","codecov":"^3.0.0","doctoc":"^1.3.0","esdoc":"^1.0.4","esdoc-ecmascript-proposal-plugin":"^1.0.0","esdoc-importpath-plugin":"^1.0.1","esdoc-standard-plugin":"^1.0.0","husky":"^0.14.3","jest":"^21.2.1","jest-fixtures":"^0.6.0","jsonfile":"^4.0.0","karma":"^1.7.1","karma-browserify":"^5.1.1","karma-chrome-launcher":"^2.2.0","karma-firefox-launcher":"^1.0.1","karma-sauce-launcher":"^1.2.0","karma-tap":"^3.1.1","lodash":"^4.17.4","nock":"^9.0.17","npm-run-all":"^4.1.1","nps":"^5.7.1","nps-utils":"^1.4.0","parse-header-stream":"^1.1.1","prettier-standard":"^7.0.3","rollup":"^0.51.6","rollup-plugin-babel":"^3.0.2","rollup-plugin-json":"^2.3.0","standard":"^10.0.3","stream-equal":"^1.0.1","tape":"^4.8.0","uglify-es":"^3.1.2","watch":"^1.0.2","watchify":"^3.9.0","semantic-release":"^8.2.0"},"ava":{"source":["dist/for-node/*"]},"browserify":{"transform":["browserify-shim"]},"browserify-shim":{"fs":"global:fs"},"testling":{"files":"testling/basic-test.js","browsers":["chrome/latest","firefox/latest","ie/latest"]},"jest":{"testPathIgnorePatterns":["__helpers__"],"testEnvironment":"node"}}

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc