原文:https://twitter.com/aboutjgeo/status/1623284762441043968
因為太好笑了,保留圖片




軟體開發和生活瑣事
看了「Backblaze Drive Stats for 2022」的硬碟列表:
希萌創意與 Storia 辛苦了,劇本、角色、遊戲設計都很棒,且很有臺灣在地特色。
任意入門:食用系少女14項成就攻略
載點:https://a.blog.zeroplex.tw/wp-content/uploads/2023/01/Storia.7z
透過 bash 中的 $? 來讀取前一個指令的狀態 (exit code)。一般來說,正常執行的 exit code 會是 0,若有發生錯誤或其他狀況,exit code 則會是 1 – 255 之間。
正常結束的 exit code:
ls /var echo $? 0
若發生錯誤,則有其他 exit code:
ls /not-exsit echo $? 2
在 shell script 中用 if 判斷程式是否要繼續執行:
curl -s https://test.com/install.sh -o install.sh
if [ @? -ne 0 ]; then
echo "download failed"
exit
fi
# run install