Github Actions To Release WordPress Plugin

Github is the place where we spend a good amount of time exploring some amazing opensource projects, contributing or pushing our own code. Development at GitHub is on fire post Microsoft acquisition.

Lately, we have seen many new features and improvements being rolled out to the platform. Of all the new goodies “Actions” are coming to platform which is currently in beta.

Actions are fun little bots that help you automate all the boring repetitive task. Currently we have various other ways to do that. But having something integrated within the platform would be fun.

With action possiblities are endless as you can use pre made action by Github or community. Also, you can create your own actions if you are familar with DOCKER and shell scripting.

We were excited about actions and once we got the beta access we started exploring it for our needs. We have created two actions which are our mini-bots to automate our WordPress plugin release publish.

Plugin release work flow includes creating distrrubution archive and then releasing / pushing same to the wordpress.org

Archive Action

Action to create a distribution zip archive excluding all development and build related files/folder. We use this archive with WordPress action to publish it to the WordPress plugin repository.

WordPress Action

Action to publish plugin release to wordpress.org repository. Simply tag the release on GitHub to trigger publish. Action checkout plugin from wordpress.org SVN, update trunk with release archive and create a tag folder based on GitHub release tag. Action copies files from “.wordpress-org” folder to “assets” folder. Commits the changes and push to SVN.

More actions will be added to our github workflow stay tuned 🙂

Want to make your fun little action you can have look at how we have built . All actions are opensource and available on GitHub.

https://github.com/lubusIN/actions

https://github.com/lubusIN/actions/tree/master/archive

https://github.com/lubusIN/actions/tree/master/wordpress