xgqfrms™, xgqfrms® : xgqfrms's offical website of cnblogs! xgqfrms™, xgqfrms® : xgqfrms's offical website of GitHub!

IoT & Raspberry Pi

IoT & Raspberry Pi

https://www.raspberrypi.org/

https://www.raspberrypi.org/training

https://projects.raspberrypi.org/en/projects/raspberry-pi-getting-started


chmod

linux & chmod 777 & chmod +x

https://www.cnblogs.com/xgqfrms/p/9546961.html

https://www.cnblogs.com/xgqfrms/p/9551553.html

https://www.cnblogs.com/xgqfrms/p/9626636.html

https://github.com/xgqfrms-GitHub/Node-CLI-Tools/blob/master/bash-shell-chmod.md



#!/bin/sh

# echo "^-v-^ JSON DB is running in development env!" && npm run db

# echo "^-v-^ JSON DB is running in development env!" && nodemon -w ./server.js localhost 8888

JSONDB="nodemon -w ./server.js localhost 8888"

${JSONDB} &
# chmod +x db.sh
# OR
# chmod 777 db.sh

# sudo ./db.sh
# nodemon -w ./server.js localhost 8888

# /bin/sh db.sh

# ps -ef | grep node
# sudo kill -9 <PID>


Linux Shell

编写首个Shell脚本
打开你使用的文本编辑器,粘贴如下内容:

#!/bin/bash
echo "Hello World!"

将其保存成 1st.sh 再执行看看效果:

chmod 755 1st.sh

./1st.sh

执行成功了,是不是非常简单。

下面我们再建立一个 2nd.sh 并粘入如下内容:


#!/bin/bash
echo "What is your name?"
read a;
echo "Hey $a! what is your Favorite Website?"
read b;
echo -e "That's Nice to know @$a that $b is your favorite Website"



©xgqfrms 2012-2020

www.cnblogs.com 发布文章使用:只允许注册用户才可以访问!


posted @   xgqfrms  阅读(115)  评论(3编辑  收藏  举报
编辑推荐:
· AI与.NET技术实操系列(二):开始使用ML.NET
· 记一次.NET内存居高不下排查解决与启示
· 探究高空视频全景AR技术的实现原理
· 理解Rust引用及其生命周期标识(上)
· 浏览器原生「磁吸」效果!Anchor Positioning 锚点定位神器解析
阅读排行:
· DeepSeek 开源周回顾「GitHub 热点速览」
· 记一次.NET内存居高不下排查解决与启示
· 物流快递公司核心技术能力-地址解析分单基础技术分享
· .NET 10首个预览版发布:重大改进与新特性概览!
· .NET10 - 预览版1新功能体验(一)
历史上的今天:
2018-05-17 How to run multiple Python versions on Windows?
2018-05-17 MySQL & Python
2016-05-17 各种流行的icon-font 库 图标字体 iconfont fontawesome
2016-05-17 论文 公式 排版 编辑 工具 NoteExpress & MathType
点击右上角即可分享
微信分享提示