$ tmux
CTRL+B C -> create new pane
CTRL+B [num] -> go to a pane
CTRL+D -> finish bash session, closes the pane. Closing all panes will destroy the window and thus the tmux
| ALIAS=@foo | |
| MIGRATION=foo_news | |
| LOG_FILE=/tmp/foo-migrate-logs/migration-foo_news.log | |
| rm -f $LOG_FILE | |
| date > $LOG_FILE | |
| # Run migrations in chunks of 3000 items. | |
| THRESHOLD=3000 | |
| TOTAL=$(COLUMNS=160 drush $ALIAS migrate-status $MIGRATION | tail -n 1 | awk '{print $3}') |
| #!/bin/bash | |
| # Place this file in /usr/local/bin/composer and chmod +x | |
| docker run --rm \ | |
| -u `id -u`:`id -g` \ | |
| --volume "${PWD}":/app \ | |
| --volume "${COMPOSER_HOME:-$HOME/.composer}":/tmp \ | |
| --volume "$SSH_AUTH_SOCK":/ssh-agent --env SSH_AUTH_SOCK=/ssh-agent \ | |
| --volume /etc/ssh/ssh_known_hosts:/etc/ssh/ssh_known_hosts \ |