Starter Kit Site Lisp

This is part of the Emacs Starter Kit.

Starter Kit Site Lisp

The purpose of this code is to download, if necessary, missing lisp code that can not be retrieved through ELPA package. Maybe this can be better done using el-get package. No update mechanism is implemented but in the same time, the packages retrieved this way are not fashion enough (otherwise there have been added to melpa).

Download code

(defun install-site-lisp-file (package urls)
  "Function to get a remote lisp file."
  (let (dir file)
    (setq dir (concat starter-kit-lisp-directory package "/"))
    ;; Make sure the directory exists and add it to the load path
    (make-directory dir t)
    (add-to-list 'load-path dir)
    ;; Loop over urls
    (while urls
      (let (url file)
        (setq url (pop urls))
        (setq file (concat dir (file-name-nondirectory url)))
        (message "URL %s" file)
        (when (not (file-exists-p file))
          (url-copy-file url file t))))))

External Lisp files

trac-wiki

(install-site-lisp-file
 "trac-wiki"
 (list "https://raw.github.com/tiborsimko/trac-wiki-el/master/trac-wiki.el"))

inertial-scroll

(install-site-lisp-file
 "inertial-scroll"
 (list
 "https://raw.github.com/kiwanami/emacs-inertial-scroll/master/inertial-scroll.el"
 "https://raw.github.com/kiwanami/emacs-deferred/master/concurrent.el"
 "https://raw.github.com/kiwanami/emacs-deferred/master/deferred.el"))
File under version control - commit 135971e - 2014-11-29