baggio63446333 commented on a change in pull request #4144:
URL: https://github.com/apache/incubator-nuttx/pull/4144#discussion_r668918404
##########
File path: tools/version.sh
##########
@@ -71,12 +71,12 @@ done
OUTFILE=$1
if [ -z ${VERSION} ] ; then
- VERSION=`git -C ${WD} describe 2>/dev/null | tail -1 | cut -d'-' -f2`
+ VERSION=`git -C ${WD} describe --match "nuttx-*" 2>/dev/null | tail -1 | cut
-d'-' -f2`
Review comment:
Adding `--match` option of `git describe` is nice-to-have to prevent the
wrong version from being retrieved depending on the environment. If it's better
without it or is side-effect, I'll delete it.
> @masayuki2009 changed the regex to accommodate something similar, but
maybe this doesn't cover your use case.
This is about `git tag ... | grep -E "nuttx-` and this regex is helpful for
me to manage tags on fork repository.
Thanks.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]