Git Mailing List Archive mirror
 help / color / mirror / Atom feed
From: Felipe Contreras <felipe.contreras@gmail.com>
To: git@vger.kernel.org
Cc: Jeff King <peff@peff.net>, Junio C Hamano <gitster@pobox.com>,
	Todd Zullinger <tmz@pobox.com>,
	Felipe Contreras <felipe.contreras@gmail.com>
Subject: [PATCH v2 15/15] version-gen: get rid of GVF variable
Date: Mon, 24 Apr 2023 10:50:41 -0600	[thread overview]
Message-ID: <20230424165041.25180-16-felipe.contreras@gmail.com> (raw)
In-Reply-To: <20230424165041.25180-1-felipe.contreras@gmail.com>

There's not much point in a variable which is never going to change and
doesn't really add any readability.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
---
 GIT-VERSION-GEN | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/GIT-VERSION-GEN b/GIT-VERSION-GEN
index a1c50cb06b..3d30ce74af 100755
--- a/GIT-VERSION-GEN
+++ b/GIT-VERSION-GEN
@@ -1,6 +1,5 @@
 #!/bin/sh
 
-GVF=GIT-VERSION-FILE
 DEF_VER=2.40.GIT
 
 get_version () {
@@ -15,5 +14,5 @@ VN=$(get_version)
 
 NEW="GIT_VERSION = $VN"
 
-test -r $GVF && test "$NEW" = "$(cat $GVF)" && exit
-echo "$NEW" | tee $GVF >&2
+test -r GIT-VERSION-FILE && test "$NEW" = "$(cat GIT-VERSION-FILE)" && exit
+echo "$NEW" | tee GIT-VERSION-FILE >&2
-- 
2.40.0+fc1


      parent reply	other threads:[~2023-04-24 16:52 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-24 16:50 [PATCH v2 00/15] version-gen: complete revamp/rewrite Felipe Contreras
2023-04-24 16:50 ` [PATCH v2 01/15] version-gen: reorganize Felipe Contreras
2023-04-24 16:50 ` [PATCH v2 02/15] version-gen: trivial cleanup Felipe Contreras
2023-04-24 16:50 ` [PATCH v2 03/15] version-gen: refactor default version Felipe Contreras
2023-04-24 16:50 ` [PATCH v2 04/15] version-gen: simplify v prefix removal Felipe Contreras
2023-04-24 16:50 ` [PATCH v2 05/15] version-gen: simplify update check Felipe Contreras
2023-04-24 16:50 ` [PATCH v2 06/15] version-gen: simplify `git describe` checks Felipe Contreras
2023-04-24 16:50 ` [PATCH v2 07/15] version-gen: simplify dirty check Felipe Contreras
2023-04-24 16:50 ` [PATCH v2 08/15] version-gen: move describe fix into function Felipe Contreras
2023-04-24 16:50 ` [PATCH v2 09/15] version-gen: describe and sed in one go Felipe Contreras
2023-04-24 16:50 ` [PATCH v2 10/15] version-gen: refactor describe function Felipe Contreras
2023-04-24 16:50 ` [PATCH v2 11/15] version-gen: do v fix only when necessary Felipe Contreras
2023-04-24 16:50 ` [PATCH v2 12/15] version-gen: move v fix into sed Felipe Contreras
2023-04-24 16:50 ` [PATCH v2 13/15] version-gen: refactor main functionality Felipe Contreras
2023-04-24 16:50 ` [PATCH v2 14/15] version-gen: refactor GIT_VERSION string Felipe Contreras
2023-04-24 16:50 ` Felipe Contreras [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230424165041.25180-16-felipe.contreras@gmail.com \
    --to=felipe.contreras@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=peff@peff.net \
    --cc=tmz@pobox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).