implement Smartfile.write

This commit is contained in:
Philipp Kunz 2018-02-16 21:57:44 +01:00
parent 9fa98c3804
commit 5b2089044d
17 changed files with 136 additions and 271 deletions

View File

@ -8,6 +8,7 @@ cache:
stages: stages:
- mirror - mirror
- security
- test - test
- release - release
- trigger - trigger
@ -20,6 +21,15 @@ mirror:
tags: tags:
- docker - docker
security:
stage: security
script:
- npmci command yarn global add snyk
- npmci command yarn install --ignore-scripts
- npmci command snyk test
tags:
- docker
testLEGACY: testLEGACY:
stage: test stage: test
script: script:
@ -31,15 +41,6 @@ testLEGACY:
- docker - docker
allow_failure: true allow_failure: true
testStableWindows:
stage: test
script:
- npm install -g npmts && cd C:\\gitlab_runner\builds\326a2ffb\0\pushrocks\smartfile && npm install && npm test
coverage: /\d+.?\d+?\%\s*coverage/
tags:
- windows
allow_failure: true
testLTS: testLTS:
stage: test stage: test
script: script:

View File

@ -1,6 +1,6 @@
The MIT License (MIT) The MIT License (MIT)
Copyright (c) 2015 Push.Rocks Copyright (c) 2015 Lossless GmbH
Permission is hereby granted, free of charge, to any person obtaining a copy Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal of this software and associated documentation files (the "Software"), to deal

View File

@ -1,22 +0,0 @@
# Test against the latest version of this Node.js version
environment:
nodejs_version: "6"
# Install scripts. (runs after repo cloning)
install:
# Get the latest stable version of Node.js or io.js
- ps: Install-Product node $env:nodejs_version
# install modules
- npm install
- npm install -g npmts
# Post-install test scripts.
test_script:
# Output useful info for debugging.
- node --version
- npm --version
# run tests
- npm test
# Don't actually build.
build: off

View File

@ -44,8 +44,10 @@ export declare class Smartfile {
setContentsFromString(contentString: string): void; setContentsFromString(contentString: string): void;
/** /**
* write file to disk * write file to disk
* Behaviours:
* - no argument write to exactly where the file was picked up
*/ */
write(): Promise<void>; write(pathArg?: string): Promise<void>;
/** /**
* read file from disk * read file from disk
*/ */

View File

@ -9,6 +9,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
}; };
Object.defineProperty(exports, "__esModule", { value: true }); Object.defineProperty(exports, "__esModule", { value: true });
const plugins = require("./smartfile.plugins"); const plugins = require("./smartfile.plugins");
const memory = require("./smartfile.memory");
/** /**
* class Smartfile * class Smartfile
* -> is vinyl file compatible * -> is vinyl file compatible
@ -41,9 +42,13 @@ class Smartfile {
} }
/** /**
* write file to disk * write file to disk
* Behaviours:
* - no argument write to exactly where the file was picked up
*/ */
write() { write(pathArg) {
return __awaiter(this, void 0, void 0, function* () { return __awaiter(this, void 0, void 0, function* () {
const stringToWrite = this.contentBuffer.toString();
yield memory.toFs(stringToWrite, this.path);
}); });
} }
/** /**
@ -111,4 +116,4 @@ class Smartfile {
} }
} }
exports.Smartfile = Smartfile; exports.Smartfile = Smartfile;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic21hcnRmaWxlLmNsYXNzZXMuc21hcnRmaWxlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vdHMvc21hcnRmaWxlLmNsYXNzZXMuc21hcnRmaWxlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7Ozs7Ozs7QUFBQSwrQ0FBOEM7QUFTOUM7OztHQUdHO0FBQ0g7SUEyQkU7OztPQUdHO0lBR0gsWUFBYSxVQUF3QztRQUNuRCxFQUFFLENBQUMsQ0FBQyxVQUFVLENBQUMsYUFBYSxDQUFDLENBQUMsQ0FBQztZQUM3QixJQUFJLENBQUMsYUFBYSxHQUFHLFVBQVUsQ0FBQyxhQUFhLENBQUE7UUFDL0MsQ0FBQztRQUFDLElBQUksQ0FBQyxFQUFFLENBQUMsQ0FBQyxVQUFVLENBQUMsYUFBYSxDQUFDLENBQUMsQ0FBQztZQUNwQyxJQUFJLENBQUMscUJBQXFCLENBQUMsVUFBVSxDQUFDLGFBQWEsQ0FBQyxDQUFBO1FBQ3RELENBQUM7UUFBQyxJQUFJLENBQUMsQ0FBQztZQUNOLE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ELE1BQU0sQ0FBQyxLQUFLLENBQUE7SUFDZCxDQUFDO0lBRUQsV0FBVztRQUNULE1BQU0sQ0FBQyxLQUFLLENBQUE7SUFDZCxDQUFDO0lBRUQsUUFBUTtRQUNOLE1BQU0sQ0FBQyxLQUFLLENBQUE7SUFDZCxDQUFDO0lBRUQsVUFBVTtRQUNSLE1BQU0sQ0FBQyxLQUFLLENBQUE7SUFDZCxDQUFDO0lBRUQsZ0JBQWdCO0lBQ2hCLGNBQWMsQ0FBRSxXQUFtQjtRQUNqQyxJQUFJLFdBQVcsR0FBRyxJQUFJLENBQUMsVUFBVSxDQUFDLElBQUksQ0FBQTtRQUN0QyxJQUFJLENBQUMsSUFBSSxHQUFHLElBQUksQ0FBQyxJQUFJLENBQUMsT0FBTyxDQUFDLElBQUksTUFBTSxDQUFDLFdBQVcsR0FBRyxHQUFHLENBQUMsRUFBQyxXQUFXLENBQUMsQ0FBQTtJQUMxRSxDQUFDO0NBQ0Y7QUF2SUQsOEJBdUlDIn0=

File diff suppressed because one or more lines are too long

View File

@ -19,4 +19,4 @@ exports.objectFile = (fileStringArg, fileTypeArg) => {
break; break;
} }
}; };
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic21hcnRmaWxlLmludGVycHJldGVyLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vdHMvc21hcnRmaWxlLmludGVycHJldGVyLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBQUEsMEJBQXVCO0FBRXZCLCtDQUErQztBQUVwQyxRQUFBLFFBQVEsR0FBRyxDQUFDLE9BQWU7SUFDbEMsSUFBSSxPQUFPLEdBQUcsT0FBTyxDQUFDLElBQUksQ0FBQyxPQUFPLENBQUMsT0FBTyxDQUFDLENBQUE7SUFDM0MsSUFBSSxRQUFRLEdBQUcsT0FBTyxDQUFDLE9BQU8sQ0FBQyxZQUFZLEVBQUMsSUFBSSxDQUFDLENBQUEsQ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xFQUFDLENBQUMsQ0FBQTtBQUN6RSxDQUFDLENBQUE7QUFFVSxRQUFBLGtCQUFrQixHQUFHLENBQU8saUJBQThCLEVBQUUsTUFBYyxFQUFFLEVBQUU7SUFDdkYsTUFBTSxXQUFXLENBQUMsU0FBUyxDQUFDLE1BQU0sQ0FBQyxDQUFBO0lBQ25DLEdBQUcsQ0FBQyxDQUFDLElBQUksU0FBUyxJQUFJLGlCQUFpQixDQUFDLENBQUMsQ0FBQztRQUN4QyxNQUFNLFlBQUksQ0FBQyxTQUFTLEVBQUUsTUFBTSxFQUFFO1lBQzVCLGVBQWUsRUFBRSxJQUFJO1NBQ3RCLENBQUMsQ0FBQTtJQUNKLENBQUM7QUFDSCxDQUFDLENBQUEsQ0FBQSJ9

View File

@ -1,4 +1,3 @@
import 'typings-global';
export import fs = require('fs'); export import fs = require('fs');
export import fsExtra = require('fs-extra'); export import fsExtra = require('fs-extra');
export declare let glob: any; export declare let glob: any;

View File

@ -1,6 +1,5 @@
"use strict"; "use strict";
Object.defineProperty(exports, "__esModule", { value: true }); Object.defineProperty(exports, "__esModule", { value: true });
require("typings-global");
exports.fs = require("fs"); exports.fs = require("fs");
exports.fsExtra = require("fs-extra"); exports.fsExtra = require("fs-extra");
exports.glob = require('glob'); exports.glob = require('glob');
@ -11,4 +10,4 @@ exports.requireReload = require('require-reload');
exports.smartpath = require("smartpath"); exports.smartpath = require("smartpath");
exports.vinylFile = require('vinyl-file'); exports.vinylFile = require('vinyl-file');
exports.yaml = require('js-yaml'); exports.yaml = require('js-yaml');
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic21hcnRmaWxlLnBsdWdpbnMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi90cy9zbWFydGZpbGUucGx1Z2lucy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLDBCQUF1QjtBQUN2QiwyQkFBZ0M7QUFDaEMsc0NBQTJDO0FBQ2hDLFFBQUEsSUFBSSxHQUFHLE9BQU8sQ0FBQyxNQUFNLENBQUMsQ0FBQTtBQUNqQywrQkFBb0M7QUFDcEMsOEJBQW1DO0FBQ25DLCtDQUFvRDtBQUN6QyxRQUFBLGFBQWEsR0FBRyxPQUFPLENBQUMsZ0JBQWdCLENBQUMsQ0FBQTtBQUNwRCx5Q0FBOEM7QUFDbkMsUUFBQSxTQUFTLEdBQUcsT0FBTyxDQUFDLFlBQVksQ0FBQyxDQUFBO0FBQ2pDLFFBQUEsSUFBSSxHQUFHLE9BQU8sQ0FBQyxTQUFTLENBQUMsQ0FBQSJ9 //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic21hcnRmaWxlLnBsdWdpbnMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi90cy9zbWFydGZpbGUucGx1Z2lucy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLDJCQUFnQztBQUNoQyxzQ0FBMkM7QUFDaEMsUUFBQSxJQUFJLEdBQUcsT0FBTyxDQUFDLE1BQU0sQ0FBQyxDQUFBO0FBQ2pDLCtCQUFvQztBQUNwQyw4QkFBbUM7QUFDbkMsK0NBQW9EO0FBQ3pDLFFBQUEsYUFBYSxHQUFHLE9BQU8sQ0FBQyxnQkFBZ0IsQ0FBQyxDQUFBO0FBQ3BELHlDQUE4QztBQUNuQyxRQUFBLFNBQVMsR0FBRyxPQUFPLENBQUMsWUFBWSxDQUFDLENBQUE7QUFDakMsUUFBQSxJQUFJLEdBQUcsT0FBTyxDQUFDLFNBQVMsQ0FBQyxDQUFBIn0=

View File

@ -42,10 +42,9 @@ exports.toString = (fromArg) => {
done.resolve(res.body); done.resolve(res.body);
} }
else { else {
console.error('could not get remote file from ' + fromArg);
done.reject(new Error('could not get remote file from ' + fromArg)); done.reject(new Error('could not get remote file from ' + fromArg));
} }
}); });
return done.promise; return done.promise;
}; };
//# sourceMappingURL=data:application/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BTSxDQUFDLElBQUksS0FBSyxDQUFDLGlDQUFpQyxHQUFHLE9BQU8sQ0FBQyxDQUFDLENBQUE7UUFDckUsQ0FBQztJQUNILENBQUMsQ0FBQyxDQUFBO0lBQ0YsTUFBTSxDQUFDLElBQUksQ0FBQyxPQUFPLENBQUE7QUFDckIsQ0FBQyxDQUFBIn0=

View File

@ -26,20 +26,20 @@
}, },
"homepage": "https://gitlab.com/pushrocks/smartfile", "homepage": "https://gitlab.com/pushrocks/smartfile",
"dependencies": { "dependencies": {
"@types/fs-extra": "4.x.x", "@types/fs-extra": "5.0.0",
"@types/vinyl": "^2.0.1", "@types/vinyl": "^2.0.2",
"fs-extra": "^4.0.2", "fs-extra": "^5.0.0",
"glob": "^7.1.2", "glob": "^7.1.2",
"js-yaml": "^3.10.0", "js-yaml": "^3.10.0",
"require-reload": "0.2.2", "require-reload": "0.2.2",
"smartpath": "^3.2.8", "smartpath": "^3.2.8",
"smartq": "^1.1.6", "smartq": "^1.1.6",
"smartrequest": "^1.0.6", "smartrequest": "^1.0.8",
"typings-global": "^1.0.20",
"vinyl-file": "^3.0.0" "vinyl-file": "^3.0.0"
}, },
"devDependencies": { "devDependencies": {
"gulp-function": "^2.2.9", "@types/node": "^9.4.6",
"tapbundle": "^1.1.1" "gulp-function": "^2.2.14",
"tapbundle": "^1.1.8"
} }
} }

View File

@ -12,41 +12,43 @@ tap.test('.fs.fileExistsSync -> should return an accurate boolean', async () =>
expect(smartfile.fs.fileExistsSync('./test/notthere.json')).be.false expect(smartfile.fs.fileExistsSync('./test/notthere.json')).be.false
}) })
tap.test('.fs.fileExists should resolve or reject a promise', async () => { tap.test('.fs.fileExists -> should resolve or reject a promise', async () => {
expect(smartfile.fs.fileExists('./test/mytest.json')).to.be.instanceof(Promise) expect(smartfile.fs.fileExists('./test/mytest.json')).to.be.instanceof(Promise)
await expect(smartfile.fs.fileExists('./test/mytest.json')).to.eventually.be.fulfilled await smartfile.fs.fileExists('./test/mytest.json')
await expect(smartfile.fs.fileExists('./test/notthere.json')).to.eventually.be.rejected await smartfile.fs.fileExists('./test/notthere.json').catch(err => {
return expect(err.message).to.equal("ENOENT: no such file or directory, access './test/notthere.json'")
});
}) })
tap.test('.fs.listFoldersSync() -> should get the file type from a string', async () => { tap.test('.fs.listFoldersSync() -> should get the file type from a string', async () => {
expect(smartfile.fs.listFoldersSync('./test/')).to.deep.include('testfolder') expect(smartfile.fs.listFoldersSync('./test/')).to.include('testfolder')
expect(smartfile.fs.listFoldersSync('./test/')).to.not.deep.include('notExistentFolder') expect(smartfile.fs.listFoldersSync('./test/')).to.not.include('notExistentFolder')
}) })
tap.test('.fs.listFolders() -> should get the file type from a string', async () => { tap.test('.fs.listFolders() -> should get the file type from a string', async () => {
let folderArrayArg = await smartfile.fs.listFolders('./test/') let folderArrayArg = await smartfile.fs.listFolders('./test/')
expect(folderArrayArg).to.deep.include('testfolder') expect(folderArrayArg).to.include('testfolder')
expect(folderArrayArg).to.not.deep.include('notExistentFolder') expect(folderArrayArg).to.not.include('notExistentFolder')
}) })
tap.test('.fs.listFilesSync() -> should get the file type from a string', async () => { tap.test('.fs.listFilesSync() -> should get the file type from a string', async () => {
expect(smartfile.fs.listFilesSync('./test/')).to.deep.include('mytest.json') expect(smartfile.fs.listFilesSync('./test/')).to.include('mytest.json')
expect(smartfile.fs.listFilesSync('./test/')).to.not.deep.include('notExistentFile') expect(smartfile.fs.listFilesSync('./test/')).to.not.include('notExistentFile')
expect(smartfile.fs.listFilesSync('./test/', /mytest\.json/)).to.deep.include('mytest.json') expect(smartfile.fs.listFilesSync('./test/', /mytest\.json/)).to.include('mytest.json')
expect(smartfile.fs.listFilesSync('./test/', /mytests.json/)).to.not.deep.include('mytest.json') expect(smartfile.fs.listFilesSync('./test/', /mytests.json/)).to.not.include('mytest.json')
}) })
tap.test('.fs.listFiles() -> should get the file type from a string', async () => { tap.test('.fs.listFiles() -> should get the file type from a string', async () => {
let folderArrayArg = await smartfile.fs.listFiles('./test/') let folderArrayArg = await smartfile.fs.listFiles('./test/')
expect(folderArrayArg).to.deep.include('mytest.json') expect(folderArrayArg).to.include('mytest.json')
expect(folderArrayArg).to.not.deep.include('notExistentFile') expect(folderArrayArg).to.not.include('notExistentFile')
}) })
tap.test('.fs.listFileTree() -> should get a file tree', async () => { tap.test('.fs.listFileTree() -> should get a file tree', async () => {
let folderArrayArg = await smartfile.fs.listFileTree(path.resolve('./test/'), '**/*.txt') let folderArrayArg = await smartfile.fs.listFileTree(path.resolve('./test/'), '**/*.txt')
expect(folderArrayArg).to.deep.include('testfolder/testfile1.txt') expect(folderArrayArg).to.include('testfolder/testfile1.txt')
expect(folderArrayArg).to.not.deep.include('mytest.json') expect(folderArrayArg).to.not.include('mytest.json')
}) })
tap.test('.fs.fileTreeToObject -> should read a file tree into an Object', async () => { tap.test('.fs.fileTreeToObject -> should read a file tree into an Object', async () => {
@ -72,7 +74,7 @@ tap.test('.fs.remove() -> should remove an entire directory', async () => {
}) })
tap.test('.fs.remove -> should remove single files', async () => { tap.test('.fs.remove -> should remove single files', async () => {
await expect(smartfile.fs.remove('./test/temp/mytestRenamed.yaml')).to.eventually.be.fulfilled await smartfile.fs.remove('./test/temp/mytestRenamed.yaml')
}) })
tap.test('.fs.removeSync -> should remove single files synchronouly', async () => { tap.test('.fs.removeSync -> should remove single files synchronouly', async () => {
@ -95,8 +97,8 @@ tap.test('.fs.removeManySync -> should remove and array of single files synchron
tap.test('.fs.toObjectSync() -> should read an ' + '.yaml' + ' file to an object', async () => { tap.test('.fs.toObjectSync() -> should read an ' + '.yaml' + ' file to an object', async () => {
let testData = smartfile.fs.toObjectSync('./test/mytest.yaml') let testData = smartfile.fs.toObjectSync('./test/mytest.yaml')
expect(testData).have.property('key1', 'this works') expect(testData).to.include({'key1': 'this works'})
expect(testData).have.property('key2', 'this works too') expect(testData).to.include({'key2': 'this works too'})
}) })
tap.test('.fs.toObjectSync() -> should state unknown file type for unknown file types', async () => { tap.test('.fs.toObjectSync() -> should state unknown file type for unknown file types', async () => {
@ -105,8 +107,8 @@ tap.test('.fs.toObjectSync() -> should state unknown file type for unknown file
tap.test('.fs.toObjectSync() -> should read an ' + '.json' + ' file to an object', async () => { tap.test('.fs.toObjectSync() -> should read an ' + '.json' + ' file to an object', async () => {
let testData = smartfile.fs.toObjectSync('./test/mytest.json') let testData = smartfile.fs.toObjectSync('./test/mytest.json')
expect(testData).have.property('key1', 'this works') expect(testData).to.include({'key1': 'this works'})
expect(testData).have.property('key2', 'this works too') expect(testData).to.include({'key2': 'this works too'})
}) })
@ -150,9 +152,11 @@ tap.test('.remote.toString() -> should load a remote file to a variable', async
expect(responseString).to.equal('Some TestString &&%$') expect(responseString).to.equal('Some TestString &&%$')
}) })
tap.test('.remote.toString() -> should reject a Promise when the link is false', async () => { tap.test('.remote.toString() -> should reject a Promise when the link is false', async (tools) => {
await expect(smartfile.remote.toString('https://push.rocks/doesnotexist.txt')) tools.returnError
.to.eventually.be.rejected await smartfile.remote.toString('https://push.rocks/doesnotexist.txt').catch(err => {
return expect(err.message).to.equal('could not get remote file from https://push.rocks/doesnotexist.txt')
})
}) })
// --------------------------- // ---------------------------

View File

@ -1,4 +1,6 @@
import * as plugins from './smartfile.plugins' import * as plugins from './smartfile.plugins'
import * as fs from './smartfile.fs'
import * as memory from './smartfile.memory'
export interface ISmartfileConstructorOptions { export interface ISmartfileConstructorOptions {
path?: string path?: string
@ -68,9 +70,12 @@ export class Smartfile {
/** /**
* write file to disk * write file to disk
* Behaviours:
* - no argument write to exactly where the file was picked up
*/ */
async write () { async write (pathArg?: string) {
const stringToWrite = this.contentBuffer.toString()
await memory.toFs(stringToWrite, this.path)
} }
/** /**

View File

@ -1,4 +1,3 @@
import 'typings-global'
export import fs = require('fs') export import fs = require('fs')
export import fsExtra = require('fs-extra') export import fsExtra = require('fs-extra')
export let glob = require('glob') export let glob = require('glob')

View File

@ -42,7 +42,6 @@ export let toString = (fromArg: string) => {
if (res.statusCode === 200) { if (res.statusCode === 200) {
done.resolve(res.body) done.resolve(res.body)
} else { } else {
console.error('could not get remote file from ' + fromArg)
done.reject(new Error('could not get remote file from ' + fromArg)) done.reject(new Error('could not get remote file from ' + fromArg))
} }
}) })

263
yarn.lock
View File

@ -2,58 +2,23 @@
# yarn lockfile v1 # yarn lockfile v1
"@types/chai-as-promised@0.0.29": "@types/code@^4.0.3":
version "0.0.29"
resolved "https://registry.yarnpkg.com/@types/chai-as-promised/-/chai-as-promised-0.0.29.tgz#43d52892aa998e185a3de3e2477edb8573be1d77"
dependencies:
"@types/chai" "*"
"@types/promises-a-plus" "*"
"@types/chai-string@^1.1.30":
version "1.1.31"
resolved "https://registry.yarnpkg.com/@types/chai-string/-/chai-string-1.1.31.tgz#a22f75d713f69da8c5cf34f8bc808a62cd249405"
dependencies:
"@types/chai" "*"
"@types/chai@*":
version "4.0.4" version "4.0.4"
resolved "https://registry.yarnpkg.com/@types/chai/-/chai-4.0.4.tgz#fe86315d9a66827feeb16f73bc954688ec950e18" resolved "https://registry.yarnpkg.com/@types/code/-/code-4.0.4.tgz#527fbdbb487dabc4346b8a2ccca3496d8198bae7"
"@types/chai@^3.4.35": "@types/fs-extra@5.0.0":
version "3.5.2" version "5.0.0"
resolved "https://registry.yarnpkg.com/@types/chai/-/chai-3.5.2.tgz#c11cd2817d3a401b7ba0f5a420f35c56139b1c1e" resolved "https://registry.yarnpkg.com/@types/fs-extra/-/fs-extra-5.0.0.tgz#d3e225b35eb5c6d3a5a782c28219df365c781413"
"@types/fs-extra@4.x.x":
version "4.0.2"
resolved "https://registry.yarnpkg.com/@types/fs-extra/-/fs-extra-4.0.2.tgz#7b9b1bbf85962cbe029b5a83c9b530d7c75af3ba"
dependencies: dependencies:
"@types/node" "*" "@types/node" "*"
"@types/glob@*": "@types/node@*", "@types/node@^9.4.6":
version "5.0.32" version "9.4.6"
resolved "https://registry.yarnpkg.com/@types/glob/-/glob-5.0.32.tgz#aec5cfe987c72f099fdb1184452986aa506d5e8f" resolved "https://registry.yarnpkg.com/@types/node/-/node-9.4.6.tgz#d8176d864ee48753d053783e4e463aec86b8d82e"
dependencies:
"@types/minimatch" "*"
"@types/node" "*"
"@types/minimatch@*": "@types/node@^8.0.33":
version "3.0.1" version "8.9.4"
resolved "https://registry.yarnpkg.com/@types/minimatch/-/minimatch-3.0.1.tgz#b683eb60be358304ef146f5775db4c0e3696a550" resolved "https://registry.yarnpkg.com/@types/node/-/node-8.9.4.tgz#dfd327582a06c114eb6e0441fa3d6fab35edad48"
"@types/node@*":
version "8.0.28"
resolved "https://registry.yarnpkg.com/@types/node/-/node-8.0.28.tgz#86206716f8d9251cf41692e384264cbd7058ad60"
"@types/promises-a-plus@*":
version "0.0.27"
resolved "https://registry.yarnpkg.com/@types/promises-a-plus/-/promises-a-plus-0.0.27.tgz#c64651134614c84b8f5d7114ce8901d36a609780"
"@types/shelljs@^0.7.4":
version "0.7.4"
resolved "https://registry.yarnpkg.com/@types/shelljs/-/shelljs-0.7.4.tgz#137b5f31306eaff4de120ffe5b9d74b297809cfc"
dependencies:
"@types/glob" "*"
"@types/node" "*"
"@types/through2@^2.0.32": "@types/through2@^2.0.32":
version "2.0.33" version "2.0.33"
@ -61,30 +26,22 @@
dependencies: dependencies:
"@types/node" "*" "@types/node" "*"
"@types/vinyl@^2.0.1": "@types/vinyl@^2.0.2":
version "2.0.1" version "2.0.2"
resolved "https://registry.yarnpkg.com/@types/vinyl/-/vinyl-2.0.1.tgz#6b414dfdcd4a785e8e76e87565ed29e79490d9b7" resolved "https://registry.yarnpkg.com/@types/vinyl/-/vinyl-2.0.2.tgz#4f3b8dae8f5828d3800ef709b0cff488ee852de3"
dependencies: dependencies:
"@types/node" "*" "@types/node" "*"
"@types/which@^1.0.28":
version "1.0.28"
resolved "https://registry.yarnpkg.com/@types/which/-/which-1.0.28.tgz#016e387629b8817bed653fe32eab5d11279c8df6"
ansi-256-colors@^1.1.0: ansi-256-colors@^1.1.0:
version "1.1.0" version "1.1.0"
resolved "https://registry.yarnpkg.com/ansi-256-colors/-/ansi-256-colors-1.1.0.tgz#910de50efcc7c09e3d82f2f87abd6b700c18818a" resolved "https://registry.yarnpkg.com/ansi-256-colors/-/ansi-256-colors-1.1.0.tgz#910de50efcc7c09e3d82f2f87abd6b700c18818a"
argparse@^1.0.7: argparse@^1.0.7:
version "1.0.9" version "1.0.10"
resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.9.tgz#73d83bc263f86e97f8cc4f6bae1b0e90a7d22c86" resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.10.tgz#bcd6791ea5ae09725e17e5ad988134cd40b3d911"
dependencies: dependencies:
sprintf-js "~1.0.2" sprintf-js "~1.0.2"
assertion-error@^1.0.1:
version "1.0.2"
resolved "https://registry.yarnpkg.com/assertion-error/-/assertion-error-1.0.2.tgz#13ca515d86206da0bac66e834dd397d87581094c"
balanced-match@^1.0.0: balanced-match@^1.0.0:
version "1.0.0" version "1.0.0"
resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz#89b4d199ab2bee49de164ea02b89ce462d71b767" resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz#89b4d199ab2bee49de164ea02b89ce462d71b767"
@ -101,34 +58,12 @@ bindings@^1.2.1:
resolved "https://registry.yarnpkg.com/bindings/-/bindings-1.3.0.tgz#b346f6ecf6a95f5a815c5839fc7cdb22502f1ed7" resolved "https://registry.yarnpkg.com/bindings/-/bindings-1.3.0.tgz#b346f6ecf6a95f5a815c5839fc7cdb22502f1ed7"
brace-expansion@^1.1.7: brace-expansion@^1.1.7:
version "1.1.8" version "1.1.11"
resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.8.tgz#c07b211c7c952ec1f8efd51a77ef0d1d3990a292" resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.11.tgz#3c7fcbf529d87226f3d2f52b966ff5271eb441dd"
dependencies: dependencies:
balanced-match "^1.0.0" balanced-match "^1.0.0"
concat-map "0.0.1" concat-map "0.0.1"
chai-as-promised@^6.0.0:
version "6.0.0"
resolved "https://registry.yarnpkg.com/chai-as-promised/-/chai-as-promised-6.0.0.tgz#1a02a433a6f24dafac63b9c96fa1684db1aa8da6"
dependencies:
check-error "^1.0.2"
chai-string@^1.3.0:
version "1.4.0"
resolved "https://registry.yarnpkg.com/chai-string/-/chai-string-1.4.0.tgz#359140c051d36a4e4b1a5fc6b910152f438a8d49"
chai@^3.5.0:
version "3.5.0"
resolved "https://registry.yarnpkg.com/chai/-/chai-3.5.0.tgz#4d02637b067fe958bdbfdd3a40ec56fef7373247"
dependencies:
assertion-error "^1.0.1"
deep-eql "^0.1.3"
type-detect "^1.0.0"
check-error@^1.0.2:
version "1.0.2"
resolved "https://registry.yarnpkg.com/check-error/-/check-error-1.0.2.tgz#574d312edd88bb5dd8912e9286dd6c0aed4aac82"
clone-buffer@^1.0.0: clone-buffer@^1.0.0:
version "1.0.0" version "1.0.0"
resolved "https://registry.yarnpkg.com/clone-buffer/-/clone-buffer-1.0.0.tgz#e3e25b207ac4e701af721e2cb5a16792cac3dc58" resolved "https://registry.yarnpkg.com/clone-buffer/-/clone-buffer-1.0.0.tgz#e3e25b207ac4e701af721e2cb5a16792cac3dc58"
@ -149,6 +84,12 @@ cloneable-readable@^1.0.0:
process-nextick-args "^1.0.6" process-nextick-args "^1.0.6"
through2 "^2.0.1" through2 "^2.0.1"
code@^5.1.0:
version "5.2.0"
resolved "https://registry.yarnpkg.com/code/-/code-5.2.0.tgz#fb3a5e247afc17e3d65c49e7ce0f69ebe51a75b5"
dependencies:
hoek "5.x.x"
concat-map@0.0.1: concat-map@0.0.1:
version "0.0.1" version "0.0.1"
resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b"
@ -157,12 +98,6 @@ core-util-is@~1.0.0:
version "1.0.2" version "1.0.2"
resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7"
deep-eql@^0.1.3:
version "0.1.3"
resolved "https://registry.yarnpkg.com/deep-eql/-/deep-eql-0.1.3.tgz#ef558acab8de25206cd713906d74e56930eb69f2"
dependencies:
type-detect "0.1.1"
define-properties@^1.1.2: define-properties@^1.1.2:
version "1.1.2" version "1.1.2"
resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.1.2.tgz#83a73f2fea569898fb737193c8f873caf6d45c94" resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.1.2.tgz#83a73f2fea569898fb737193c8f873caf6d45c94"
@ -179,8 +114,8 @@ early@^2.1.1:
typings-global "^1.0.16" typings-global "^1.0.16"
es-abstract@^1.5.1: es-abstract@^1.5.1:
version "1.8.2" version "1.10.0"
resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.8.2.tgz#25103263dc4decbda60e0c737ca32313518027ee" resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.10.0.tgz#1ecb36c197842a00d8ee4c2dfd8646bb97d60864"
dependencies: dependencies:
es-to-primitive "^1.1.1" es-to-primitive "^1.1.1"
function-bind "^1.1.1" function-bind "^1.1.1"
@ -197,8 +132,8 @@ es-to-primitive@^1.1.1:
is-symbol "^1.0.1" is-symbol "^1.0.1"
es6-error@^4.0.2: es6-error@^4.0.2:
version "4.0.2" version "4.1.1"
resolved "https://registry.yarnpkg.com/es6-error/-/es6-error-4.0.2.tgz#eec5c726eacef51b7f6b73c20db6e1b13b069c98" resolved "https://registry.yarnpkg.com/es6-error/-/es6-error-4.1.1.tgz#9e3af407459deed47e9a91f9b885a84eb05c561d"
esprima@^4.0.0: esprima@^4.0.0:
version "4.0.0" version "4.0.0"
@ -214,9 +149,9 @@ foreach@^2.0.5:
version "2.0.5" version "2.0.5"
resolved "https://registry.yarnpkg.com/foreach/-/foreach-2.0.5.tgz#0bee005018aeb260d0a3af3ae658dd0136ec1b99" resolved "https://registry.yarnpkg.com/foreach/-/foreach-2.0.5.tgz#0bee005018aeb260d0a3af3ae658dd0136ec1b99"
fs-extra@^4.0.2: fs-extra@^5.0.0:
version "4.0.2" version "5.0.0"
resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-4.0.2.tgz#f91704c53d1b461f893452b0c307d9997647ab6b" resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-5.0.0.tgz#414d0110cdd06705734d055652c5411260c31abd"
dependencies: dependencies:
graceful-fs "^4.1.2" graceful-fs "^4.1.2"
jsonfile "^4.0.0" jsonfile "^4.0.0"
@ -230,7 +165,7 @@ function-bind@^1.0.2, function-bind@^1.1.1:
version "1.1.1" version "1.1.1"
resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d"
glob@^7.0.0, glob@^7.1.2: glob@^7.1.2:
version "7.1.2" version "7.1.2"
resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.2.tgz#c19c9df9a028702d678612384a6552404c636d15" resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.2.tgz#c19c9df9a028702d678612384a6552404c636d15"
dependencies: dependencies:
@ -245,14 +180,13 @@ graceful-fs@^4.1.2, graceful-fs@^4.1.6:
version "4.1.11" version "4.1.11"
resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.11.tgz#0e8bdfe4d1ddb8854d64e04ea7c00e2a026e5658" resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.11.tgz#0e8bdfe4d1ddb8854d64e04ea7c00e2a026e5658"
gulp-function@^2.2.9: gulp-function@^2.2.14:
version "2.2.9" version "2.2.14"
resolved "https://registry.yarnpkg.com/gulp-function/-/gulp-function-2.2.9.tgz#de513103db9d817e94bb8aab45f30bf286f19ae5" resolved "https://registry.yarnpkg.com/gulp-function/-/gulp-function-2.2.14.tgz#e2fe65cfd2f7f614a2c66795e2ae4440467082df"
dependencies: dependencies:
"@types/through2" "^2.0.32" "@types/through2" "^2.0.32"
smartq "^1.1.1" smartq "^1.1.6"
through2 "^2.0.3" through2 "^2.0.3"
typings-global "^1.0.16"
has@^1.0.1: has@^1.0.1:
version "1.0.1" version "1.0.1"
@ -260,6 +194,10 @@ has@^1.0.1:
dependencies: dependencies:
function-bind "^1.0.2" function-bind "^1.0.2"
hoek@5.x.x:
version "5.0.3"
resolved "https://registry.yarnpkg.com/hoek/-/hoek-5.0.3.tgz#b71d40d943d0a95da01956b547f83c4a5b4a34ac"
home@^1.0.1: home@^1.0.1:
version "1.0.1" version "1.0.1"
resolved "https://registry.yarnpkg.com/home/-/home-1.0.1.tgz#96a423ceb49b98378ff5ef3ceae059a557f9dd35" resolved "https://registry.yarnpkg.com/home/-/home-1.0.1.tgz#96a423ceb49b98378ff5ef3ceae059a557f9dd35"
@ -277,10 +215,6 @@ inherits@2, inherits@^2.0.1, inherits@~2.0.3:
version "2.0.3" version "2.0.3"
resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.3.tgz#633c2c83e3da42a502f52466022480f4208261de" resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.3.tgz#633c2c83e3da42a502f52466022480f4208261de"
interpret@^1.0.0:
version "1.0.4"
resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.0.4.tgz#820cdd588b868ffb191a809506d6c9c8f212b1b0"
is-callable@^1.1.1, is-callable@^1.1.3: is-callable@^1.1.1, is-callable@^1.1.3:
version "1.1.3" version "1.1.3"
resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.1.3.tgz#86eb75392805ddc33af71c92a0eedf74ee7604b2" resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.1.3.tgz#86eb75392805ddc33af71c92a0eedf74ee7604b2"
@ -307,10 +241,6 @@ isarray@~1.0.0:
version "1.0.0" version "1.0.0"
resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11" resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11"
isexe@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10"
js-yaml@^3.10.0: js-yaml@^3.10.0:
version "3.10.0" version "3.10.0"
resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.10.0.tgz#2e78441646bd4682e963f22b6e92823c309c62dc" resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.10.0.tgz#2e78441646bd4682e963f22b6e92823c309c62dc"
@ -335,8 +265,8 @@ leakage@^0.3.0:
pretty-bytes "^4.0.2" pretty-bytes "^4.0.2"
left-pad@^1.1.3: left-pad@^1.1.3:
version "1.1.3" version "1.2.0"
resolved "https://registry.yarnpkg.com/left-pad/-/left-pad-1.1.3.tgz#612f61c033f3a9e08e939f1caebeea41b6f3199a" resolved "https://registry.yarnpkg.com/left-pad/-/left-pad-1.2.0.tgz#d30a73c6b8201d8f7d8e7956ba9616087a68e0ee"
memwatch-next@^0.3.0: memwatch-next@^0.3.0:
version "0.3.0" version "0.3.0"
@ -356,8 +286,8 @@ minimist@^1.2.0:
resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz#a35008b20f41383eec1fb914f4cd5df79a264284" resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz#a35008b20f41383eec1fb914f4cd5df79a264284"
nan@^2.3.2: nan@^2.3.2:
version "2.7.0" version "2.8.0"
resolved "https://registry.yarnpkg.com/nan/-/nan-2.7.0.tgz#d95bf721ec877e08db276ed3fc6eb78f9083ad46" resolved "https://registry.yarnpkg.com/nan/-/nan-2.8.0.tgz#ed715f3fe9de02b57a5e6252d90a96675e1f085a"
object-keys@^1.0.8: object-keys@^1.0.8:
version "1.0.11" version "1.0.11"
@ -384,10 +314,6 @@ path-is-absolute@^1.0.0:
version "1.0.1" version "1.0.1"
resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f"
path-parse@^1.0.5:
version "1.0.5"
resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.5.tgz#3c1adf871ea9cd6c9431b6ea2bd74a0ff055c4c1"
pify@^2.3.0: pify@^2.3.0:
version "2.3.0" version "2.3.0"
resolved "https://registry.yarnpkg.com/pify/-/pify-2.3.0.tgz#ed141a6ac043a849ea588498e7dca8b15330e90c" resolved "https://registry.yarnpkg.com/pify/-/pify-2.3.0.tgz#ed141a6ac043a849ea588498e7dca8b15330e90c"
@ -396,28 +322,26 @@ pretty-bytes@^4.0.2:
version "4.0.2" version "4.0.2"
resolved "https://registry.yarnpkg.com/pretty-bytes/-/pretty-bytes-4.0.2.tgz#b2bf82e7350d65c6c33aa95aaa5a4f6327f61cd9" resolved "https://registry.yarnpkg.com/pretty-bytes/-/pretty-bytes-4.0.2.tgz#b2bf82e7350d65c6c33aa95aaa5a4f6327f61cd9"
process-nextick-args@^1.0.6, process-nextick-args@~1.0.6: process-nextick-args@^1.0.6:
version "1.0.7" version "1.0.7"
resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-1.0.7.tgz#150e20b756590ad3f91093f25a4f2ad8bff30ba3" resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-1.0.7.tgz#150e20b756590ad3f91093f25a4f2ad8bff30ba3"
process-nextick-args@~2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.0.tgz#a37d732f4271b4ab1ad070d35508e8290788ffaa"
readable-stream@^2.0.2, readable-stream@^2.1.5: readable-stream@^2.0.2, readable-stream@^2.1.5:
version "2.3.3" version "2.3.4"
resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.3.tgz#368f2512d79f9d46fdfc71349ae7878bbc1eb95c" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.4.tgz#c946c3f47fa7d8eabc0b6150f4a12f69a4574071"
dependencies: dependencies:
core-util-is "~1.0.0" core-util-is "~1.0.0"
inherits "~2.0.3" inherits "~2.0.3"
isarray "~1.0.0" isarray "~1.0.0"
process-nextick-args "~1.0.6" process-nextick-args "~2.0.0"
safe-buffer "~5.1.1" safe-buffer "~5.1.1"
string_decoder "~1.0.3" string_decoder "~1.0.3"
util-deprecate "~1.0.1" util-deprecate "~1.0.1"
rechoir@^0.6.2:
version "0.6.2"
resolved "https://registry.yarnpkg.com/rechoir/-/rechoir-0.6.2.tgz#85204b54dba82d5742e28c96756ef43af50e3384"
dependencies:
resolve "^1.1.6"
remove-trailing-separator@^1.0.1: remove-trailing-separator@^1.0.1:
version "1.1.0" version "1.1.0"
resolved "https://registry.yarnpkg.com/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz#c24bce2a283adad5bc3f58e0d48249b92379d8ef" resolved "https://registry.yarnpkg.com/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz#c24bce2a283adad5bc3f58e0d48249b92379d8ef"
@ -430,42 +354,21 @@ require-reload@0.2.2:
version "0.2.2" version "0.2.2"
resolved "https://registry.yarnpkg.com/require-reload/-/require-reload-0.2.2.tgz#29a7591846caf91b6e8a3cda991683f95f8d7d42" resolved "https://registry.yarnpkg.com/require-reload/-/require-reload-0.2.2.tgz#29a7591846caf91b6e8a3cda991683f95f8d7d42"
resolve@^1.1.6:
version "1.4.0"
resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.4.0.tgz#a75be01c53da25d934a98ebd0e4c4a7312f92a86"
dependencies:
path-parse "^1.0.5"
safe-buffer@~5.1.0, safe-buffer@~5.1.1: safe-buffer@~5.1.0, safe-buffer@~5.1.1:
version "5.1.1" version "5.1.1"
resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.1.tgz#893312af69b2123def71f57889001671eeb2c853" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.1.tgz#893312af69b2123def71f57889001671eeb2c853"
semver@^5.3.0:
version "5.4.1"
resolved "https://registry.yarnpkg.com/semver/-/semver-5.4.1.tgz#e059c09d8571f0540823733433505d3a2f00b18e"
shelljs@^0.7.8:
version "0.7.8"
resolved "https://registry.yarnpkg.com/shelljs/-/shelljs-0.7.8.tgz#decbcf874b0d1e5fb72e14b164a9683048e9acb3"
dependencies:
glob "^7.0.0"
interpret "^1.0.0"
rechoir "^0.6.2"
smartchai@^1.0.3: smartchai@^1.0.3:
version "1.0.3" version "1.0.8"
resolved "https://registry.yarnpkg.com/smartchai/-/smartchai-1.0.3.tgz#de6d010bb8b5aef24cb70b31a5f5334e8c41b72f" resolved "https://registry.yarnpkg.com/smartchai/-/smartchai-1.0.8.tgz#a074836f4ddd4b98c50f1e7ae9e8e8ad9f6f1902"
dependencies: dependencies:
"@types/chai" "^3.4.35" "@types/code" "^4.0.3"
"@types/chai-as-promised" "0.0.29" code "^5.1.0"
"@types/chai-string" "^1.1.30" typings-global "^1.0.20"
chai "^3.5.0"
chai-as-promised "^6.0.0"
chai-string "^1.3.0"
smartdelay@^1.0.3: smartdelay@^1.0.3:
version "1.0.3" version "1.0.4"
resolved "https://registry.yarnpkg.com/smartdelay/-/smartdelay-1.0.3.tgz#5fd44dad77262d110702f0293efa80c072cfb579" resolved "https://registry.yarnpkg.com/smartdelay/-/smartdelay-1.0.4.tgz#791c1a4ee6770494064c10b1d2d2b8e6f3105b82"
dependencies: dependencies:
smartq "^1.1.1" smartq "^1.1.1"
typings-global "^1.0.16" typings-global "^1.0.16"
@ -484,23 +387,11 @@ smartq@^1.1.1, smartq@^1.1.6:
typings-global "^1.0.19" typings-global "^1.0.19"
util.promisify "^1.0.0" util.promisify "^1.0.0"
smartrequest@^1.0.6: smartrequest@^1.0.8:
version "1.0.6" version "1.0.8"
resolved "https://registry.yarnpkg.com/smartrequest/-/smartrequest-1.0.6.tgz#a006454332453b0a70d38a003a29963d039a7783" resolved "https://registry.yarnpkg.com/smartrequest/-/smartrequest-1.0.8.tgz#9af18dde34efa7d43b4ecfc92ccb157a98eda3b1"
dependencies: dependencies:
smartq "^1.1.1" smartq "^1.1.1"
typings-global "^1.0.17"
smartshell@^1.0.6:
version "1.0.18"
resolved "https://registry.yarnpkg.com/smartshell/-/smartshell-1.0.18.tgz#b84ccc65cedf3a875bf676cec78ee07f4b4aa9e5"
dependencies:
"@types/shelljs" "^0.7.4"
"@types/which" "^1.0.28"
shelljs "^0.7.8"
smartq "^1.1.6"
typings-global "^1.0.20"
which "^1.3.0"
sprintf-js@~1.0.2: sprintf-js@~1.0.2:
version "1.0.3" version "1.0.3"
@ -531,10 +422,11 @@ strip-bom@^2.0.0:
dependencies: dependencies:
is-utf8 "^0.2.0" is-utf8 "^0.2.0"
tapbundle@^1.1.1: tapbundle@^1.1.8:
version "1.1.1" version "1.1.8"
resolved "https://registry.yarnpkg.com/tapbundle/-/tapbundle-1.1.1.tgz#ec4172c0e82a77b1f6133fef2606311ede28a62d" resolved "https://registry.yarnpkg.com/tapbundle/-/tapbundle-1.1.8.tgz#e08aee0e100a830d8a26a583a85d37ce53312e02"
dependencies: dependencies:
"@types/node" "^8.0.33"
early "^2.1.1" early "^2.1.1"
leakage "^0.3.0" leakage "^0.3.0"
smartchai "^1.0.3" smartchai "^1.0.3"
@ -549,20 +441,9 @@ through2@^2.0.1, through2@^2.0.3:
readable-stream "^2.1.5" readable-stream "^2.1.5"
xtend "~4.0.1" xtend "~4.0.1"
type-detect@0.1.1: typings-global@^1.0.14, typings-global@^1.0.16, typings-global@^1.0.19, typings-global@^1.0.20:
version "0.1.1" version "1.0.28"
resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-0.1.1.tgz#0ba5ec2a885640e470ea4e8505971900dac58822" resolved "https://registry.yarnpkg.com/typings-global/-/typings-global-1.0.28.tgz#e28cc965476564cbc00e438739e0aa0735d323d4"
type-detect@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-1.0.0.tgz#762217cc06db258ec48908a1298e8b95121e8ea2"
typings-global@^1.0.14, typings-global@^1.0.16, typings-global@^1.0.17, typings-global@^1.0.19, typings-global@^1.0.20:
version "1.0.20"
resolved "https://registry.yarnpkg.com/typings-global/-/typings-global-1.0.20.tgz#3da769c54db538247c5d877d1d9e97eb2ec981ff"
dependencies:
semver "^5.3.0"
smartshell "^1.0.6"
universalify@^0.1.0: universalify@^0.1.0:
version "0.1.1" version "0.1.1"
@ -600,12 +481,6 @@ vinyl@^2.0.1:
remove-trailing-separator "^1.0.1" remove-trailing-separator "^1.0.1"
replace-ext "^1.0.0" replace-ext "^1.0.0"
which@^1.3.0:
version "1.3.0"
resolved "https://registry.yarnpkg.com/which/-/which-1.3.0.tgz#ff04bdfc010ee547d780bec38e1ac1c2777d253a"
dependencies:
isexe "^2.0.0"
wrappy@1: wrappy@1:
version "1.0.2" version "1.0.2"
resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f"