A shell script that will automate the creation of a custom installation of a Wordpress setup with a Foudnationpress theme. Connects to local database, install plugins, and the Foundationpress Theme. Additionally, the script adds a python script that will automate page and template creation within a theme via the command line.
I needed to decrease the time and steps involved in a tedious setup for wordpress builds.
- WP CLI - command-line interface for WordPress
- WGET - used to retrieve file via HTTP
- Python - for the python script
- python-wordpress-xmlrpc - template page creation
- Clone the repository
git clone [email protected]:smithsa/wpinstall.git
- In your terminal navigate to the directory where the file "wpinstall.sh" lives. Simply run the command below and follow the proceeding prompts.
. wpinstall.sh
- Run the following command in the FoundationPress theme to start compiling ''' npm start '''
Once the build is complete, you will have access to automate the creation of template php files in the Foundationpress theme as well as pages in wordpress connected to the template just created, image folders for the template, and sass files (ready to be compiled) for the template.
** Python Script Commands ** To use these commands navigate to the theme level.
Create a template php file in the foundationpress theme, image folder, and sass file ready to be compiled
python create_template.py create [insert template name here]
Remove the template php file in the foundationpress theme, image folder, and sass file ready to be compiled
python create_template.py remove [insert template name here]
- Fork it!
- Create your feature branch:
git checkout -b my-new-feature
- Commit your changes:
git commit -am 'Add some feature'
- Push to the branch:
git push origin my-new-feature
- Submit a pull request :D
This project is licensed under the MIT License - see the LICENSE file for details.
MIT © Sade Smith