Skip to content

Commit

Permalink
Install go-mode with melpa
Browse files Browse the repository at this point in the history
  • Loading branch information
Zellux Yuanxuan Wang committed Mar 26, 2016
1 parent e494ee8 commit 46d6fb6
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 15 deletions.
3 changes: 0 additions & 3 deletions lang-go.el
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
(add-to-list 'load-path "~/emacs/langmode/go/go-mode" t)
(require 'go-mode-autoloads)

(defun go-mode-custom ()
(set (make-local-variable 'tab-width) 2)
(set (make-local-variable 'indent-tabs-mode) nil)
Expand Down
1 change: 1 addition & 0 deletions lang-web.el
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@

(add-to-list 'auto-mode-alist '("\\.js\\'" . jsx-mode))
(autoload 'jsx-mode "jsx-mode" "JSX mode" t)

5 changes: 5 additions & 0 deletions sys-common.el
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,11 @@
(require 'yasnippet)
(yas-global-mode 1)


(require 'package)
(add-to-list 'package-archives
'("melpa" . "http://melpa.milkbox.net/packages/") t)

(custom-set-faces
;; custom-set-faces was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
Expand Down
10 changes: 10 additions & 0 deletions sys-init.el
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
(when (< emacs-major-version 24)
(add-to-list 'load-path "~/emacs/utils/package-old"))
(require 'package)
(add-to-list 'package-archives
'("melpa" . "http://melpa.org/packages/") t)
(when (< emacs-major-version 24)
;; For important compatibility libraries like cl-lib
(add-to-list 'package-archives '("gnu" . "http://elpa.gnu.org/packages/")))
(package-initialize)

14 changes: 2 additions & 12 deletions sys-linux.el
Original file line number Diff line number Diff line change
@@ -1,16 +1,6 @@
(when (< emacs-major-version 24)
(add-to-list 'load-path "~/emacs/utils/package-old"))
(require 'package)
(add-to-list 'package-archives
'("melpa" . "http://melpa.org/packages/") t)
(when (< emacs-major-version 24)
;; For important compatibility libraries like cl-lib
(add-to-list 'package-archives '("gnu" . "http://elpa.gnu.org/packages/")))
(package-initialize)

(setq package-list '(ecb shm bm yasnippet muse popup color-theme-solarized async auto-complete-clang go-mode projectile))
(setq package-list '(ecb shm bm yasnippet muse popup color-theme-solarized async auto-complete-clang go-mode projectile go-mode))
(when (>= emacs-major-version 24)
(setq package-list '(ecb shm bm yasnippet muse helm popup color-theme-solarized async auto-complete-clang go-mode js3-mode jsx-mode)))
(setq package-list (append package-list '(helm js3-mode jsx-mode exec-path-from-shell))))

(dolist (package package-list)
(unless (package-installed-p package)
Expand Down
3 changes: 3 additions & 0 deletions sys-macosx.el
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,6 @@
(define-key (keymap-parent local-function-key-map) [S-tab] nil)

(setq ispell-program-name "/usr/local/bin/aspell")

(when (memq window-system '(mac ns))
(exec-path-from-shell-initialize))

0 comments on commit 46d6fb6

Please sign in to comment.