alias 默認是無法添加參數的,要想添加參數,只能定義一個函數來調用,示例如下:
alias tcstart='new() { /root/bin/tc-single-start "$1"; /root/bin/tclog "$1"; }; new'
其中注意:
{ /root/bin/tc-single-start 之間要有空格
"$1"; } 之間 要有分號。
alias 默認是無法添加參數的,要想添加參數,只能定義一個函數來調用,示例如下:
alias tcstart='new() { /root/bin/tc-single-start "$1"; /root/bin/tclog "$1"; }; new'
其中注意:
{ /root/bin/tc-single-start 之間要有空格
"$1"; } 之間 要有分號。