Skip to content

Instantly share code, notes, and snippets.

@peterstuart
Created December 12, 2019 22:20
Show Gist options
  • Save peterstuart/83f1c79065cbe727b66257a11f61e656 to your computer and use it in GitHub Desktop.
Save peterstuart/83f1c79065cbe727b66257a11f61e656 to your computer and use it in GitHub Desktop.

Put this in ~/.emacs.d/init.el:

(require 'package)
(add-to-list
  'package-archives
  '("melpa" . "http://melpa.org/packages/") t)
(package-initialize)
(package-refresh-contents)
(package-install 'use-package)

;; On macOS, get the path from the shell
(use-package exec-path-from-shell
  :config (exec-path-from-shell-initialize)
  :ensure)


;; General:
(use-package add-node-modules-path
  :ensure)
(use-package eslint-fix
  :ensure)
(use-package coffee-mode
  :after (add-node-modules-path)
  :config
  (add-hook 'coffee-mode-hook 'add-node-modules-path)
  (add-hook 'coffee-mode-hook (lambda () (add-hook 'after-save-hook 'eslint-fix nil t)))
  :ensure)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment