feat(clone): add function to clone from a known URL
This commit is contained in:
13
majjit.el
13
majjit.el
@@ -141,6 +141,19 @@ If COLOCATE-P is t, colocate the repository with git."
|
||||
repository
|
||||
(magit-convert-filename-for-git directory))))
|
||||
|
||||
;;;###autoload
|
||||
(defun majjit-clone-from-url (url)
|
||||
"Clone a repository from a known URL."
|
||||
(let ((directory (read-directory-name
|
||||
"Clone to: "
|
||||
(if (functionp majjit-default-directory)
|
||||
(funcall majjit-default-directory)
|
||||
majjit-default-directory)
|
||||
nil nil
|
||||
(magit-clone--url-to-name url)))
|
||||
(colocate-p (yes-or-no-p "Colocate? ")))
|
||||
(majjit--internal url directory colocate-p)))
|
||||
|
||||
;;;###autoload
|
||||
(defun majjit-clone (repository directory colocate-p)
|
||||
"Clone a git REPOSITORY using jujutsu into a DIRECTORY.
|
||||
|
||||
Reference in New Issue
Block a user