当前位置:网站首页>Nodejs: detect and install the NPM module. If it is already installed, skip
Nodejs: detect and install the NPM module. If it is already installed, skip
2022-07-28 10:55:00 【shunzi2016】
CURTIME=$(date "+%Y-%m-%d %H:%M:%S")
checkAndInstall(){
# Determine whether it exists
# ps -ef|grep node |wc -l
# echo [email protected]
echo 'check and install npm modular:'$1
COUNT=$(ps -ef|grep $1 |wc -l)
if [ $COUNT -eq 1 ]; then
echo "$CURTIME $1 exist"
echo "$CURTIME $1 exist" >> /tmp/update_npm_log.txt
else
npm install $1
echo "$CURTIME $1 installing"
echo "$CURTIME $1 installed" >> /tmp/update_npm_log.txt
fi
}
n v14.16.0
npm config set registry https://registry.npm.taobao.org
cd /home/opc/web-core
# npm install nodemailer
# ----------------------------------
checkAndInstall generic-pool
echo $?边栏推荐
猜你喜欢

Ten questions about low code: tell everything about low code!

GKBillowNoiseSource

Attention attention mechanism flow chart

分体式测斜探头安装要点及注意事项

float浮动初步理解

剑指 Offer 35. 复杂链表的复制

ctf技能树----文件上传

GKVoronoiNoiseSource

GKCheckerboardNoiseSource

Pyqt5 rapid development and practice 4.13 menu bar, toolbar and status bar and 4.14 qprinter
随机推荐
11_ UE4 advanced_ Change male characters to female characters and modify the animation
Attention 注意力机制流程框图
Arduino基础知识
clo*******e:项目管理随记
适合中小企业的进销存软件,搞定5大难题
蓝桥杯嵌入式-HAL库-LCD
3. MapReduce explanation and source code analysis
Samba server configuration
Product side data analysis thinking
Crm+ zero code: easily realize enterprise informatization
Samba learning
nodejs:mongodb 插入成功之后的返回值
GKBillowNoiseSource
GKRidgedNoiseSource
Two years of crud, two graduates, two months of preparation for the interview with ALI, and fortunately won the offer grading p6
蓝桥杯嵌入式-HAL库-SYSTICK
这里有一份超实用Excel快捷键合集(常用+八大类汇总)
哈希表的相关知识点
GKCheckerboardNoiseSource
The 10th Landbridge cup embedded electronic provincial competition