In order to have an efficient way of deploying Magento extensions to (remote) Magento setups I’ve created a simple deployment script based on modman and rsync.
How it works
This script copies your Magento extension to the .modman directory of your destination Magento project and deploys it there using modman. In addition, it exludes files and folders (such as .git) so that only relevant files are copied. This script uses rsync to copy files to your (remote) Magento project.
For example:
- Let’s say you develop a Magento extension in /home/my_user/workspace/MyExtension
- Your development Magento setup is located at /var/www/magento-dev1/
- This script copies your Magento extension from /home/my_user/workspace/MyExtension to /var/www/magento-dev1/.modman/ and automatically deploys it using modman.
Benefits
Although you could do the copying alone using the modman configuration file modman does not offer the possibility to exclude certain files for the deployment process. In addition, this script uses rsync, thus giving you the possibility to remotely deploy your Magento extension.
Download script
Feel free to grab the script from Github. Also, in case you have suggestions for improvements don’t hesitate to drop a comment below.