如何在 bash 脚本中使用 git 当前分支
how-to-use-git-current-branch-in-bash-scripts.sh
# 分支是,例如,"main"
export branch=$(git branch --show-current)Check out similar posts by category:
Git, Linux, Version Management
If this post helped you, please consider buying me a coffee or donating via PayPal to support research & publishing of new posts on TechOverflow