emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/eev 07124c9ab9: Added `find-package-vc-install-links'.


From: ELPA Syncer
Subject: [elpa] externals/eev 07124c9ab9: Added `find-package-vc-install-links'.
Date: Thu, 25 Jul 2024 18:57:55 -0400 (EDT)

branch: externals/eev
commit 07124c9ab9ceafd07109e3cc5f1265e91c1936d4
Author: Eduardo Ochs <eduardoochs@gmail.com>
Commit: Eduardo Ochs <eduardoochs@gmail.com>

    Added `find-package-vc-install-links'.
---
 ChangeLog     |  4 ++++
 VERSION       |  4 ++--
 eev-blinks.el |  7 ++++++-
 eev-intro.el  | 48 +++++++++++++++---------------------------
 eev-tlinks.el | 67 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 5 files changed, 96 insertions(+), 34 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 89ac17b6ea..f7ee840c14 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2024-07-25  Eduardo Ochs  <eduardoochs@gmail.com>
+
+       * eev-tlinks.el (find-package-vc-install-links): new function.
+
 2024-07-24  Eduardo Ochs  <eduardoochs@gmail.com>
 
        * eev-blinks.el (ee-closure-to-lambda, ee-symbol-function): new
diff --git a/VERSION b/VERSION
index 6adcd6f687..992795efec 100644
--- a/VERSION
+++ b/VERSION
@@ -1,2 +1,2 @@
-Wed Jul 24 18:34:05 GMT 2024
-Wed Jul 24 15:34:05 -03 2024
+Thu Jul 25 20:17:50 GMT 2024
+Thu Jul 25 17:17:50 -03 2024
diff --git a/eev-blinks.el b/eev-blinks.el
index dfe3a22630..c71d40a034 100644
--- a/eev-blinks.el
+++ b/eev-blinks.el
@@ -1691,10 +1691,15 @@ Hint: install the Debian package \"unicode-data\".")
 ;; This is an experimental hack for handling some versions of Emacs31. See:
 ;; https://lists.gnu.org/archive/html/help-gnu-emacs/2024-07/msg00292.html
 ;; https://lists.gnu.org/archive/html/help-gnu-emacs/2024-07/msg00311.html
+;; https://lists.gnu.org/archive/html/help-gnu-emacs/2024-07/msg00328.html
+;; TODO: fix this:
+;;   (find-elisp-intro "6. Defining functions")
 
 (defun ee-closure-to-lambda (c)
   "Experimental!!! See the comments in the source!"
-  `(lambda ,(aref c 0) ,@(aref c 1)))
+  (let ((arglist (aref c 0))
+       (body    (aref c 1)))
+  `(lambda ,arglist ,@body)))
 
 (defun ee-symbol-function (sym)
   "Experimental!!! See the comments in the source!"
diff --git a/eev-intro.el b/eev-intro.el
index 86a212ed2e..d9ccf313b0 100644
--- a/eev-intro.el
+++ b/eev-intro.el
@@ -17920,45 +17920,31 @@ Use: (find-dot-emacs-links \"eev angges melpa lean4 
maxima5470 mfms\")
 
 5. Install lean4-mode
 =====================
-Check the version of your Emacs:
-  (emacs-version)
-If it is at least 29, then running this sexp should be enough:
+The instructions in
 
-  (package-vc-install \"https://github.com/leanprover-community/lean4-mode\";)
+  https://github.com/leanprover-community/lean4-mode
 
-If not then you need to download lean4-mode with this eepitch block,
-
- (eepitch-shell)
- (eepitch-kill)
- (eepitch-shell)
-# (find-fline \"~/.emacs.d/elpa/lean4-mode/\")
-  rm -Rfv  ~/.emacs.d/elpa/lean4-mode/
-  mkdir -p ~/.emacs.d/elpa/lean4-mode/
-  cd       ~/.emacs.d/elpa/lean4-mode/
-  git clone https://github.com/leanprover-community/lean4-mode .
-
-Then add \"~/.emacs.d/elpa/lean4-mode/\" to the Emacs load-path, with:
-
-(add-to-list 'load-path \"~/.emacs.d/elpa/lean4-mode/\")
-;; Tests: (find-fline \"~/.emacs.d/elpa/lean4-mode/\")
-;;        (ee-locate-library \"lean4-mode\")
-;;        (find-eppp load-path)
+are not very beginner-friendly. So: follow the instructions
+in the temporary buffer generated by the sexp below,
 
+  (find-package-vc-install-links 
\"https://github.com/leanprover-community/lean4-mode\";)
 
+then run this progn,
 
+  (progn
+    (find-2a nil '(find-ebuffer \"*Messages*\"))
+    (package-initialize)
+    (package-refresh-contents)
+    (package-install 'dash)
+    (package-install 'flycheck)
+    (package-install 'lsp-mode)
+    (package-install 'magit-section)
+    )
 
-See: https://github.com/leanprover-community/lean4-mode
-
-
-
+and try:
 
-     (find-es \"lean\" \"lean4-mode-vc\")
-     (find-efunction 'ee-locate-library)
-     (ee-locate-library \"lean4-mode\")
-     (find-eev \"eev-lean4.el\" \"etc\")
+  (require 'lean4-mode)
 
-  (package-vc-install \"https://github.com/leanprover-community/lean4-mode\";)
-  (find-lean4modefile \"README.md\")
 
 
 6. Test lean4-mode
diff --git a/eev-tlinks.el b/eev-tlinks.el
index a7ab25d6af..67d6809b7a 100644
--- a/eev-tlinks.el
+++ b/eev-tlinks.el
@@ -192,6 +192,7 @@
 ;; «.find-debootstrap1-links»          (to "find-debootstrap1-links")
 ;;   «.ee-debootstrap1»                        (to "ee-debootstrap1")
 ;; «.find-debootstrap2-links»          (to "find-debootstrap2-links")
+;; «.find-package-vc-install-links»    (to "find-package-vc-install-links")
 
 
 (require 'eev-env)
@@ -5887,6 +5888,72 @@ exit
 
 
 
+;;;                 _           _        _ _ 
+;;; __   _____     (_)_ __  ___| |_ __ _| | |
+;;; \ \ / / __|____| | '_ \/ __| __/ _` | | |
+;;;  \ V / (_|_____| | | | \__ \ || (_| | | |
+;;;   \_/ \___|    |_|_| |_|___/\__\__,_|_|_|
+;;;                                          
+;; «find-package-vc-install-links»  (to ".find-package-vc-install-links")
+;; Skel: (find-find-links-links-new "package-vc-install" "giturl" "name dir0 
dir")
+;; Test: (find-package-vc-install-links)
+;;  See: (find-lean4-intro "5. Install lean4-mode")
+;;
+(defun find-package-vc-install-links (&optional giturl &rest pos-spec-list)
+"Show a script that does part of the work of `package-vc-install'.
+GITURL must be a git url - other version control systems are not
+supported."
+  (interactive)
+  (setq giturl (or giturl "{giturl}"))
+  (let* ((name (file-name-nondirectory giturl))
+         (dir0 (ee-expand "$HOME/.emacs.d/elpa/"))
+         (dir (concat dir0 name)))
+    (apply
+     'find-elinks-elisp
+     `((find-package-vc-install-links ,giturl ,@pos-spec-list)
+       (find-package-vc-install-links 
"https://github.com/leanprover-community/lean4-mode";)
+       (find-package-vc-install-links "https://github.com/edrx/eev";)
+       ;; Convention: the first sexp always regenerates the buffer.
+       (find-efunction 'find-package-vc-install-links)
+       ""
+       ,(ee-template0 "\
+;; Check the version of your Emacs:
+;;   (emacs-version)
+;;
+;; If you're on emacs 29.1 or newer then the sexp with
+;; `package-vc-install' below should work. See:
+;;   (find-enode \"Fetching Package Sources\")
+;;   (find-efunctiondescr 'package-vc-install)
+;;
+(package-vc-install \"{giturl}\")
+
+
+;; Otherwise try the script below.
+;; It will try to download the package from:
+;;   {giturl}
+;; and install it into:
+;;   {dir}
+;;   (find-fline \"{dir0}\")
+;;   (find-fline \"{dir0}\" \"{name}\")
+;;   (find-fline \"{dir}\")
+;; ...BUT IT WILL NOT INSTALL ITS DEPENDENCIES!
+
+ (eepitch-shell)
+ (eepitch-kill)
+ (eepitch-shell)
+rm -Rfv  {dir}
+mkdir -p {dir}
+cd       {dir}
+git clone {giturl} .
+
+ (add-to-list 'load-path \"{dir}\")
+ (find-eppp load-path)
+")
+       )
+     pos-spec-list)))
+
+
+
 
 (provide 'eev-tlinks)
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]