[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
feature/package+vc 73669f73e6 7/9: Allow specifying a package name for '
From: |
Philip Kaludercic |
Subject: |
feature/package+vc 73669f73e6 7/9: Allow specifying a package name for 'package-vc-link-directory' |
Date: |
Wed, 12 Oct 2022 15:31:34 -0400 (EDT) |
branch: feature/package+vc
commit 73669f73e65a038a6717377cf8308eba9b7ce2af
Author: Philip Kaludercic <philipk@posteo.net>
Commit: Philip Kaludercic <philipk@posteo.net>
Allow specifying a package name for 'package-vc-link-directory'
* lisp/emacs-lisp/package-vc.el (package-vc-link-directory): Add argument
NAME
---
lisp/emacs-lisp/package-vc.el | 13 ++++++++++---
1 file changed, 10 insertions(+), 3 deletions(-)
diff --git a/lisp/emacs-lisp/package-vc.el b/lisp/emacs-lisp/package-vc.el
index d513e9a733..dfa8094e61 100644
--- a/lisp/emacs-lisp/package-vc.el
+++ b/lisp/emacs-lisp/package-vc.el
@@ -339,9 +339,16 @@ be requested using REV."
;;;###autoload
(defalias 'package-checkout #'package-vc-install)
-(defun package-vc-link-directory (dir)
- "Install the package in DIR by linking it into the ELPA directory."
- (interactive (list (read-directory-name "Directory: ")))
+(defun package-vc-link-directory (dir name)
+ "Install the package NAME in DIR by linking it into the ELPA directory.
+If invoked interactively with a prefix argument, the user will be
+prompted for the package NAME. Otherwise it will be inferred
+from the base name of DIR."
+ (interactive (let ((dir (read-directory-name "Directory: ")))
+ (list dir
+ (if current-prefix-arg
+ (read-string "Package name: ")
+ (file-name-base (directory-file-name dir))))))
(unless (vc-responsible-backend dir)
(user-error "Directory %S is not under version control" dir))
(package--archives-initialize)
- feature/package+vc updated (8e6e6e6de5 -> 982c0e6c15), Philip Kaludercic, 2022/10/12
- feature/package+vc 0610e6f9f1 5/9: Rename 'package-vc-link-project' to 'package-vc-link-directory', Philip Kaludercic, 2022/10/12
- feature/package+vc 576593a2b2 2/9: Add new command to install a package via symbolic linking, Philip Kaludercic, 2022/10/12
- feature/package+vc 7cdc11ee99 8/9: Document package-vc, Philip Kaludercic, 2022/10/12
- feature/package+vc 73669f73e6 7/9: Allow specifying a package name for 'package-vc-link-directory',
Philip Kaludercic <=
- feature/package+vc 22d768a29d 4/9: Run 'package-vc-unpack-1' after updating source packages, Philip Kaludercic, 2022/10/12
- feature/package+vc 1a5e705dda 3/9: ; * lisp/vc/vc-cvs.el (vc-cvs-clone): Remove function, Philip Kaludercic, 2022/10/12
- feature/package+vc 982c0e6c15 9/9: * etc/NEWS: Mention package-vc additions, Philip Kaludercic, 2022/10/12
- feature/package+vc 4a25205ec1 1/9: Only use 'package-vc-repository-store' if necessary, Philip Kaludercic, 2022/10/12
- feature/package+vc 0e3b67e3a3 6/9: * lisp/emacs-lisp/package-vc.el (package-vc-refresh): Add function., Philip Kaludercic, 2022/10/12