Requires Node.js and ttab
npm install ttab -g
In ~/bin/start
:
#!/usr/bin/env bash
dir=$(basename $(pwd))
if [ "$dir" == "hyperion" ]; then
command="env IRIS_HOST=http://localhost:4000 npm start"
elif [ "$dir" == "iris-core" ]; then
command="env LOG_LEVEL=debug IRIS_SITE=aftonbladet npm run start:dev:watch"
else
echo "Don't know how to start app in dir $dir"
exit 1
fi
echo "starting app in $dir: $command"
$command
In ~/bin/open-dev
:
#!/usr/bin/env bash
ttab "cd ~/src/hyperion"
ttab "cd ~/src/hyperion && start"
ttab "cd ~/src/iris-core"
ttab "cd ~/src/iris-core && start"