-
-
Save binarymatt/1326816 to your computer and use it in GitHub Desktop.
A stab at running remote Django management commands via fabric.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def manage(management_command, args=[]): | |
with cd(REMOTE_PROJECT_DIR): | |
with prefix('source /path/to/virtualenv/bin/activate'): | |
run('python manage.py %s %s' % (management_command, ' '.join(args)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment