Update modules/lang/*

This commit is contained in:
Henrik Lissner 2017-02-19 18:57:16 -05:00
parent f0adef1b01
commit e14e25ecb4
68 changed files with 1487 additions and 750 deletions

View file

@ -0,0 +1,21 @@
;;; lang/javascript/autoload.el
;;;###autoload
(defun +javascript/install ()
"Installs NodeJS and tern."
(interactive)
(pcase (doom-system-os)
('arch
(unless (and (executable-find "node")
(executable-find "npm"))
(doom-sudo "pacman --needed --noconfirm -S nodejs npm")))
('debian) ;; TODO
('macos
(unless (executable-find "node")
(doom-sh "brew install node")))
(_ (error "Not a supported OS")))
(unless (executable-find "node")
(error "node isn't installed, run `+javascript/install' again"))
(unless (executable-find "tern")
(sh "npm -g install tern")))