]> git.eshelyaron.com Git - emacs.git/commitdiff
* lisp/editorconfig.el (editorconfig-version): Delete function
authorStefan Monnier <monnier@iro.umontreal.ca>
Thu, 20 Jun 2024 02:05:36 +0000 (22:05 -0400)
committerEshel Yaron <me@eshelyaron.com>
Fri, 21 Jun 2024 19:00:45 +0000 (21:00 +0200)
Better use a generic command like `C-h P` or `M-x list-packages`
which works uniformly for all packages.

(cherry picked from commit b72826eef971e5c0179c8b4ebca652992f33b636)

lisp/editorconfig.el

index 46b5843f99fd052e2539e752aa22850ad585a53f..02186e428916cc9a42dd53e3f29e63a54884a9cd 100644 (file)
@@ -761,36 +761,36 @@ Meant to be used on `hack-dir-local-get-variables-functions'."
 ;;     (lm-version))
 ;;   "EditorConfig version.")
 
-;;;###autoload
-(defun editorconfig-version (&optional show-version)
-  "Get EditorConfig version as string.
-
-If called interactively or if SHOW-VERSION is non-nil, show the
-version in the echo area and the messages buffer."
-  (interactive (list t))
-  (let ((version-full
-         (if (fboundp 'package-get-version)
-             (package-get-version)
-           (let* ((version
-                   (with-temp-buffer
-                     (require 'find-func)
-                     (declare-function find-library-name "find-func" (library))
-                     (insert-file-contents (find-library-name "editorconfig"))
-                     (require 'lisp-mnt)
-                     (declare-function lm-version "lisp-mnt" nil)
-                     (lm-version)))
-                  (pkg (and (eval-and-compile (require 'package nil t))
-                            (cadr (assq 'editorconfig
-                                        package-alist))))
-                  (pkg-version (and pkg (package-version-join
-                                         (package-desc-version pkg)))))
-             (if (and pkg-version
-                      (not (string= version pkg-version)))
-                 (concat version "-" pkg-version)
-               version)))))
-    (when show-version
-      (message "EditorConfig Emacs v%s" version-full))
-    version-full))
+;; ;;;###autoload
+;; (defun editorconfig-version (&optional show-version)
+;;   "Get EditorConfig version as string.
+;;
+;; If called interactively or if SHOW-VERSION is non-nil, show the
+;; version in the echo area and the messages buffer."
+;;   (interactive (list t))
+;;   (let ((version-full
+;;          (if (fboundp 'package-get-version)
+;;              (package-get-version)
+;;            (let* ((version
+;;                    (with-temp-buffer
+;;                      (require 'find-func)
+;;                      (declare-function find-library-name "find-func" (library))
+;;                      (insert-file-contents (find-library-name "editorconfig"))
+;;                      (require 'lisp-mnt)
+;;                      (declare-function lm-version "lisp-mnt" nil)
+;;                      (lm-version)))
+;;                   (pkg (and (eval-and-compile (require 'package nil t))
+;;                             (cadr (assq 'editorconfig
+;;                                         package-alist))))
+;;                   (pkg-version (and pkg (package-version-join
+;;                                          (package-desc-version pkg)))))
+;;              (if (and pkg-version
+;;                       (not (string= version pkg-version)))
+;;                  (concat version "-" pkg-version)
+;;                version)))))
+;;     (when show-version
+;;       (message "EditorConfig Emacs v%s" version-full))
+;;     version-full))
 
 (provide 'editorconfig)
 ;;; editorconfig.el ends here