command line app for running configurable shell commands
Project description
plz-cmd
A shell command to execute standard/repeatable commands in a git repo
Installation
Install plz at the system level so that it only has to be installed once.
pip install plz-cmd
# sudo may be required on your machine
sudo pip install plz-cmd
It can also be installed inside a virtualenv. However, this means you'll have to install plz-cmd for each each virtualenv in use.
virtualenv venv
. venv/bin/activate
pip install plz-cmd
Example
plz looks for a .plz.yaml
file either in the current directory or in the root
of the git repo you're currently in. This file can (and should) be checked into
version control.
For a .plz.yaml file located in the git root directory, commands run will be executed relative to that directory, not the current directory.
Suppose we have the following .plz.yaml
file:
- id: run
name: runserver
cmd: ./manage.py runserver
- id: test
name: test code
cmd:
- ./manage.py test
- yarn test
- id: setup
name: setup apps
cmd:
- pipenv install
- pipenv run ./manage.py migrate
- yarn install
The following commands would be available:
plz run
plz test
plz setup
Globbing
plz supports asterisk expansion. For example, the cmd ls *.py
will work as expected.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.