#!/bin/bash
# 一次性处理git提交
#branch_name=`git symbolic-ref --short -q HEAD`
branch_name=$(git symbolic-ref --short -q HEAD)
if [ ! -n "$1" ] ;then
commit="提交"
else
commit=$1
fi
password="123456"
echo $password|sudo -S git add .
echo $password|sudo -S git commit -m "$commit"
echo $password|sudo -S git push origin "$branch_name"

相关文章:

  • 2022-02-07
  • 2022-01-03
  • 2022-12-23
  • 2021-08-01
  • 2022-12-23
  • 2022-12-23
  • 2022-02-07
猜你喜欢
  • 2022-02-07
  • 2022-01-01
  • 2022-12-23
  • 2022-02-09
  • 2021-09-05
  • 2021-09-27
相关资源
相似解决方案