I'm new to phing and building a script to automate some build tasks.
Is there a way to retrieve just the most recently added tag to a git repo? I can pull up a list of all my tags but cannot seem to filter it down to the latest one.
Here's the relevant code that fetches my git tags:
<gittag
repository="${repo.dir.resolved}"
list="true"
outputProperty="versionTag"
pattern="v*" />
The output of the above results in a list of tags (prefixed by "v"):
[gittag] git-tag output: v1.0.0
v1.0.1
v1.0.2
Any ideas on how I can get this down to just the v1.0.2?