{"thread":{"id":"13049","subject":"[PATCH] git-submodule: Avoid 'fatal: cannot describe' message","startedAt":"2008-04-10T14:45:29Z","lastAt":"2008-04-10T14:45:29Z","messageCount":1,"participants":["Ping Yin"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"74063","messageId":"1207838729-5567-1-git-send-email-pkufranky@gmail.com","threadId":"13049","inReplyTo":null,"subject":"[PATCH] git-submodule: Avoid 'fatal: cannot describe' message","fromName":"Ping Yin","fromEmail":"pkufranky@gmail.com","sentAt":"2008-04-10T14:45:29Z","receivedAt":"2008-04-10T14:45:29Z","isPatch":true,"sender":{"key":"pkufranky@gmail.com","avatar":"https://avatars.githubusercontent.com/u/5346?v=4"},"body":"When \"git submodule status\" command tries to show the name of the\nsubmodule HEAD revision more descriptively, but the submodule\nrepository lacked a suitable tag to do so, it leaked \"fatal: cannot\ndescribe\" message to the UI.  Squelch it by using '--always'.\n\nSigned-off-by: Ping Yin <pkufranky@gmail.com>\n---\n git-submodule.sh |    2 +-\n 1 files changed, 1 insertions(+), 1 deletions(-)\n\ndiff --git a/git-submodule.sh b/git-submodule.sh\nindex 56ec353..7674346 100755\n--- a/git-submodule.sh\n+++ b/git-submodule.sh\n@@ -327,7 +327,7 @@ set_name_rev () {\n \t\tcd \"$1\" && {\n \t\t\tgit describe \"$2\" 2>/dev/null ||\n \t\t\tgit describe --tags \"$2\" 2>/dev/null ||\n-\t\t\tgit describe --contains --tags \"$2\"\n+\t\t\tgit describe --contains --tags --always \"$2\"\n \t\t}\n \t) )\n \ttest -z \"$revname\" || revname=\" ($revname)\"\n-- \n1.5.5.23.g2a5f\n"}]}