Skip to content

Commit

Permalink
updated hooks
Browse files Browse the repository at this point in the history
  • Loading branch information
jdx committed Jan 2, 2018
1 parent bb82675 commit 7665b14
Show file tree
Hide file tree
Showing 3 changed files with 118 additions and 29 deletions.
12 changes: 6 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,18 +29,18 @@
},
"dependencies": {
"@cli-engine/command": "^12.0.3",
"@cli-engine/config": "^5.0.10",
"@cli-engine/engine": "^6.1.9",
"@cli-engine/config": "^5.0.11",
"@cli-engine/engine": "^6.1.12",
"cli-engine-example-plugin": "^3.0.8",
"cli-flags": "^2.0.6",
"cli-ux": "^2.0.17",
"cli-flags": "^2.0.7",
"cli-ux": "^2.0.21",
"debug": "^3.1.0"
},
"devDependencies": {
"@cli-engine/util": "^1.0.9",
"@cli-engine/util": "^1.0.10",
"@heroku-cli/tslint": "^1.0.3",
"@types/ansi-styles": "^2.0.30",
"@types/jest": "^21.1.9",
"@types/jest": "^22.0.0",
"@types/node": "8.5.2",
"jest": "22.0.4",
"prettier": "^1.9.2",
Expand Down
6 changes: 3 additions & 3 deletions src/hooks/plugins/parse/legacy.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Hook, IHooks } from '@cli-engine/engine/lib/hooks'
import { Hook } from '@cli-engine/engine/lib/hooks'

function getID(c: any): string {
let id = []
Expand All @@ -8,8 +8,8 @@ function getID(c: any): string {
}

export default class PluginsParseTestHook extends Hook<'plugins:parse'> {
async run(opts: IHooks['plugins:parse']) {
const m = opts.module
async run() {
const m = this.options.module
m.commands = m.commands.map((c: any) => {
if (!c.id) c.id = getID(c)
return c
Expand Down
129 changes: 109 additions & 20 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -22,38 +22,46 @@
version "5.0.10"
resolved "https://registry.yarnpkg.com/@cli-engine/config/-/config-5.0.10.tgz#f8420b9c4cd44e4feafeb90165d9557168bb484c"

"@cli-engine/engine@^6.1.9":
version "6.1.9"
resolved "https://registry.yarnpkg.com/@cli-engine/engine/-/engine-6.1.9.tgz#9937edd007225a4f219fe8bab60673ead9340eb4"
"@cli-engine/config@^5.0.11":
version "5.0.11"
resolved "https://registry.yarnpkg.com/@cli-engine/config/-/config-5.0.11.tgz#b3b1393da09469fbcaaa99329064e775e275de24"

"@cli-engine/engine@^6.1.12":
version "6.1.12"
resolved "https://registry.yarnpkg.com/@cli-engine/engine/-/engine-6.1.12.tgz#4afafc1049823ef204cb63a68d1566a2b1056cb7"
dependencies:
"@heroku-cli/color" "^1.0.4"
assync "^1.0.4"
cli-ux "^2.0.17"
cli-ux "^2.0.21"
cross-spawn "^5.1.0"
debug "^3.1.0"
filesize "^3.5.11"
fs-extra "^5.0.0"
graceful-fs "^4.1.11"
http-call "^4.0.6"
klaw "^2.1.1"
log-chopper "^1.0.2"
moment "^2.20.1"
rwlockfile "^1.4.12"
rwlockfile "^2.0.13"
semver "5.4.1"
string-similarity "^1.2.0"
strip-ansi "4.0.0"
tar-fs "^1.16.0"
ts-lodash "4.0.8"
yarn "^1.3.2"

"@cli-engine/screen@^0.0.0":
version "0.0.0"
resolved "https://registry.yarnpkg.com/@cli-engine/screen/-/screen-0.0.0.tgz#c2e847c7d4d998490c9097282bf21637d5162116"

"@cli-engine/util@^1.0.9":
version "1.0.9"
resolved "https://registry.yarnpkg.com/@cli-engine/util/-/util-1.0.9.tgz#f97b94083a9700a7e6af1b4561afe0b87f9ed87e"
"@cli-engine/util@^1.0.10":
version "1.0.11"
resolved "https://registry.yarnpkg.com/@cli-engine/util/-/util-1.0.11.tgz#b5bc3071d6b4feb3e63a2c6713517d1a6b4bc655"
dependencies:
"@cli-engine/command" "^12.0.3"
"@cli-engine/config" "^5.0.10"
"@cli-engine/engine" "^6.1.9"
cli-ux "^2.0.17"
"@cli-engine/config" "^5.0.11"
"@cli-engine/engine" "^6.1.12"
cli-ux "^2.0.21"
cross-spawn "^5.1.0"
del "^3.0.0"
fs-extra "^5.0.0"
Expand Down Expand Up @@ -81,9 +89,9 @@
version "2.0.30"
resolved "https://registry.yarnpkg.com/@types/ansi-styles/-/ansi-styles-2.0.30.tgz#9a645299020a224afc6a8cd055195850b3c2af85"

"@types/jest@^21.1.9":
version "21.1.9"
resolved "https://registry.yarnpkg.com/@types/jest/-/jest-21.1.9.tgz#a913d6224e9d8a1f24908af536f65b5bf4d489bc"
"@types/jest@^22.0.0":
version "22.0.0"
resolved "https://registry.yarnpkg.com/@types/jest/-/jest-22.0.0.tgz#23009941178aad7979a9591e026f7a96054d7bc0"

"@types/node@*", "@types/[email protected]":
version "8.5.2"
Expand Down Expand Up @@ -463,6 +471,12 @@ bindings@^1.2.1:
version "1.3.0"
resolved "https://registry.yarnpkg.com/bindings/-/bindings-1.3.0.tgz#b346f6ecf6a95f5a815c5839fc7cdb22502f1ed7"

bl@^1.0.0:
version "1.2.1"
resolved "https://registry.yarnpkg.com/bl/-/bl-1.2.1.tgz#cac328f7bee45730d404b692203fcb590e172d5e"
dependencies:
readable-stream "^2.0.5"

block-stream@*:
version "0.0.9"
resolved "https://registry.yarnpkg.com/block-stream/-/block-stream-0.0.9.tgz#13ebfe778a03205cfe03751481ebb4b3300c126a"
Expand Down Expand Up @@ -589,6 +603,10 @@ chokidar@^1.6.0:
optionalDependencies:
fsevents "^1.0.0"

chownr@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/chownr/-/chownr-1.0.1.tgz#e2a75042a9551908bebd25b8523d5f9769d79181"

ci-info@^1.0.0:
version "1.1.2"
resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-1.1.2.tgz#03561259db48d0474c8bdc90f5b47b068b6bbfb4"
Expand All @@ -611,7 +629,15 @@ cli-flags@^2.0.4, cli-flags@^2.0.6:
"@heroku/linewrap" "^1.0.0"
ts-lodash "^4.0.8"

cli-ux@^2.0.16, cli-ux@^2.0.17:
cli-flags@^2.0.7:
version "2.0.7"
resolved "https://registry.yarnpkg.com/cli-flags/-/cli-flags-2.0.7.tgz#215b3f8d911142c3e4833eaf7f2f96ab97fd22cf"
dependencies:
"@cli-engine/screen" "^0.0.0"
"@heroku/linewrap" "^1.0.0"
ts-lodash "^4.0.8"

cli-ux@^2.0.16:
version "2.0.17"
resolved "https://registry.yarnpkg.com/cli-ux/-/cli-ux-2.0.17.tgz#8e510cf169f6ad5ea70ca7a430d166a9b6b33ddf"
dependencies:
Expand All @@ -629,6 +655,24 @@ cli-ux@^2.0.16, cli-ux@^2.0.17:
supports-color "^5.1.0"
ts-lodash "^4.0.8"

cli-ux@^2.0.21:
version "2.0.21"
resolved "https://registry.yarnpkg.com/cli-ux/-/cli-ux-2.0.21.tgz#a7231097af95356e79f5d6a380f04be889703083"
dependencies:
"@cli-engine/screen" "^0.0.0"
"@heroku-cli/color" "^1.0.4"
"@heroku/linewrap" "^1.0.0"
ansi-escapes "^3.0.0"
ansi-styles "^3.2.0"
cardinal "^1.0.0"
chalk "^2.3.0"
lodash "^4.17.4"
moment "^2.20.1"
password-prompt "^1.0.3"
strip-ansi "^4.0.0"
supports-color "^5.1.0"
ts-lodash "^4.0.8"

cliui@^2.1.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/cliui/-/cliui-2.1.0.tgz#4b475760ff80264c762c3a1719032e91c7fea0d1"
Expand Down Expand Up @@ -841,6 +885,12 @@ ecc-jsbn@~0.1.1:
dependencies:
jsbn "~0.1.0"

end-of-stream@^1.0.0, end-of-stream@^1.1.0:
version "1.4.0"
resolved "https://registry.yarnpkg.com/end-of-stream/-/end-of-stream-1.4.0.tgz#7a90d833efda6cfa6eac0f4949dbb0fad3a63206"
dependencies:
once "^1.4.0"

error-ex@^1.2.0:
version "1.3.1"
resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.1.tgz#f855a86ce61adc4e8621c3cda21e7a7612c3a8dc"
Expand Down Expand Up @@ -988,6 +1038,10 @@ fileset@^2.0.2:
glob "^7.0.3"
minimatch "^3.0.3"

filesize@^3.5.11:
version "3.5.11"
resolved "https://registry.yarnpkg.com/filesize/-/filesize-3.5.11.tgz#1919326749433bb3cf77368bd158caabcc19e9ee"

fill-range@^2.1.0:
version "2.2.3"
resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-2.2.3.tgz#50b77dfd7e469bc7492470963699fe7a8485a723"
Expand Down Expand Up @@ -2172,7 +2226,7 @@ object.omit@^2.0.0:
for-own "^0.1.4"
is-extendable "^0.1.1"

once@^1.3.0, once@^1.3.3, once@^1.4.0:
once@^1.3.0, once@^1.3.1, once@^1.3.3, once@^1.4.0:
version "1.4.0"
resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1"
dependencies:
Expand Down Expand Up @@ -2366,6 +2420,13 @@ pseudomap@^1.0.2:
version "1.0.2"
resolved "https://registry.yarnpkg.com/pseudomap/-/pseudomap-1.0.2.tgz#f052a28da70e618917ef0a8ac34c1ae5a68286b3"

pump@^1.0.0:
version "1.0.3"
resolved "https://registry.yarnpkg.com/pump/-/pump-1.0.3.tgz#5dfe8311c33bbf6fc18261f9f34702c47c08a954"
dependencies:
end-of-stream "^1.1.0"
once "^1.3.1"

punycode@^1.4.1:
version "1.4.1"
resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e"
Expand Down Expand Up @@ -2413,7 +2474,7 @@ read-pkg@^1.0.0:
normalize-package-data "^2.3.2"
path-type "^1.0.0"

readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.6, readable-stream@^2.1.4:
readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.5, readable-stream@^2.0.6, readable-stream@^2.1.4:
version "2.3.3"
resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.3.tgz#368f2512d79f9d46fdfc71349ae7878bbc1eb95c"
dependencies:
Expand Down Expand Up @@ -2572,11 +2633,13 @@ rimraf@2, rimraf@^2.2.8, rimraf@^2.5.1, rimraf@^2.5.4, rimraf@^2.6.1:
dependencies:
glob "^7.0.5"

rwlockfile@^1.4.12:
version "1.4.12"
resolved "https://registry.yarnpkg.com/rwlockfile/-/rwlockfile-1.4.12.tgz#40cef17c915207c4315c1f535a006e0d1556bcd8"
rwlockfile@^2.0.13:
version "2.0.13"
resolved "https://registry.yarnpkg.com/rwlockfile/-/rwlockfile-2.0.13.tgz#e15d36223d53160102721fa139eefa46ec9a8892"
dependencies:
fs-extra "^5.0.0"
tslib "^1.8.1"
uuid "^3.1.0"

safe-buffer@^5.0.1, safe-buffer@^5.1.1, safe-buffer@~5.1.0, safe-buffer@~5.1.1:
version "5.1.1"
Expand Down Expand Up @@ -2821,6 +2884,15 @@ symbol-tree@^3.2.1:
version "3.2.2"
resolved "https://registry.yarnpkg.com/symbol-tree/-/symbol-tree-3.2.2.tgz#ae27db38f660a7ae2e1c3b7d1bc290819b8519e6"

tar-fs@^1.16.0:
version "1.16.0"
resolved "https://registry.yarnpkg.com/tar-fs/-/tar-fs-1.16.0.tgz#e877a25acbcc51d8c790da1c57c9cf439817b896"
dependencies:
chownr "^1.0.1"
mkdirp "^0.5.1"
pump "^1.0.0"
tar-stream "^1.1.2"

tar-pack@^3.4.0:
version "3.4.1"
resolved "https://registry.yarnpkg.com/tar-pack/-/tar-pack-3.4.1.tgz#e1dbc03a9b9d3ba07e896ad027317eb679a10a1f"
Expand All @@ -2834,6 +2906,15 @@ tar-pack@^3.4.0:
tar "^2.2.1"
uid-number "^0.0.6"

tar-stream@^1.1.2:
version "1.5.5"
resolved "https://registry.yarnpkg.com/tar-stream/-/tar-stream-1.5.5.tgz#5cad84779f45c83b1f2508d96b09d88c7218af55"
dependencies:
bl "^1.0.0"
end-of-stream "^1.0.0"
readable-stream "^2.0.0"
xtend "^4.0.0"

tar@^2.2.1:
version "2.2.1"
resolved "https://registry.yarnpkg.com/tar/-/tar-2.2.1.tgz#8e4d2a256c0e2185c6b18ad694aec968b83cb1d1"
Expand Down Expand Up @@ -3095,6 +3176,10 @@ xml-name-validator@^2.0.1:
version "2.0.1"
resolved "https://registry.yarnpkg.com/xml-name-validator/-/xml-name-validator-2.0.1.tgz#4d8b8f1eccd3419aa362061becef515e1e559635"

xtend@^4.0.0:
version "4.0.1"
resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.1.tgz#a5c6d532be656e23db820efb943a1f04998d63af"

y18n@^3.2.1:
version "3.2.1"
resolved "https://registry.yarnpkg.com/y18n/-/y18n-3.2.1.tgz#6d15fba884c08679c0d77e88e7759e811e07fa41"
Expand Down Expand Up @@ -3134,3 +3219,7 @@ yargs@~3.10.0:
cliui "^2.1.0"
decamelize "^1.0.0"
window-size "0.1.0"

yarn@^1.3.2:
version "1.3.2"
resolved "https://registry.yarnpkg.com/yarn/-/yarn-1.3.2.tgz#5939762581b5b4ddcd3418c0f6be42df3aee195f"

0 comments on commit 7665b14

Please sign in to comment.