Skip to content

Commit

Permalink
go 対応
Browse files Browse the repository at this point in the history
  • Loading branch information
y-ohgi committed Jun 4, 2018
1 parent 4a59a94 commit 0c56075
Show file tree
Hide file tree
Showing 4 changed files with 33 additions and 3 deletions.
8 changes: 7 additions & 1 deletion .bash_profile
Expand Up @@ -4,6 +4,7 @@ GHQ_ROOT_PATH=$(ghq root)

. ~/.bashrc
[[ -s ~/.bash_profile_cmp ]] && . ~/.bash_profile_cmp
[[ -s ~/.gvm/scripts/gvm ]] && . ~/.gvm/scripts/gvm
. ${BREW_PREFIX}/etc/profile.d/z.sh
. ${BREW_PREFIX}/etc/bash_completion
. /usr/local/opt/kube-ps1/share/kube-ps1.sh
Expand All @@ -13,7 +14,9 @@ if [ -e `ghq list --full-path | grep enhancd | head -n 1` ]; then
fi


export "PATH=$PATH:/usr/local/Caskroom/google-cloud-sdk/latest/google-cloud-sdk/bin/"
export GOPATH=$HOME/.go
export PATH=$PATH:$GOPATH/bin #TODO
export PATH=$PATH:/usr/local/Caskroom/google-cloud-sdk/latest/google-cloud-sdk/bin/

if [[ "${TMUX}" != "" ]]; then
export EDITOR=emacsclient
Expand All @@ -32,6 +35,7 @@ alias pbcopy="nkf -w | __CF_USER_TEXT_ENCODING=0x$(printf %x $(id -u)):0x0800010
eval "$(direnv hook bash)"
alias direnv="EDITOR=vi direnv"

alias emacs="emacs -nw"

mkcd() {
mkdir -p -- "$1" &&
Expand Down Expand Up @@ -176,3 +180,5 @@ _gcp_project() {
_last_result() {
[[ ${LAST_EXEC:-0} != "0" ]] && echo ""
}


2 changes: 1 addition & 1 deletion .spacemacs
Expand Up @@ -379,7 +379,7 @@ before packages are loaded. If you are unsure, you should try in setting them in
'(global-undo-tree-mode t)
'(package-selected-packages
(quote
(dockerfile-mode nginx-mode pbcopy smartrep yaml-mode web-beautify smeargle orgit mmm-mode markdown-toc markdown-mode magit-gitflow livid-mode skewer-mode simple-httpd json-mode json-snatcher json-reformat js2-refactor multiple-cursors js2-mode js-doc helm-gitignore helm-ghq helm-company helm-c-yasnippet gitignore-mode gitconfig-mode gitattributes-mode git-timemachine git-messenger git-link gh-md fuzzy flyspell-correct-helm flyspell-correct flycheck-pos-tip pos-tip flycheck evil-magit magit magit-popup git-commit ghub with-editor editorconfig company-tern dash-functional tern company-statistics company coffee-mode auto-yasnippet yasnippet auto-dictionary ac-ispell auto-complete ws-butler winum which-key volatile-highlights vi-tilde-fringe uuidgen use-package toc-org spaceline restart-emacs request rainbow-delimiters popwin persp-mode pcre2el paradox org-plus-contrib org-bullets open-junk-file neotree move-text macrostep lorem-ipsum linum-relative link-hint indent-guide hungry-delete hl-todo highlight-parentheses highlight-numbers highlight-indentation helm-themes helm-swoop helm-projectile helm-mode-manager helm-make helm-flx helm-descbinds helm-ag google-translate golden-ratio flx-ido fill-column-indicator fancy-battery eyebrowse expand-region exec-path-from-shell evil-visualstar evil-visual-mark-mode evil-unimpaired evil-tutor evil-surround evil-search-highlight-persist evil-numbers evil-nerd-commenter evil-mc evil-matchit evil-lisp-state evil-indent-plus evil-iedit-state evil-exchange evil-escape evil-ediff evil-args evil-anzu eval-sexp-fu elisp-slime-nav dumb-jump diminish define-word column-enforce-mode clean-aindent-mode auto-highlight-symbol auto-compile aggressive-indent adaptive-wrap ace-window ace-link ace-jump-helm-line)))
(powerline spinner hydra parent-mode projectile pkg-info epl flx smartparens iedit anzu evil goto-chg undo-tree highlight f s dash bind-map bind-key packed helm avy helm-core async popup dockerfile-mode nginx-mode pbcopy smartrep yaml-mode web-beautify smeargle orgit mmm-mode markdown-toc markdown-mode magit-gitflow livid-mode skewer-mode simple-httpd json-mode json-snatcher json-reformat js2-refactor multiple-cursors js2-mode js-doc helm-gitignore helm-ghq helm-company helm-c-yasnippet gitignore-mode gitconfig-mode gitattributes-mode git-timemachine git-messenger git-link gh-md fuzzy flyspell-correct-helm flyspell-correct flycheck-pos-tip pos-tip flycheck evil-magit magit magit-popup git-commit ghub with-editor editorconfig company-tern dash-functional tern company-statistics company coffee-mode auto-yasnippet yasnippet auto-dictionary ac-ispell auto-complete ws-butler winum which-key volatile-highlights vi-tilde-fringe uuidgen use-package toc-org spaceline restart-emacs request rainbow-delimiters popwin persp-mode pcre2el paradox org-plus-contrib org-bullets open-junk-file neotree move-text macrostep lorem-ipsum linum-relative link-hint indent-guide hungry-delete hl-todo highlight-parentheses highlight-numbers highlight-indentation helm-themes helm-swoop helm-projectile helm-mode-manager helm-make helm-flx helm-descbinds helm-ag google-translate golden-ratio flx-ido fill-column-indicator fancy-battery eyebrowse expand-region exec-path-from-shell evil-visualstar evil-visual-mark-mode evil-unimpaired evil-tutor evil-surround evil-search-highlight-persist evil-numbers evil-nerd-commenter evil-mc evil-matchit evil-lisp-state evil-indent-plus evil-iedit-state evil-exchange evil-escape evil-ediff evil-args evil-anzu eval-sexp-fu elisp-slime-nav dumb-jump diminish define-word column-enforce-mode clean-aindent-mode auto-highlight-symbol auto-compile aggressive-indent adaptive-wrap ace-window ace-link ace-jump-helm-line)))
'(undo-tree-visualizer-diff t)
'(undo-tree-visualizer-timestamps t))
(custom-set-faces
Expand Down
19 changes: 18 additions & 1 deletion README.md
Expand Up @@ -3,10 +3,27 @@ dotfiles

# local
```
$ brew install z direnv bash-completion stern kubectx kube-ps1 reattach-to-user-namespace ghq peco fzf extract_url
$ brew install z direnv bash-completion stern kubectx kube-ps1 reattach-to-user-namespace ghq peco fzf extract_url tmux emacs-plus
$ ./dotfilesLink.sh
$ ghq get https://github.com/b4b4r07/enhancd
$ source ~/.ghq/github.com/b4b4r07/enhancd/init.sh
$ gvm install go1.4 -B
$ gvm use go1.4
$ export GOROOT_BOOTSTRAP=$GOROOT
$ gvm install go1.10.1
$ gvm use go1.10.1 --default
```

## one liner
```
$ xcode-select --install && \
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" && \
brew tap d12frosted/emacs-plus && \
brew install z direnv bash-completion stern kubectx kube-ps1 reattach-to-user-namespace ghq peco fzf extract_url tmux emacs-plus mercurial && \
brew tap caskroom/fonts && \
brew cask install font-source-code-pro && \
git clone https://github.com/syl20bnr/spacemacs ~/.emacs.d && \
bash < <(curl -s -S -L https://raw.githubusercontent.com/moovweb/gvm/master/binscripts/gvm-installer)
```

# gui
Expand Down
7 changes: 7 additions & 0 deletions scripts/init-spacemacs-go-layer
@@ -0,0 +1,7 @@
#!/bin/sh

go get -u -v github.com/nsf/gocode
go get -u -v github.com/rogpeppe/godef
go get -u -v golang.org/x/tools/cmd/guru
go get -u -v golang.org/x/tools/cmd/gorename
go get -u -v golang.org/x/tools/cmd/goimports

0 comments on commit 0c56075

Please sign in to comment.