Skip to content

Commit

Permalink
Feat: cmd console log
Browse files Browse the repository at this point in the history
  • Loading branch information
pandaoh committed Apr 12, 2024
1 parent c81375a commit b798e62
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion bin/xcmd.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* @Author: HxB
* @Date: 2022-04-25 16:27:06
* @LastEditors: DoubleAm
* @LastEditTime: 2024-04-12 21:51:36
* @LastEditTime: 2024-04-12 22:18:51
* @Description: 命令处理文件
* @FilePath: \js-xcmd\bin\xcmd.js
*/
Expand Down Expand Up @@ -394,6 +394,7 @@ program
let cmdStr = 'npm i nrm pnpm cnpm js-xcmd nodemon pm2 yarn rimraf protobufjs protobufjs-cli -g';
console.log({ cmdStr });
nodeCmd.run(cmdStr, (err, data, stderr) => {
console.log(stderr);
if (err) return console.log(`%c出错啦!${data}`, 'color:red;');
console.log(data);
console.log('----------Successful----------');
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "js-xcmd",
"version": "1.4.9",
"version": "1.4.10",
"description": "XCmd library for node.js.",
"main": "main.js",
"bin": {
Expand Down

0 comments on commit b798e62

Please sign in to comment.