@listenai/lisa
Advanced tools
Comparing version 2.0.1 to 2.0.2
@@ -20,3 +20,2 @@ "use strict"; | ||
} | ||
this.debug(command.join(' ')); | ||
try { | ||
@@ -28,3 +27,5 @@ this.debug(globalInstall ? 'npm' : 'yarn', command.join(' ')); | ||
this.debug(code); | ||
await lisa_core_2.loadTaskDict(); | ||
if (code === 0) { | ||
await lisa_core_2.loadTaskDict(); | ||
} | ||
cli.action.stop(code === 0 ? '成功' : '失败'); | ||
@@ -31,0 +32,0 @@ } |
@@ -82,2 +82,3 @@ "use strict"; | ||
}); | ||
this.log(`或直接访问url进行登录:${url}`); | ||
cli.action.start('等待登录授权...'); | ||
@@ -84,0 +85,0 @@ let infoResult = null; |
@@ -5,2 +5,3 @@ "use strict"; | ||
const lisa_core_1 = require("@listenai/lisa_core"); | ||
const lisa_core_2 = require("@listenai/lisa_core"); | ||
class Uninstall extends command_1.Command { | ||
@@ -23,2 +24,5 @@ async run() { | ||
this.debug(code); | ||
if (code === 0) { | ||
await lisa_core_2.loadTaskDict(); | ||
} | ||
cli.action.stop(code === 0 ? '成功' : '失败'); | ||
@@ -25,0 +29,0 @@ } |
@@ -6,2 +6,3 @@ "use strict"; | ||
const lpminit_1 = require("../util/lpminit"); | ||
const lisa_core_2 = require("@listenai/lisa_core"); | ||
class Upgrade extends command_1.Command { | ||
@@ -25,2 +26,5 @@ async run() { | ||
this.debug(code); | ||
if (code === 0) { | ||
await lisa_core_2.loadTaskDict(); | ||
} | ||
cli.action.stop(code === 0 ? '成功' : '失败'); | ||
@@ -27,0 +31,0 @@ } |
@@ -11,13 +11,20 @@ "use strict"; | ||
const registry = application.registryUrl.replace('https:', ''); | ||
await cmd('npm', ['config', 'set', 'registry', process.env.LISA_NPM_REGISTRY || 'https://registry.npm.taobao.org']); | ||
application.debug('npm', ['set', `${registry}/:username=${lisaUserInfo.username}`].join(' ')); | ||
await cmd('npm', ['set', `${registry}/:username=${lisaUserInfo.username}`]); | ||
application.debug('npm', ['set', `${registry}/:_password=${lisaUserInfo.base64Token}`].join(' ')); | ||
await cmd('npm', ['set', `${registry}/:_password=${lisaUserInfo.base64Token}`]); | ||
application.debug('npm', ['set', `${registry}/:email=${lisaUserInfo.email}`].join(' ')); | ||
await cmd('npm', ['set', `${registry}/:email=${lisaUserInfo.email}`]); | ||
application.debug('npm', ['set', `${registry}/:always-auth=true`].join(' ')); | ||
await cmd('npm', ['set', `${registry}/:always-auth=true`]); | ||
try { | ||
await cmd('npm', ['config', 'set', 'registry', process.env.LISA_NPM_REGISTRY || 'https://registry.npm.taobao.org']); | ||
application.debug('npm', ['set', `${registry}/:username=${lisaUserInfo.username}`].join(' ')); | ||
await cmd('npm', ['set', `${registry}/:username=${lisaUserInfo.username}`]); | ||
application.debug('npm', ['set', `${registry}/:_password=${lisaUserInfo.base64Token}`].join(' ')); | ||
await cmd('npm', ['set', `${registry}/:_password=${lisaUserInfo.base64Token}`]); | ||
application.debug('npm', ['set', `${registry}/:email=${lisaUserInfo.email}`].join(' ')); | ||
await cmd('npm', ['set', `${registry}/:email=${lisaUserInfo.email}`]); | ||
application.debug('npm', ['set', `${registry}/:always-auth=true`].join(' ')); | ||
await cmd('npm', ['set', `${registry}/:always-auth=true`]); | ||
} | ||
catch (error) { | ||
if (error.message.indexOf('username')) { | ||
throw new Error('请先登录,执行`lisa login`'); | ||
} | ||
} | ||
} | ||
exports.default = lpminit; | ||
//# sourceMappingURL=lpminit.js.map |
@@ -1,1 +0,1 @@ | ||
{"version":"2.0.1","commands":{"build":{"id":"build","description":"固件开发项目编译打包","pluginName":"@listenai/lisa","pluginType":"core","aliases":[],"flags":{"release":{"name":"release","type":"boolean","char":"r","description":"打包release包","allowNo":false},"factory":{"name":"factory","type":"boolean","description":"打包factory包","allowNo":false}},"args":[]},"commands":{"id":"commands","description":"展示所有的命令","pluginName":"@listenai/lisa","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","char":"j","description":"display unfiltered api data in json format","allowNo":false}},"args":[]},"create":{"id":"create","description":"创建项目,例`lisa create newProject -t @generator/csk`","pluginName":"@listenai/lisa","pluginType":"core","aliases":[],"flags":{"template":{"name":"template","type":"option","char":"t","description":"生成器模板","required":false}},"args":[{"name":"name","description":"项目名称","required":false}]},"flash":{"id":"flash","description":"烧录程序","pluginName":"@listenai/lisa","pluginType":"core","aliases":[],"flags":{"part":{"name":"part","type":"option","char":"p","description":"选择烧录part文件,例:'-p master -p script',默认全部烧录"}},"args":[{"name":"filePath","description":"烧录的lpk包绝对路径,非必填,默认烧录csk开发项目package后的lpk包"}]},"install":{"id":"install","description":"安装依赖","pluginName":"@listenai/lisa","pluginType":"core","aliases":[],"flags":{},"args":[{"name":"pkg","description":"资源包名,例:'@source/csk4002',不填时默认安装lisa项目中的依赖","required":false}]},"login":{"id":"login","description":"登录","pluginName":"@listenai/lisa","pluginType":"core","aliases":[],"flags":{},"args":[]},"task":{"id":"task","description":"执行tasks,可执行的task输入`lisa task -T`命令查看","pluginName":"@listenai/lisa","pluginType":"core","aliases":[],"flags":{"table":{"name":"table","type":"boolean","char":"T","description":"表格展示所有可执行的task","allowNo":false},"json":{"name":"json","type":"boolean","description":"json展示所有可执行的task","allowNo":false},"verbose":{"name":"verbose","type":"boolean","description":"日志全量输出","allowNo":false}},"args":[{"name":"ID","description":"task id","required":false}]},"uninstall":{"id":"uninstall","description":"移除依赖","pluginName":"@listenai/lisa","pluginType":"core","aliases":[],"flags":{},"args":[{"name":"pkg","description":"资源包名,例:'@alge/general'","required":false}]},"update":{"id":"update","description":"更新lisa到最新版本","pluginName":"@listenai/lisa","pluginType":"core","aliases":[],"flags":{},"args":[]},"upgrade":{"id":"upgrade","description":"更新当前项目依赖","pluginName":"@listenai/lisa","pluginType":"core","aliases":[],"flags":{},"args":[]}}} | ||
{"version":"2.0.2","commands":{"build":{"id":"build","description":"固件开发项目编译打包","pluginName":"@listenai/lisa","pluginType":"core","aliases":[],"flags":{"release":{"name":"release","type":"boolean","char":"r","description":"打包release包","allowNo":false},"factory":{"name":"factory","type":"boolean","description":"打包factory包","allowNo":false}},"args":[]},"commands":{"id":"commands","description":"展示所有的命令","pluginName":"@listenai/lisa","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","char":"j","description":"display unfiltered api data in json format","allowNo":false}},"args":[]},"create":{"id":"create","description":"创建项目,例`lisa create newProject -t @generator/csk`","pluginName":"@listenai/lisa","pluginType":"core","aliases":[],"flags":{"template":{"name":"template","type":"option","char":"t","description":"生成器模板","required":false}},"args":[{"name":"name","description":"项目名称","required":false}]},"flash":{"id":"flash","description":"烧录程序","pluginName":"@listenai/lisa","pluginType":"core","aliases":[],"flags":{"part":{"name":"part","type":"option","char":"p","description":"选择烧录part文件,例:'-p master -p script',默认全部烧录"}},"args":[{"name":"filePath","description":"烧录的lpk包绝对路径,非必填,默认烧录csk开发项目package后的lpk包"}]},"install":{"id":"install","description":"安装依赖","pluginName":"@listenai/lisa","pluginType":"core","aliases":[],"flags":{},"args":[{"name":"pkg","description":"资源包名,例:'@source/csk4002',不填时默认安装lisa项目中的依赖","required":false}]},"login":{"id":"login","description":"登录","pluginName":"@listenai/lisa","pluginType":"core","aliases":[],"flags":{},"args":[]},"task":{"id":"task","description":"执行tasks,可执行的task输入`lisa task -T`命令查看","pluginName":"@listenai/lisa","pluginType":"core","aliases":[],"flags":{"table":{"name":"table","type":"boolean","char":"T","description":"表格展示所有可执行的task","allowNo":false},"json":{"name":"json","type":"boolean","description":"json展示所有可执行的task","allowNo":false},"verbose":{"name":"verbose","type":"boolean","description":"日志全量输出","allowNo":false}},"args":[{"name":"ID","description":"task id","required":false}]},"uninstall":{"id":"uninstall","description":"移除依赖","pluginName":"@listenai/lisa","pluginType":"core","aliases":[],"flags":{},"args":[{"name":"pkg","description":"资源包名,例:'@alge/general'","required":false}]},"update":{"id":"update","description":"更新lisa到最新版本","pluginName":"@listenai/lisa","pluginType":"core","aliases":[],"flags":{},"args":[]},"upgrade":{"id":"upgrade","description":"更新当前项目依赖","pluginName":"@listenai/lisa","pluginType":"core","aliases":[],"flags":{},"args":[]}}} |
{ | ||
"name": "@listenai/lisa", | ||
"description": "Lisa 是 Lisa Framework 核心命令行工具,提供模版生成能力以及任务执行命令", | ||
"version": "2.0.1", | ||
"version": "2.0.2", | ||
"author": "geekBoom.Zhao <zbzhao@listenai.com>", | ||
@@ -6,0 +6,0 @@ "bin": { |
@@ -21,3 +21,3 @@ @listenai/lisa | ||
$ lisa (-v|--version|version) | ||
@listenai/lisa/2.0.1 win32-x64 node-v12.22.0 | ||
@listenai/lisa/2.0.2 win32-x64 node-v12.22.0 | ||
$ lisa --help [COMMAND] | ||
@@ -60,3 +60,3 @@ USAGE | ||
_See code: [src/commands/build.ts](https://github.com/LISTENAI/lisa/blob/v2.0.1/src/commands/build.ts)_ | ||
_See code: [src/commands/build.ts](https://github.com/LISTENAI/lisa/blob/v2.0.2/src/commands/build.ts)_ | ||
@@ -78,3 +78,3 @@ ## `lisa create [NAME]` | ||
_See code: [src/commands/create.ts](https://github.com/LISTENAI/lisa/blob/v2.0.1/src/commands/create.ts)_ | ||
_See code: [src/commands/create.ts](https://github.com/LISTENAI/lisa/blob/v2.0.2/src/commands/create.ts)_ | ||
@@ -96,3 +96,3 @@ ## `lisa flash [FILEPATH]` | ||
_See code: [src/commands/flash.ts](https://github.com/LISTENAI/lisa/blob/v2.0.1/src/commands/flash.ts)_ | ||
_See code: [src/commands/flash.ts](https://github.com/LISTENAI/lisa/blob/v2.0.2/src/commands/flash.ts)_ | ||
@@ -111,3 +111,3 @@ ## `lisa install [PKG]` | ||
_See code: [src/commands/install.ts](https://github.com/LISTENAI/lisa/blob/v2.0.1/src/commands/install.ts)_ | ||
_See code: [src/commands/install.ts](https://github.com/LISTENAI/lisa/blob/v2.0.2/src/commands/install.ts)_ | ||
@@ -123,3 +123,3 @@ ## `lisa login` | ||
_See code: [src/commands/login.ts](https://github.com/LISTENAI/lisa/blob/v2.0.1/src/commands/login.ts)_ | ||
_See code: [src/commands/login.ts](https://github.com/LISTENAI/lisa/blob/v2.0.2/src/commands/login.ts)_ | ||
@@ -281,3 +281,3 @@ ## `lisa plugins` | ||
_See code: [src/commands/task.ts](https://github.com/LISTENAI/lisa/blob/v2.0.1/src/commands/task.ts)_ | ||
_See code: [src/commands/task.ts](https://github.com/LISTENAI/lisa/blob/v2.0.2/src/commands/task.ts)_ | ||
@@ -296,3 +296,3 @@ ## `lisa uninstall [PKG]` | ||
_See code: [src/commands/uninstall.ts](https://github.com/LISTENAI/lisa/blob/v2.0.1/src/commands/uninstall.ts)_ | ||
_See code: [src/commands/uninstall.ts](https://github.com/LISTENAI/lisa/blob/v2.0.2/src/commands/uninstall.ts)_ | ||
@@ -308,3 +308,3 @@ ## `lisa update` | ||
_See code: [src/commands/update.ts](https://github.com/LISTENAI/lisa/blob/v2.0.1/src/commands/update.ts)_ | ||
_See code: [src/commands/update.ts](https://github.com/LISTENAI/lisa/blob/v2.0.2/src/commands/update.ts)_ | ||
@@ -320,3 +320,3 @@ ## `lisa upgrade` | ||
_See code: [src/commands/upgrade.ts](https://github.com/LISTENAI/lisa/blob/v2.0.1/src/commands/upgrade.ts)_ | ||
_See code: [src/commands/upgrade.ts](https://github.com/LISTENAI/lisa/blob/v2.0.2/src/commands/upgrade.ts)_ | ||
<!-- commandsstop --> |
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 not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
956956
1344