Don't know how to use
althought I add ob-go from melpa, but it doesn't work well. could you tell me how to config it in emacs Thank you
Hey @haormj , here is what I did:
Download the ob-go.el, add the following line to my emacs configuration:
(load-file "~/.dotfiles/ob-go.el")
I uses Spacemacs, thus this line is in the (defun dotspacemacs/user-config () block.
I loaded it via melpa, but also had to add this to my emacs init file:
(setenv "PATH" (concat (getenv "PATH") ":/usr/local/go/bin"))
(setq exec-path (append exec-path '("/usr/local/go/bin")))
(or where ever you have go installed)
@robrohan I also had the very same problem but with another ob-* package as mentioned here https://github.com/brotzeit/rustic/issues/93#issuecomment-586688568 and the documentation fix was: https://github.com/brotzeit/rustic/commit/f387594773ce68f30e3f15f041b64c0214a277a3#diff-04c6e90faac2675aa89e2176d2eec7d8R71-R74
It would be nice to mention that solution, for example, on doom emacs:
Install using MELPA M-x package-install RET exec-path-from-shell RET.
Add initialization to config.el:
(package-initialize)
;; Config environment variables
(when (memq window-system '(mac ns x))
(exec-path-from-shell-initialize))