My Development Environment Checklist
Lately I’ve been admitted as intern at a tech startup to work on a SDK. To begin the development, my first task is to get my development environment ready. This job allows me to take time to reflect on what I’ve done to make it cozy, and how to make it better or even streamlined.
Configure Shell
Install zsh
Try zsh --version
to see if Z shell has been installed. If not, use package manager if you have root access, or build zsh from source.
Using package manager
Install zsh by following the instructions here:
# on centos
sudo yum update && sudo yum -y install zsh
# on ubuntu
sudo apt install zsh
Building zsh from source (optional)
You may build zsh from source if you don’t have root access.
wget ftp://ftp.zsh.org/pub/zsh-5.6.2.tar.xz
tar xf zsh-5.6.2.tar.xz
cd zsh-5.6.2
./configure --prefix=${HOME}/local
make -j && make check && make install
Make zsh your default shell
On Centos, add ${HOME}/local/bin/zsh-5.6.2 -l
.
On Ubuntu, do chsh -s $(which zsh)
.
if you don’t have a .zshrc template, you can copy from GitHub and change accordingly.
Install oh-my-zsh
This is as simple as one line of command:
sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
Config oh-my-zsh
In ~.zshrc
, do the following:
- change theme to
ZSH_THEME="af-magic"
- add
plugins=(autojump)
- (optional) configure python environment
# make python3 the default python version to use with virtualenv
export VIRTUALENVWRAPPER_PYTHON=/usr/bin/python3
export VIRTUALENVWRAPPER_VIRTUALENV_ARGS=' -p /usr/bin/python3 '
Then do source ~/.zshrc
to reload the environment.
Configure Vim
Update vim
Install awesome-vim
git clone --depth=1 https://github.com/amix/vimrc.git ~/.vim_runtime
sh ~/.vim_runtime/install_awesome_vimrc.sh
Install Vundle
Use vundle to manage plugins like
- NERDTree
- bufexplorer
- YouCompleteMe
Config vim
Basically just copy ~/.vim_runtime/my_configs.vim
to the counterpart :p
Configure tmux
Install tmux
To install tmux without root access, see my another post.
Config tmux
Use the tmux conf file here.
$ cd ~
$ git clone https://github.com/gpakosz/.tmux.git
$ ln -s -f .tmux/.tmux.conf
$ cp .tmux/.tmux.conf.local .
Other utilities & tools
- homebrew (on MacOS)
- htop
- gcc-4.9 (for OpenMP support on MacOS)