summary refs log tree commit diff
diff options
context:
space:
mode:
authorFranck Cuny <franck.cuny@gmail.com>2018-07-07 19:45:53 +0000
committerFranck Cuny <franck.cuny@gmail.com>2018-07-07 19:45:53 +0000
commitb4d3aadef306b637baf68534357bbe7946727def (patch)
treefc5fb6b0390c622577405d6de658b233c361b484
parent[emacs] All spelling configs in one place. (diff)
downloademacs.d-b4d3aadef306b637baf68534357bbe7946727def.tar.gz
[emacs] Configure correctly for linux (chrome).
Ensure go binaries are in the path for emacs and add custom settings
for linux.
-rw-r--r--emacs.d/config/fcuny-darwin.el1
-rw-r--r--emacs.d/config/fcuny-linux.el5
-rw-r--r--emacs.d/config/fcuny-vars.el6
-rw-r--r--emacs.d/init.el7
4 files changed, 17 insertions, 2 deletions
diff --git a/emacs.d/config/fcuny-darwin.el b/emacs.d/config/fcuny-darwin.el
index fbc95e7..c23ff44 100644
--- a/emacs.d/config/fcuny-darwin.el
+++ b/emacs.d/config/fcuny-darwin.el
@@ -2,7 +2,6 @@
   (require 'use-package))
 
 (use-package exec-path-from-shell
-  :if (memq window-system '(mac ns))
   :ensure t
   :config
   (exec-path-from-shell-initialize)
diff --git a/emacs.d/config/fcuny-linux.el b/emacs.d/config/fcuny-linux.el
new file mode 100644
index 0000000..dc1f992
--- /dev/null
+++ b/emacs.d/config/fcuny-linux.el
@@ -0,0 +1,5 @@
+(setenv "PATH" (concat fcuny-path-go-bin path-separator (getenv "PATH")))
+
+(add-to-list 'exec-path fcuny-path-go-bin)
+
+(provide 'fcuny-linux)
diff --git a/emacs.d/config/fcuny-vars.el b/emacs.d/config/fcuny-vars.el
index cc19201..aebaadf 100644
--- a/emacs.d/config/fcuny-vars.el
+++ b/emacs.d/config/fcuny-vars.el
@@ -4,6 +4,12 @@
 (defvar fcuny-path-workspace (expand-file-name "workspace" fcuny-path-home)
   "Path to the workspace.")
 
+(defvar fcuny-path-go (expand-file-name "go" fcuny-path-workspace)
+  "Path to GOPATH.")
+
+(defvar fcuny-path-go-bin (expand-file-name "bin" fcuny-path-go)
+  "Path to the go binaries.")
+
 (defvar fcuny-path-git-twitter (expand-file-name "git.twitter.biz" fcuny-path-workspace)
   "Path to twitter's git repositories.")
 
diff --git a/emacs.d/init.el b/emacs.d/init.el
index f6989df..dd233a1 100644
--- a/emacs.d/init.el
+++ b/emacs.d/init.el
@@ -30,7 +30,12 @@
 (use-package fcuny-basic-settings)
 (use-package fcuny-common)
 (use-package fcuny-appearance)
-(use-package fcuny-darwin)
+
+(use-package fcuny-darwin
+  :if (memq window-system '(mac ns)))
+
+(use-package fcuny-linux
+  :if (string-equal system-type "gnu/linux"))
 
 (use-package fcuny-editor)
 (use-package fcuny-spell)