-
古く枯れたソフト/バージョンで構成された環境でも困らない設定
- 操作者としての自分が困らない
- 上位互換のキーバインド設定
- tmux を普段使いする場合も、キーバインドは screen 互換
- helm-for-files は C-x b にバインド
- 上位互換のキーバインド設定
- レガシーな環境に設定ファイルを持ち込んでも問題無いように
- OS による分岐
- コマンドの存在を確認してからロード
- 操作者としての自分が困らない
-
設定に時間をかけすぎない
- 鬼門
- 色指定
- escape sequence
- 鬼門
-
覚えることは少なく
- Anything 的機能を積極的に導入
- helm, peco
- 「ポケットひとつ」にはそれなりに拘る
- 環境非依存に
- OS による分岐は少なめに
- OS X でも ghq のインストールは (homebrew ではなく) go 経由
- 特に実験に関わるもの (python など) は共通のフローで管理
- Anything 的機能を積極的に導入
- モード毎の設定
- 「auto-complete-mode をデフォルトで有効にするか」は autocomplete.el にまとめて記述
- ag (the silver searcher)
- Cask
- python
- git
- ghq
- peco
- zsh
```shell
# symbolic links
$ ./init-osx.sh
# ime
$ sudo cp /System/Library/Input\ Methods/JapaneseIM.app/Contents/Resources/KeySetting_Default.plist /System/Library/Input\ Methods/JapaneseIM.app/Contents/Resources/KeySetting_Default.plist.orig
$ ./init-osx-JapaneseIM.sh
```
```shell
$ brew update
$ brew doctor
$ brew upgrade
$ brew install rcmdnk/file/brew-file
$ brew file install
```
-
/etc/shells
に追記/usr/local/bin/zsh
-
ログインシェルの変更
$ chsh -s /usr/local/bin/zsh
-
/etc/zprofile
をコメントアウト (El Capitan 以後)
-
ログインシェルの変更
$ which zsh $ chsh -s /path/to/zsh
$ which zsh $ ypchsh > {password} $ /path/to/zsh
-
バイナリ版を落として使う
-
CPUの確認
$ uname -a
- x86_64 -> amd64
- i389 -> 386
-
ダウンロードしてパスが通っているディレクトリへ
$ wget https://github.com/peco/peco/releases/download/v0.*.*/peco_linux_***.tar.gz $ tar zxvf peco_linux_***.tar.gz $ mv peco_linux_***/peco $HOME/local/bin $ rm -rf peco_linux_***
-
.emacs.d 移行後にインストールすれば,初期化までしてくれる?
-
installation
$ curl -fsSL https://raw.githubusercontent.com/cask/cask/master/go | python
-
or
git clone https://github.com/cask/cask.git $HOME/.cask
-
or
git clone [email protected]:cask/cask.git $HOME/.cask
-
-
upgrade cask
$ cask upgrade-cask
- path
- RSA 公開鍵作成
$ ssh-keygen -t rsa -C "[email protected]"
# to generate ~/.ssh/id_rsa, id_rsa.pub
$ chmod 600 id_rsa
# もともと 600 だと思うけど一応
- ~/.ssh/config に以下を追加 (スペースはすべてタブ)
Host bitbucket.org
HostName bitbucket.org
IdentityFile ~/.ssh/id_rsa
User git
Host github
Hostname github.com
IdentityFile ~/.ssh/id_rsa
User git
-
GitHub
- 右上自分アイコン→settings
- SSH Keys
- Add SSH key
- id_rsa.pub の中身を登録
-
Bitbucket
- 右上自分アイコン→Settings
- SSH keys
- Add key
- id_rsa.pub の中身を登録
-
post processing
$ ssh -T [email protected]
- ghq で管理している src を移行 (可能なら Dropbox 経由?)
$ cd
$ git clone [email protected]:eumesy/dotfiles.git ~/.dotfiles
$ ln -sf ~/.dotfiles/Brewfile ~/Brewfile
$ ln -sf ~/.dotfiles/.aspell.conf ~/.aspell.conf
$ ln -sf ~/.dotfiles/.emacs.d ~/.emacs.d
$ ln -sf ~/.dotfiles/.gitconfig ~/.gitconfig
$ ln -sf ~/.dotfiles/.gitignore.global ~/.gitignore
$ ln -sf ~/.dotfiles/.screenrc ~/.screenrc
$ ln -sf ~/.dotfiles/.template ~/.template
$ ln -sf ~/.dotfiles/.tmux.conf ~/.tmux.conf
$ ln -sf ~/.dotfiles/.peco ~/.peco
$ ln -sf ~/.dotfiles/.pip_requirements ~/.pip_requirements
$ ln -sf ~/.dotfiles/.pip_requirements_anaconda ~/.pip_requirements_anaconda
$ ln -sf ~/.dotfiles/.zshenv ~/.zshenv
$ ln -sf ~/.dotfiles/.zshenv.darwin ~/.zshenv.darwin
$ ln -sf ~/.dotfiles/.zshenv.linux ~/.zshenv.linux
$ ln -sf ~/.dotfiles/.zshrc ~/.zshrc
$ ln -sf ~/.dotfiles/.zshrc.darwin ~/.zshrc.darwin
$ ln -sf ~/.dotfiles/.zshrc.linux ~/.zshrc.linux
$ ln -sf ~/.dotfiles/.zsh ~/.zsh
$ ln -sf ~/.dotfiles/mendeley/publicationAbbreviations ~/Library/Application\ Support/Mendeley\ Desktop
$ zsh
$ rm -f ~/.zcompdump; compinit
$ cd ~/.emacs.d/
$ cask
ln -f: 上書き
- pyenv, virtualenv
$ ghq get [email protected]:yyuu/pyenv.git
$ ln -sf ~/src/github.com/yyuu/pyenv ~/.pyenv
$ ghq get [email protected]:yyuu/pyenv-virtualenv.git
$ ln -sf ~/src/github.com/yyuu/pyenv-virtualenv ~/.pyenv/plugins/pyenv-virtualenv
$ source ~/.zshrc
- 実験環境
$ pyenv install anaconda2-2.4.1
$ pyenv global anaconda2-2.4.1
$ pip install -r ~/.pip_requirements_anaconda
$ git add .
$ git commit -m "some comments"
$ git push origin master
$ git pull