当前位置:网站首页>Write a simple nodejs script
Write a simple nodejs script
2022-07-03 12:27:00 【Chengfeng XS】
1. Create a script folder
2. initialization
npm init -y
3. stay package.json Add script command to file
"bin": {
"recat": "./index.js"
},
4. The same as creating in the directory index.js file , Content
#!/usr/bin/env node
const argvArr = process.argv;
console.log(argvArr);
5. Run the command
npm link
6. You can run the script on the command line
recat
边栏推荐
- Wechat applet - basic content
- Eureka自我保护
- Self made pop-up input box, input text, and click to complete the event.
- 剑指Offer10- I. 斐波那契数列
- 网络通讯之Socket-Tcp(一)
- Shutter widget: centerslice attribute
- Atomic atomic operation
- 1-2 project technology selection and structure
- (構造筆記)從類、API、框架三個層面學習如何設計可複用軟件實體的具體技術
- (construction notes) grasp learning experience
猜你喜欢
Why can't my MySQL container start
If you can't learn, you have to learn. Jetpack compose writes an im app (II)
Basic knowledge of OpenGL (sort it out according to your own understanding)
Prompt unread messages and quantity before opening chat group
Eureka自我保护
4000字超详解指针
TOGAF认证自学宝典V2.0
1-2 project technology selection and structure
Fluent: Engine Architecture
Wechat applet - basic content
随机推荐
DEJA_VU3D - Cesium功能集 之 053-地下模式效果
SystemVerilog -- OOP -- copy of object
Jsup crawls Baidu Encyclopedia
OpenGL draws colored triangles
Pki/ca and digital certificate
Sword finger offer03 Repeated numbers in the array [simple]
145. Post order traversal of binary tree
Unicode查询的官方网站
(构造笔记)MIT reading部分学习心得
QT OpenGL rotate, pan, zoom
Flutter 退出登录二次确认怎么做才更优雅?
239. Sliding window maximum
Official website of Unicode query
Use of atomicinteger
JVM内存模型
Shutter widget: centerslice attribute
Why can't my MySQL container start
Apprendre à concevoir des entités logicielles réutilisables à partir de la classe, de l'API et du cadre
If you can't learn, you have to learn. Jetpack compose writes an im app (I)
How to convert a numeric string to an integer