Linux
  • Linux
  • Bash
  • Debian
  • Ubuntu
  • Shell
  • CentOS
  • SSH
☰

是否可以在bash中運行nodejs程式?

tag-icon 2024-5-13 • tag-icon bash node.js javascript
是否可以在bash中運行nodejs程式?

我的問題很簡單:我有一個用nodejs寫的程序,想用該語言無限循環運行它bash,這可能嗎?

答案1

沒問題

#!/bin/sh
while true
do
    node <myapp>
done

您也可以將其用作單襯裡 while true; do; node <myapp>; done;

THE END
更改寫入 crontab 的 bash 腳本中的事件順序 更改寫入 crontab 的 bash 腳本中的事件順序
刪除 sqlplus 中的所有選項卡 刪除 sqlplus 中的所有選項卡

相關內容

熱門問答

熱門問答

  • bash
  • node.js
  • javascript
  • shell-script
  • cron
  • ksh
  • sql
  • tabulation

© 2024 rvso.com 版權所有. 網站地圖