Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: bump to kui-core 5.5.3 #25

Merged
merged 1 commit into from
Nov 30, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
431 changes: 179 additions & 252 deletions package-lock.json

Large diffs are not rendered by default.

26 changes: 13 additions & 13 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,22 +39,22 @@
],
"license": "Apache-2.0",
"devDependencies": {
"@kui-shell/builder": "5.4.4",
"@kui-shell/core": "5.4.4",
"@kui-shell/plugin-bash-like": "5.4.4",
"@kui-shell/plugin-core-support": "5.4.4",
"@kui-shell/plugin-editor": "5.4.4",
"@kui-shell/plugin-proxy-support": "5.4.4",
"@kui-shell/proxy": "5.4.4",
"@kui-shell/test": "5.4.4",
"@kui-shell/webpack": "5.4.4",
"@kui-shell/builder": "5.5.3",
"@kui-shell/core": "5.5.3",
"@kui-shell/plugin-bash-like": "5.5.3",
"@kui-shell/plugin-core-support": "5.5.3",
"@kui-shell/plugin-editor": "5.5.3",
"@kui-shell/plugin-proxy-support": "5.5.3",
"@kui-shell/proxy": "5.5.3",
"@kui-shell/test": "5.5.3",
"@kui-shell/webpack": "5.5.3",
"@types/mocha": "5.2.7",
"@types/node": "12.12.12",
"@types/node": "12.12.14",
"@types/swagger-schema-official": "^2.0.20",
"@types/uuid": "3.4.6",
"@types/webdriverio": "4.13.3",
"@typescript-eslint/eslint-plugin": "2.8.0",
"@typescript-eslint/parser": "2.8.0",
"@typescript-eslint/eslint-plugin": "2.9.0",
"@typescript-eslint/parser": "2.9.0",
"electron": "6.0.12",
"eslint": "6.7.1",
"eslint-config-prettier": "6.7.0",
Expand All @@ -64,7 +64,7 @@
"eslint-plugin-promise": "4.2.1",
"eslint-plugin-standard": "4.0.1",
"husky": "3.1.0",
"lint-staged": "9.4.3",
"lint-staged": "9.5.0",
"mocha": "6.2.2",
"prettier": "1.19.1",
"request-promise": "^4.2.5",
Expand Down
6 changes: 3 additions & 3 deletions plugins/plugin-apache-composer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@
],
"main": "dist/index.js",
"dependencies": {
"@kui-shell/core": "^5.4.4",
"@kui-shell/plugin-wskflow": "^5.4.4",
"@kui-shell/test": "^5.4.4",
"@kui-shell/core": "^5.5.3",
"@kui-shell/plugin-wskflow": "^5.5.3",
"@kui-shell/test": "^5.5.3",
"app-module-path": "2.2.0",
"debug": "4.1.1",
"openwhisk-composer": "github:starpit/incubator-openwhisk-composer#agent"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ export default {
order: -9,

content: (_, preview: Preview) => ({
content: preview.ast,
content: JSON.stringify(preview.ast, undefined, 2),
contentType: 'json'
})
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ export default {
})
}

return preview.container
return preview.container as HTMLElement
}
}
}
62 changes: 0 additions & 62 deletions plugins/plugin-grid/src/lib/modes.ts

This file was deleted.

2 changes: 1 addition & 1 deletion plugins/plugin-openwhisk-editor-extensions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
},
"gitHead": "89de9f78e8a1a2bdd29d2e17d7c608ab006c6d32",
"dependencies": {
"@kui-shell/plugin-editor": "^5.4.4",
"@kui-shell/plugin-editor": "^5.5.3",
"debug": "4.1.1"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,7 @@ export const newAction = ({
.then(() => Promise.all([makeAction(), openEditor(tab, name, options, execOptions)]))
.then(prepareEditorWithAction)
.then(addWskflow(tab))
.then(respondToRepl(undefined, ['is-modified']))
.then(respondToRepl(undefined /*, ['is-modified'] */))
}

export default async (commandTree: Commands.Registrar) => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ export const fetchAction = (check = checkForConformance, tryLocal = true) => asy
},
annotations: [],
persister: execOptions.parameters.persister,
gotoReadonlyView: ({ getEntity }) => lockIcon({ getEntity, direct: gotoReadonlyView({ getEntity }) })
gotoReadonlyView: ({ getEntity }) => lockIcon({ getEntity, command: gotoReadonlyView({ getEntity }) })
})
}
}
Expand All @@ -226,7 +226,7 @@ export const fetchAction = (check = checkForConformance, tryLocal = true) => asy
.then(entity =>
Object.assign({}, entity, {
persister: persisters.actions,
gotoReadonlyView: ({ getEntity }) => lockIcon({ getEntity, direct: gotoReadonlyView({ getEntity }) })
gotoReadonlyView: ({ getEntity }) => lockIcon({ getEntity, command: gotoReadonlyView({ getEntity }) })
})
)
.catch(err => {
Expand Down Expand Up @@ -317,7 +317,7 @@ export const newAction = ({
return betterNotExist(name, options)
.then(() => Promise.all([makeAction(), openEditor(tab, name, options, execOptions)]))
.then(prepareEditorWithAction)
.then(respondToRepl(undefined, ['is-modified']))
.then(respondToRepl(undefined /*, ['is-modified'] */))
}

export default async (commandTree: Commands.Registrar) => {
Expand Down
8 changes: 4 additions & 4 deletions plugins/plugin-openwhisk/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@
],
"main": "dist/index.js",
"dependencies": {
"@kui-shell/core": "^5.4.4",
"@kui-shell/plugin-core-support": "^5.4.4",
"@kui-shell/plugin-wskflow": "^5.4.4",
"@kui-shell/test": "^5.4.4",
"@kui-shell/core": "^5.5.3",
"@kui-shell/plugin-core-support": "^5.5.3",
"@kui-shell/plugin-wskflow": "^5.5.3",
"@kui-shell/test": "^5.5.3",
"adm-zip": "0.4.13",
"debug": "4.1.1",
"htmlparser2": "4.0.0",
Expand Down
49 changes: 20 additions & 29 deletions plugins/plugin-openwhisk/src/controller/generic/list-all.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2017-18 IBM Corporation
* Copyright 2017-19 IBM Corporation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand All @@ -19,48 +19,39 @@
*
*/

import Debug from 'debug'

import { Table } from '@kui-shell/core/api/table-models'
import { Arguments, Registrar } from '@kui-shell/core/api/commands'
import Tables from '@kui-shell/core/api/tables'

import { withStandardOptions } from '../usage'

const debug = Debug('plugins/openwhisk/cmds/list-all')

/** usage model */
/**
* Usage model
*
*/
const usage = withStandardOptions({
command: 'list',
strict: 'list', // enforce no positional or optional arguments
strict: 'list',
title: 'List all',
header: 'List all deployed entities',
example: `wsk list`
})

/** list all of these entity types: */
const types = ['actions', 'packages', 'triggers', 'rules']

/** list the entities of a given type */
/**
* List the entities of a given type
*
*/
const list = ({ REPL }: Arguments) => (type: string) =>
REPL.qexec<Tables.Table>(`wsk ${type} list`, undefined, undefined, { showHeader: true })

/** the command handler */
const doList = async (command: Arguments) => {
const response = await Promise.all(types.map(list(command))).then(result => {
return result.filter(
res =>
(Tables.isTable(res) && res.body.length > 0) ||
(Tables.isMultiTable(res) && res.tables.every(table => table.body.length > 0))
)
})

debug('list-all result', response)
REPL.qexec<Table>(`wsk ${type} list`, undefined, undefined, { showHeader: true })

if (Array.isArray(response) && response.length > 0) {
return response.length === 1 ? response[0] : { tables: response }
}
/**
* @return a list of lists, one for each OpenWhisk data type
*/
const doList = (command: Arguments): Promise<Table[]> => {
const types = ['actions', 'packages', 'triggers', 'rules']

return response
return Promise.all(types.map(list(command))).then(result => {
return result.filter(_ => _.body.length > 0)
})
}

/**
Expand Down
3 changes: 1 addition & 2 deletions plugins/plugin-openwhisk/src/test/openwhisk2/edit-new.ts
Original file line number Diff line number Diff line change
Expand Up @@ -121,11 +121,10 @@ describe('create new actions in editor', function(this: Common.ISuite) {
// expect the action content not to be changed
console.log('lock: Expected action content: "let main = x => x"')
const actionSrc = await Util.getValueFromMonaco(this.app)
console.error('!!!!2', actionSrc, actionSrc.trim() === 'let main = x => x')
return actionSrc.trim() === 'let main = x => x'
})
)
.catch(Common.oops(this)))
.catch(Common.oops(this, true)))

it('should get the new action, edit the action content and deployed', () =>
CLI.command('wsk action get foo2', this.app)
Expand Down