[libvirt] [Libvirt]How to get libvirt version after git clone?

Matthias Bolte matthias.bolte at googlemail.com
Sat Feb 2 13:49:35 UTC 2013


2013/2/2 harryxiyou <harryxiyou at gmail.com>:
> Hi all,
>
> After i clone libvirt git repo, how i could get this libvirt version exactly?
>
> $ git clone git://libvirt.org/libvirt.git
> $ git branch -a
> * master
>   remotes/origin/HEAD -> origin/master
>   remotes/origin/master
>   remotes/origin/v0.10.2-maint
>   remotes/origin/v0.9.11-maint
>   remotes/origin/v0.9.6-maint
>
> I can just see up stuffs but exact current version. Could anyone give me
> some suggestions? Thanks in advance.

You can look at the AC_INIT line in configure.ac

AC_INIT([libvirt], [1.0.2], [libvir-list at redhat.com], [], [http://libvirt.org])

the second argument is the latest released version.

You can also use

git describe --abbrev=0

to get the latest tag, as released versions and release candidates are tagged.

-- 
Matthias Bolte
http://photron.blogspot.com




More information about the libvir-list mailing list