Quickly initialise development environments.
dev is a cli tool which runs user-defined shell commands to set up a development environment. It can be used to:
cdto the correct directory
- set environment variables
- activate a
- do anything else which can be scripted
$ echo "echo 'Initialising my environment'" > ~/.devfiles/myenv $ dev myenv Initialising my environment
$ dev Usage: dev [-h] [-v] environment Positional arguments: environment The environment to set up. Optional arguments: -h Help. Display this message and quit. -v Version. Print version number and quit.
With git, for BASH:
$ git clone git://github.com/jamesroutley/dev.git ~/.dev $ echo 'source ~/.dev/dev.sh' >> ~/.bashrc
With git, for ZSH:
$ git clone git://github.com/jamesroutley/dev.git ~/.dev $ echo 'source ~/.dev/dev.sh' >> ~/.zshrc
A new environment,
<env>, can be added by by creating the file
$DEVFILE_HOME/<env>. This file is sourced when the command
dev <env> is run, executing any shell commands stored in the file.
$DEVFILE_HOME is defaulted to
~/.devfiles, but this location can be customised by setting the environment variable
$DEVFILE_HOME before sourcing