You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2021/03/17 06:48:55 UTC

[GitHub] [incubator-nuttx] microhobby opened a new pull request #3082: WIP: libs/libc/misc/lib_utsname.c: Add CONFIG_VERSION_EXTRA

microhobby opened a new pull request #3082:
URL: https://github.com/apache/incubator-nuttx/pull/3082


   ## Summary
   
   The idea is to have something like EXTRAVERSION from Linux. This is useful for getting RC tags, development tags and for customizing the version.
   
   ## Impact
   
   I really have no idea, I am still assimilating NuttX. So I am leaving this PR as WIP.
   This is a suggestion (also to help me understand everything and do something hands-on), so I will wait for feedback from the maintainers.
   
   ## Testing
   
   Tested on Linux user-mode:
   
   ![image](https://user-images.githubusercontent.com/2633321/111426167-fd8c0c00-86d2-11eb-8f4f-ca8abb5f12f3.png)


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-nuttx] microhobby commented on a change in pull request #3082: WIP: libs/libc/misc/lib_utsname.c: Add CONFIG_VERSION_EXTRA

Posted by GitBox <gi...@apache.org>.
microhobby commented on a change in pull request #3082:
URL: https://github.com/apache/incubator-nuttx/pull/3082#discussion_r596201016



##########
File path: tools/version.sh
##########
@@ -81,6 +82,14 @@ if [ -z ${VERSION} ] ; then
 
 fi
 
+if [ -z ${EXTRA} ] ; then
+  EXTRA=`git -C ${WD} tag --sort=v:refname | grep -E "nuttx-[0-9]+\.[0-9]+\.[0-9]+" | tail -1 | cut -d'-' -f3`

Review comment:
       @xiaoxiang781216 @Ouss4 thanks for the review.
   Yeah I agree, and use the remaining of the cut directly in VERSION looks good to me.
   I updated the commit




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-nuttx] Ouss4 commented on a change in pull request #3082: WIP: libs/libc/misc/lib_utsname.c: Add CONFIG_VERSION_EXTRA

Posted by GitBox <gi...@apache.org>.
Ouss4 commented on a change in pull request #3082:
URL: https://github.com/apache/incubator-nuttx/pull/3082#discussion_r596107568



##########
File path: tools/version.sh
##########
@@ -81,6 +82,14 @@ if [ -z ${VERSION} ] ; then
 
 fi
 
+if [ -z ${EXTRA} ] ; then
+  EXTRA=`git -C ${WD} tag --sort=v:refname | grep -E "nuttx-[0-9]+\.[0-9]+\.[0-9]+" | tail -1 | cut -d'-' -f3`

Review comment:
       Yes, this is better than duplicating the same `git` command.




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-nuttx] acassis merged pull request #3082: tools/version.sh: Add the remaining cut to VERSION

Posted by GitBox <gi...@apache.org>.
acassis merged pull request #3082:
URL: https://github.com/apache/incubator-nuttx/pull/3082


   


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-nuttx] xiaoxiang781216 commented on a change in pull request #3082: WIP: libs/libc/misc/lib_utsname.c: Add CONFIG_VERSION_EXTRA

Posted by GitBox <gi...@apache.org>.
xiaoxiang781216 commented on a change in pull request #3082:
URL: https://github.com/apache/incubator-nuttx/pull/3082#discussion_r595768107



##########
File path: tools/version.sh
##########
@@ -25,6 +25,7 @@ USAGE="USAGE: $0 [-d|-h] [-b <build>] [-v <major.minor.patch>] <outfile-path>"
 ADVICE="Try '$0 -h' for more information"
 
 unset VERSION
+unset EXTRA

Review comment:
       another way is to utilize -b(BUILD): you can add any custom string as you want.




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-nuttx] acassis commented on pull request #3082: tools/version.sh: Add the remaining cut to VERSION

Posted by GitBox <gi...@apache.org>.
acassis commented on pull request #3082:
URL: https://github.com/apache/incubator-nuttx/pull/3082#issuecomment-801479398


   Thank you @microhobby  for implementing the suggested approach!


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-nuttx] xiaoxiang781216 commented on a change in pull request #3082: WIP: libs/libc/misc/lib_utsname.c: Add CONFIG_VERSION_EXTRA

Posted by GitBox <gi...@apache.org>.
xiaoxiang781216 commented on a change in pull request #3082:
URL: https://github.com/apache/incubator-nuttx/pull/3082#discussion_r595767479



##########
File path: tools/version.sh
##########
@@ -81,6 +82,14 @@ if [ -z ${VERSION} ] ; then
 
 fi
 
+if [ -z ${EXTRA} ] ; then
+  EXTRA=`git -C ${WD} tag --sort=v:refname | grep -E "nuttx-[0-9]+\.[0-9]+\.[0-9]+" | tail -1 | cut -d'-' -f3`

Review comment:
       maybe, we can extend VERSION to carry the tail part directly.




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org