Installation
$ [sudo] pip install execdir
$ [sudo] npm i -g execdir
How it works
- create list of directories
- run command
Config
$XDG_CONFIG_HOME/execdir
by default - ~/.config/execdir
$ export EXECDIR=~/Library/execdir
Examples
set directories
# ~/git/owner/repo
$ find ~/git -type d -maxdepth 2 | execdir set all
$ find ~/git -name "setup.py" -maxdepth 3 | sed 's#/[^/]*$##' | execdir set pypi
$ find ~/git -name "package.json" -maxdepth 3 | sed 's#/[^/]*$##' | execdir set npmjs
$ find ~/git -name ".travis.yml" -maxdepth 3 | sed 's#/[^/]*$##' | execdir set travis
run command
$ execdir run pypi python setup.py sdist upload
$ execdir run npmjs npm publish