How to show what will be updated next pull?

Posted by ??? on Super User See other posts from Super User or by ???
Published on 2011-01-05T23:36:10Z Indexed on 2011/01/05 23:56 UTC
Read the original article Hit count: 219

Filed under:

In SVN, doing svn update will show a list of full paths with a status prefix:

$ svn update
M foo/bar
U another/bar
Revision 123

I need to get this update list to do some post-process work. After I have transferred the SVN repository to Git, I can't find a way to get the update list:

$ git pull
Updating 9607ca4..61584c3
Fast-forward
 .gitignore                                         |    1 +
 uni/.gitignore                                     |    1 +
 uni/package/cooldeb/.gitignore                     |    1 +
 uni/package/cooldeb/Makefile.am                    |    2 +-
 uni/package/cooldeb/VERSION.av                     |   10 +-
 uni/package/cooldeb/cideb                          |   10 +-
 uni/package/cooldeb/cooldeb.sh                     |    2 +-
 uni/package/cooldeb/newdeb                         |   53 +++-
 ...update-and-deb-redist => update-and-deb-redist} |    5 +-
 uni/utils/2tree/{list2tree => 2tree}               |   12 +-
 uni/utils/2tree/ChangeLog                          |    4 +-
 uni/utils/2tree/Makefile.am                        |    2 +-

I can translate the Git pull status list to SVN's format:

M .gitignore
M uni/.gitignore
M uni/package/cooldeb/.gitignore
M uni/package/cooldeb/Makefile.am
M uni/package/cooldeb/VERSION.av
M uni/package/cooldeb/cideb
M uni/package/cooldeb/cooldeb.sh
M uni/package/cooldeb/newdeb
M ...update-and-deb-redist => update-and-deb-redist}
M uni/utils/2tree/{list2tree => 2tree}
M uni/utils/2tree/ChangeLog
M uni/utils/2tree/Makefile.am

However, some entries having long path names are abbreviated, such as uni/package/cooldeb/update-and-deb-redist is abbreviated to ...update-and-deb-redist.

I deem I can do with Git directly, maybe I can configure git pull's output in special format.

Any idea?

© Super User or respective owner

Related posts about git