diff --git a/init.org b/init.org index f48f299..c98bc4b 100644 --- a/init.org +++ b/init.org @@ -63,8 +63,12 @@ Some background is important to understand my keybinding choices - :fetcher git :url "https://github.com/quelpa/quelpa-use-package.git")) (require 'quelpa-use-package) +;; Don't upgrade Quelpa packages if there's no connectivity. +;; Courtesy https://emacs.stackexchange.com/a/18515 +(defun my-internet-up-p (host) + (= 0 (call-process "ping" nil nil nil "-c" "1" "-W" "1" host))) (setq quelpa-checkout-melpa-p nil - quelpa-upgrade-p t) + quelpa-upgrade-p (my-internet-up-p "github.com")) #+END_SRC * TODO dvorak [60%]