Issue #857: use format' to simplify el-get-github-guess-website'

Signed-off-by: Damien Cassou <damien.cassou@gmail.com>
This commit is contained in:
Damien Cassou 2012-08-31 10:22:40 +02:00
parent 223a8b3843
commit fa55807644

View File

@ -115,13 +115,8 @@ FROM is a literal string, not a regexp."
(defun el-get-github-guess-website (package)
(let* ((user-and-repo (el-get-github-parse-user-and-repo package))
(username (car user-and-repo))
(reponame (cdr user-and-repo))
(url-format-string "https://github.com/%USER%/%REPO%"))
(el-get-replace-string
"%USER%" username
(el-get-replace-string
"%REPO%" reponame
url-format-string))))
(reponame (cdr user-and-repo)))
(format "https://github.com/%s/%s" username reponame)))
(el-get-register-derived-method :github :git
:install #'el-get-github-clone