From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: "Bozhidar Batsov" Newsgroups: gmane.emacs.devel Subject: Re: [nongnu] elpa/clojure-ts-mode 649bf1120f: Improve the package version reporting Date: Tue, 04 Jun 2024 12:49:41 +0300 Message-ID: <4f140800-7d58-4465-aaa4-2e06f591ae77@app.fastmail.com> References: <171748798553.6513.6711701045751855775@vcs2.savannah.gnu.org> <20240604075945.DB087C1F9CB@vcs2.savannah.gnu.org> <878qzlcbvx.fsf@posteo.net> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=a641e178cd314af289d1277d9935da56 Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="22487"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Cyrus-JMAP/3.11.0-alpha0-497-g97f96844c-fm-20240526.001-g97f96844 To: "Philip Kaludercic" , "Emacs Devel" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Jun 04 11:50:34 2024 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1sEQoK-0005dM-2A for ged-emacs-devel@m.gmane-mx.org; Tue, 04 Jun 2024 11:50:33 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sEQnz-0003Na-88; Tue, 04 Jun 2024 05:50:11 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sEQnv-0003ND-8L for emacs-devel@gnu.org; Tue, 04 Jun 2024 05:50:07 -0400 Original-Received: from wfout3-smtp.messagingengine.com ([64.147.123.146]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sEQnt-0007RP-4r for emacs-devel@gnu.org; Tue, 04 Jun 2024 05:50:07 -0400 Original-Received: from compute7.internal (compute7.nyi.internal [10.202.2.48]) by mailfout.west.internal (Postfix) with ESMTP id A25D61C0008D; Tue, 4 Jun 2024 05:50:02 -0400 (EDT) Original-Received: from imap43 ([10.202.2.93]) by compute7.internal (MEProxy); Tue, 04 Jun 2024 05:50:02 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=batsov.dev; h=cc :content-type:content-type:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:subject :subject:to:to; s=fm3; t=1717494602; x=1717581002; bh=cdtcDxKdqY KiOHktV7D7t8lI6ccj0NFncxZzdP72P1Q=; b=Pa0bZ6H34AeaKS64wPFnM9jtju xv/mqTQ26w5BVQk5FRsP1JVrnDR4gzYg+7X9fLju1eWnSGYMIuWccEFu6E6EvuhX 3NNSWDjHV3Vhb1ZFa6jdKKxt0bNA90chdveiTMN1i/++bB8ikgmmwwbWDQDntVE7 8bmCYV0M8E4NMB+0dsvgLvUlCgUA926FGJ7WyfOkJH4D3xFcCr9jVv63YnhlGrmc 2QWsFgFuEsZYq4YXPlZBCnABBqcpUCUl25F0p/lMMsqiZUReOi+bvpFrngYfqLBA TbU//XmA0R23icNdln2p5iiy6w8d+/lVgux36h+CKqShrW5+8Ja/F+exTkXA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:subject:subject:to :to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm1; t=1717494602; x=1717581002; bh=cdtcDxKdqYKiOHktV7D7t8lI6ccj 0NFncxZzdP72P1Q=; b=QLgyzHj9o8hBDvDP0fnxWgWqElgyN4pIYDizCj0CKMg5 Isd80ErAYX2kyBc0TUxw4oV56ID5WO0zWV2FQ7lqcotITSDlPUTNedpLWveLO13o 2ZyC1KASe/DdPnJDYWq3BPZdwbNVL8Dtc4djq7/bDayYcjxpV1b7EzusnEhC6f5a zm1qz364UDsi/svWcZIh5s4qr9Kp+2VAX2qUfb5dC3j5jo8dwGd+3aZ9xMOE8kPy m4pZjqtQidwsrsNDbqj/ffNTMN79+rUrZlNaIOrAxcg72s0XY5N34K+ovtwUmQE6 h47FHQZ70K321Zzf4oRftjKSNYvNTgomhk2g4/eQsA== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvledrvdelgedgudejucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepofgfggfkjghffffhvffutgesrgdtreerreertdenucfhrhhomhepfdeuohii hhhiuggrrhcuuegrthhsohhvfdcuoegsohiihhhiuggrrhessggrthhsohhvrdguvghvqe enucggtffrrghtthgvrhhnpeeiteeuheevvddujefhteejvdegheelhedtkefhvdethefh feefiedtkeekheeihfenucffohhmrghinhepghhithhhuhgsrdgtohhmnecuvehluhhsth gvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepsghoiihhihgurghrsegs rghtshhovhdruggvvh X-ME-Proxy: Feedback-ID: i025946a9:Fastmail Original-Received: by mailuser.nyi.internal (Postfix, from userid 501) id 0269C2D4007D; Tue, 4 Jun 2024 05:50:02 -0400 (EDT) X-Mailer: MessagingEngine.com Webmail Interface In-Reply-To: Received-SPF: pass client-ip=64.147.123.146; envelope-from=bozhidar@batsov.dev; helo=wfout3-smtp.messagingengine.com X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:319815 Archived-At: --a641e178cd314af289d1277d9935da56 Content-Type: text/plain having => have not On Tue, Jun 4, 2024, at 12:46 PM, Bozhidar Batsov wrote: > I guess you having used MELPA, right? The package versions there are replaced with a timestamp, so they are not very useful if they are not complemented by the actual version. That's why for development versions I'd like to see them both in the user reports. > > On Tue, Jun 4, 2024, at 12:09 PM, Philip Kaludercic wrote: >> ELPA Syncer writes: >> >> > branch: elpa/clojure-ts-mode >> > commit 649bf1120f10250d464d4e9ad1905b481d2e504c >> > Author: Bozhidar Batsov >> > Commit: Bozhidar Batsov >> > >> > Improve the package version reporting >> > --- >> > clojure-ts-mode.el | 9 +++++---- >> > 1 file changed, 5 insertions(+), 4 deletions(-) >> > >> > diff --git a/clojure-ts-mode.el b/clojure-ts-mode.el >> > index 99f28cd20a..d2be3e737c 100644 >> > --- a/clojure-ts-mode.el >> > +++ b/clojure-ts-mode.el >> > @@ -54,7 +54,6 @@ >> > >> > ;;; Code: >> > (require 'treesit) >> > -(require 'lisp-mnt) >> > >> > (declare-function treesit-parser-create "treesit.c") >> > (declare-function treesit-node-eq "treesit.c") >> > @@ -71,8 +70,7 @@ >> > :link '(emacs-commentary-link :tag "Commentary" "clojure-mode")) >> > >> > (defconst clojure-ts-mode-version >> > - (eval-when-compile >> > - (lm-version (or load-file-name buffer-file-name))) >> > + "0.2.2" >> > "The current version of `clojure-ts-mode'.") >> > >> > (defcustom clojure-ts-comment-macro-font-lock-body nil >> > @@ -884,7 +882,10 @@ forms like deftype, defrecord, reify, proxy, etc." >> > (defun clojure-ts-mode-display-version () >> > "Display the current `clojure-mode-version' in the minibuffer." >> > (interactive) >> > - (message "clojure-ts-mode (version %s)" clojure-ts-mode-version)) >> > + (let ((pkg-version (package-get-version))) >> > + (if pkg-version >> > + (message "clojure-ts-mode %s (package: %s)" clojure-ts-mode-version pkg-version) >> > + (message "clojure-ts-mode %s" clojure-ts-mode-version)))) >> > >> > (defconst clojure-ts-grammar-recipes >> > '((clojure "https://github.com/sogaiu/tree-sitter-clojure.git" >> >> I don't understand the point of this change. If you duplicate the >> information of the package version anyway, then why use >> `package-get-version' at all? The only advantage this seems to bring is >> that if you forget to bump the version in `clojure-ts-mode-version' that >> you can find out about the discrepancy, but then it is too late and >> confusing. >> >> (Generally, I just don't think these kinds of "version information" >> commands are really useful anymore, at least since package management >> has become the widespread norm.) >> >> -- >> Philip Kaludercic on peregrine >> >> > --a641e178cd314af289d1277d9935da56 Content-Type: text/html Content-Transfer-Encoding: quoted-printable
having =3D= > have not

On Tue, Jun 4, 2024, at 12:46= PM, Bozhidar Batsov wrote:
I guess you having used MELPA, right? The package versi= ons there are replaced with a timestamp, so they are not very useful if = they are not complemented by the actual version. That's why for developm= ent versions I'd like to see them both in the user reports.

On Tue, Jun 4, 2024, at 12:09 PM, Philip Kaludercic wro= te:
ELPA= Syncer <elpasync@gnu.org>= writes:

> branch: elpa/clojure-ts-mode<= br>
> commit 649bf1120f10250d464d4e9ad1905b481d2e504c
> Author: Bozhidar Batsov <bozhidar@batsov.dev>
> Commit: Bozhidar= Batsov <bozhidar@batsov.dev>
>
> diff --git a/clojure-ts-mode.el b/clojure-ts-mode.el
> index 99f28cd20a..d2be3e737c 100644
> --- a/= clojure-ts-mode.el
> +++ b/clojure-ts-mode.el
=
> @@ -54,7 +54,6 @@
>  
>  ;;; Code:
>  (require 'treesit)
> -(require 'lisp-mnt)
>  
>  (declare-function treesit-parser-create "treesit.c")
>  (declare-function treesit-node-eq "treesit.c")
> @@ -71,8 +70,7 @@
>   = :link '(emacs-commentary-link :tag "Commentary" "clojure-mode"))
>  
>  (defconst clojure-ts-m= ode-version
> -  (eval-when-compile
= > -    (lm-version (or load-file-name buffer-file-name= )))
> +  "0.2.2"
>  &nb= sp; "The current version of `clojure-ts-mode'.")
> = ; 
>  (defcustom clojure-ts-comment-macro-fon= t-lock-body nil
> @@ -884,7 +882,10 @@ forms like defty= pe, defrecord, reify, proxy, etc."
>  (defun cloju= re-ts-mode-display-version ()
>    "Disp= lay the current `clojure-mode-version' in the minibuffer."
>    (interactive)
> -  (messag= e "clojure-ts-mode (version %s)" clojure-ts-mode-version))
> +  (let ((pkg-version (package-get-version)))
&= gt; +    (if pkg-version
> +  =       (message "clojure-ts-mode %s (package: %s= )" clojure-ts-mode-version pkg-version)
> +  =     (message "clojure-ts-mode %s" clojure-ts-mode-version= ))))
>  
>  (defconst c= lojure-ts-grammar-recipes

=
I don't understand the point of this change.  If you duplicate= the
information of the package version anyway, then why u= se
`package-get-version' at all?  The only advantage = this seems to bring is
that if you forget to bump the vers= ion in `clojure-ts-mode-version' that
you can find out abo= ut the discrepancy, but then it is too late and
confusing.=

(Generally, I just don't think these kinds= of "version information"
commands are really useful anymo= re, at least since package management
has become the wides= pread norm.)

-- 
Philip = Kaludercic on peregrine




--a641e178cd314af289d1277d9935da56--