unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Stefan Monnier <monnier@iro.umontreal.ca>
To: emacs-devel@gnu.org
Subject: Re: Function to retrieve package version
Date: Tue, 21 May 2019 17:55:19 -0400	[thread overview]
Message-ID: <jwvh89nxyn6.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: m2pnocmmn6.fsf@paulwrankin.com

> (defvar my-great-package-version
>  (package-get-version))

C-h o package-get-version RET says:

    package-get-version is an autoloaded compiled Lisp function in ‘package.el’.
    
    (package-get-version)
    
      This function does not change global state, including the match data.
    
    Return the version number of the package in which this is used.
    Assumes it is used from an Elisp file placed inside the top-level directory
    of an installed ELPA package.
    The return value is a string (or nil in case we can’t find it).


-- Stefan




  parent reply	other threads:[~2019-05-21 21:55 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-21  4:55 Function to retrieve package version Paul W. Rankin
2019-05-21  8:32 ` Michael Albinus
2019-05-21  9:08   ` Paul W. Rankin
2019-05-21  9:40     ` Michael Albinus
2019-05-21 20:18       ` Richard Stallman
2019-05-22  2:02         ` Paul W. Rankin
2019-05-22  2:26           ` Eli Zaretskii
2019-05-22  2:49             ` Paul W. Rankin
2019-05-22  7:49               ` Michael Albinus
2019-05-22  7:50               ` Eli Zaretskii
2019-05-22 22:39           ` Richard Stallman
2019-05-21 21:55 ` Stefan Monnier [this message]
2019-05-21 22:56   ` Eric Abrahamsen

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to=jwvh89nxyn6.fsf-monnier+emacs@gnu.org \
    --to=monnier@iro.umontreal.ca \
    --cc=emacs-devel@gnu.org \
    /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.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

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