Linux常用别名设置

Linux常用别名设置

1、maven打包:mi

echo "alias mi='mvn clean install -U -DskipTests'" >>~/.bash_profile

source ~/.bash_profile

使用:

mi

2、nohup后台运行jar包:runjar

cat >> ~/.bash_profile <<-'EOF'
alias runjar='func(){ nohup java -jar $1 >>./catalina.out 2>&1 & };func'
EOF

使配置生效:

source ~/.bash_profile

使用:

runjar xx.jar
posted @ 2020-08-15 11:12  直角漫步  阅读(324)  评论(0编辑  收藏  举报