我想運行此:{這裏值與/結束}猛砸sed的-i更新斜槓
sed -i -e "s/\($user hard nproc \).*/\1{value here ending with /}/" /etc/something.conf
這裏,就像是100/或ABC/
但是,如果我只是把/ like:
sed -i -e "s/\($user hard nproc \).*/\1abc//" /etc/something.conf
我得到這個錯誤: 未知的選項'S'
我一直特林解決這個問題,但不能認爲任何解決方案...
基本上我所要做的就是更新我的老值從 「用戶名硬nproc 10」 到「用戶名硬nproc 10 **」 與「 **」。
歡迎來到堆棧溢出,你的問題不清楚。請在代碼標籤中發佈帶有預期輸出文件的示例Input_file,然後讓我知道。相應地更新了 – RavinderSingh13
。 – GodFather