Looking for a guide to upload your new WordPress plugin to an SVN using a Mac? All you may need is to follow this guide to successfully commit your plugin’s files.
Committing files to an SVN using Terminal
To commit your plugin’s files to the WordPress repository, you need to open Terminal on your Mac and follow the steps below:
- Once opening the Terminal application, you need to change directory into somewhere more relevant. Type cd ~/Documents to navigate to your Mac’s documents folder.
- In this folder, type mkdir wordpress-svn-files to generate a directory to hold your SVN files.
- Navigate into this folder by typing cd wordpress-svn-files
- Connect to the SVN by typing svn co https://plugins.svn.wordpress.org/plugin-slug-by-wordpress and this will download the current contents from the repository.
- Copy and paste your plugin’s files into the folders accordingly.
- Type cd plugin-slug-provided-by-wordpress so that you are inside the directory.
- Type ls to confirm you see the four folders (assets, branches, tags and trunk).
- Type svn add * ‐‐force to determine the files you wish to commit (this command should grab all files under the current directory).
- Type svn commit -m Committing to commit the files.
- If it’s your first time committing files into an SVN, you’ll have to supply your computer’s password (if set) and also your WordPress username and password (case-sensitive) after this.
- If successful, you should receive an automated email from WordPress to confirm the transfer of files.
Note, if you’re getting the error: xcrun: error invalid active developer path when trying to connect to the SVN, you may just need to install Xcode by typing xcode-select ‐‐install.