简体   繁体   English

检查git repo的任何分支中是否有未提交的更改

[英]Check to see if there are uncommited changes in any branch of git repo

As I am in the process of moving from Bitbucket to Github, I am going through a long list of repositories on my computer that I should have been better about maintaining, but haven't been looked at or thought of in awhile. 在我从Bitbucket迁移到Github的过程中,我要遍历计算机上的一长串存储库,这些存储库本来可以更好地进行维护,但是一段时间内没有被关注或想到。 I'm manually going from repo to repo checking to see if there are any uncommitted changes on any existing branch. 我正在手动从仓库进行仓库检查,以查看现有分支上是否存在未提交的更改。

I'd like to do this with one command, rather than doing 'git status' on each branch, but I'm unsure of how exactly to do this as I'm not very proficient writing bash scripts. 我想用一个命令来执行此操作,而不是在每个分支上执行“ git status”,但是我不确定如何精确地执行此操作,因为我不太熟练地编写bash脚本。

I am currently running Linux. 我当前正在运行Linux。

This command may help 该命令可能会有所帮助

git log --graph --all --decorate --oneline

Any lines which don't flow back in to the main branch indicate branches with un-merged changes. 任何不流回主分支的行都表示未合并更改的分支。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM