Skip to content

Commit

Permalink
Add support for el-get-master-branch in el-get-install.el for easier …
Browse files Browse the repository at this point in the history
…"developper" install.
  • Loading branch information
dimitri committed Sep 10, 2011
1 parent a06374c commit a46c02c
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 12 deletions.
17 changes: 17 additions & 0 deletions README.asciidoc
Expand Up @@ -73,6 +73,23 @@ avoid this with the following snippet instead:
See next section for details about how to setup you emacs so that it's able
to benefit from +el-get+ automatically.

== How to install the developer version (master branch)?

The 'lazy installer' uses the default +el-get-install.el+ file which targets
the +2.stable+ branch. To install el-get directly on the +master+ branch,

This comment has been minimized.

Copy link
@dabrahams

dabrahams Apr 1, 2012

Contributor

2.stable is self-reported as being version 2.2 IIUC the latest stable is 3.1

summon the +el-get-master-branch+ variable into existence:

--------------------------------------
;; So the idea is that you copy/paste this code into your *scratch* buffer,
;; hit C-j, and you have a working developper edition of el-get.
(url-retrieve
"https://raw.github.com/dimitri/el-get/master/el-get-install.el"
(lambda (s)
(let (el-get-master-branch)
(end-of-buffer)
(eval-print-last-sexp))))
--------------------------------------

== Basic usage

Now that +el-get+ is installed, simply use +M-x el-get-install+ and pick
Expand Down
25 changes: 13 additions & 12 deletions el-get-install.el
Expand Up @@ -51,19 +51,20 @@
(error "Couldn't clone el-get from the Git repository: %s" url))

;; switch branch if we have to
(let* ((branch (plist-get (with-temp-buffer
(insert-file-contents-literally
(expand-file-name "recipes/el-get.rcp" pdir))
(read (current-buffer)))
:branch))
(branch (when branch (concat "origin/" branch)))
(default-directory pdir)
(bstatus
(when branch
(call-process git nil `(,buf t) t "checkout" "-t" branch))))
(unless (boundp 'el-get-master-branch)
(let* ((branch (plist-get (with-temp-buffer
(insert-file-contents-literally
(expand-file-name "recipes/el-get.rcp" pdir))
(read (current-buffer)))
:branch))
(branch (when branch (concat "origin/" branch)))
(default-directory pdir)
(bstatus
(when branch
(call-process git nil `(,buf t) t "checkout" "-t" branch))))

(when (and branch (not (zerop bstatus)))
(error "Couldn't `git checkout -t %s`" branch)))
(when (and branch (not (zerop bstatus)))
(error "Couldn't `git checkout -t %s`" branch))))

(load (concat pdir package ".el"))
(el-get-post-install "el-get")
Expand Down

0 comments on commit a46c02c

Please sign in to comment.