hack for git packages that need to be *locked* a commit

This commit is contained in:
Donald Ephraim Curtis 2012-01-22 18:05:14 -06:00
parent cf613569d7
commit 2767583ca6
2 changed files with 11 additions and 4 deletions

View file

@ -119,7 +119,7 @@
"\\([0-9]\\{4\\}-[0-9]\\{2\\}-[0-9]\\{2\\} [0-9]\\{2\\}:[0-9]\\{2\\}:[0-9]\\{2\\}\\)")
(match-string-no-properties 1)))))))
(defun package-build-checkout-git (repo dir)
(defun package-build-checkout-git (repo dir &optional commit)
"checkout an git repo"
(with-current-buffer (get-buffer-create "*package-build-checkout*")
(goto-char (point-max))
@ -137,6 +137,11 @@
"git" nil
(current-buffer)
nil "clone" repo dir)))
(if commit
(let ((default-directory dir))
(process-file
"git" nil
(current-buffer) nil "checkout" commit)))
(let ((default-directory dir))
(process-file
"git" nil
@ -268,7 +273,8 @@
(package-build-checkout-svn repo-url pkg-cwd))
((eq repo-type 'git)
(print 'Git)
(package-build-checkout-git repo-url pkg-cwd))
(package-build-checkout-git repo-url pkg-cwd
(plist-get cfg :commit)))
((eq repo-type 'darcs)
(print 'Darcs)
(package-build-checkout-darcs repo-url pkg-cwd))))

View file

@ -54,9 +54,10 @@
:fetcher git
:files ("inf-ruby.el"))
(jump
:url "https://github.com/vhallac/jump.el.git"
:url "https://github.com/eschulte/jump.el.git"
:fetcher git
:files ("jump.el" "inflections.el" "findr.el"))
:files ("jump.el" "inflections.el" "findr.el")
:commit "0def5442723f8a2928eda7bcf428aa29f8aa97c1")
(magit
:url "git://github.com/magit/magit.git"
:fetcher git)