forums.PPSSPP.org
[Solved] how to find ppsspp git revision number on git server? - Printable Version

+- forums.PPSSPP.org (https://forums.ppsspp.org)
+-- Forum: PPSSPP - Playstation Portable Simulator Suitable for Playing Portably (/forumdisplay.php?fid=1)
+--- Forum: Development (/forumdisplay.php?fid=3)
+--- Thread: [Solved] how to find ppsspp git revision number on git server? (/showthread.php?tid=7455)



[Solved] how to find ppsspp git revision number on git server? - fastrizwaan - 11-21-2013 07:39 AM

I'm building RPM for fedora, I want to get the git version like v.0.9.5-XXXXXXX , when a commit happens and we do git fetch

When we compile ppsspp, we can see git-version.cpp, but how do I know the latest full revision number?

thanks.


RE: how to find ppsspp git revision number on git server? - Henrik - 11-21-2013 07:52 AM

This annoys me too. I generally just go to buildbot, find the version and click the link.

Alternatively if you have the hash (the part after 'g'), you can go here:

https://github.com/hrydgard/ppsspp/commits/*hash*

where you replace *hash* with the XXXXXXX (excluding the g)


RE: how to find ppsspp git revision number on git server? - fastrizwaan - 11-21-2013 08:25 AM

I think we need to successfully compile then get the GIT VERSION from

ppsspp/git-version.cpp
Code:
cat ../ppsspp/git-version.cpp|grep \"|cut -f2 -d \"
will get us
v0.9.5-556-gcd6de79


RE: how to find ppsspp git revision number on git server? - Bigpet - 11-22-2013 01:06 AM

it's just "git describe --always" at least that's what's used to generate the git-version.cpp


RE: how to find ppsspp git revision number on git server? - [Unknown] - 11-22-2013 03:44 AM

Henrik: open your .gitconfig file or etc. and add this under [alias]:

find-commit = "!START_POINT="`echo "$1" | sed -e 's/-.*$//'`"; git describe --always `git rev-list "$START_POINT"..master` | grep "$1-" && true"

Use e.g. "git find-commit v0.9.5-3". But it's still a pain and can be slow or ambiguous.

Another useful one:
get-merge = "!git log --ancestry-path $1..master --oneline --merges | tail -n1 && true"

Use e.g. "git get-merge c2b2b36" which will tell you it's pull #4417.

As for packaging, yes, just use git describe --always. I believe it has to be done from within the git directory.

-[Unknown]


RE: [Solved] how to find ppsspp git revision number on git server? - fastrizwaan - 11-22-2013 01:26 PM

Thanks unknown and Bigpet! that helped a lot for making rpm.