I found out that the easiest way to build a WordPress plugin is using a rake task. In fact, you can use Rake::PackageTask to create a zip file. However, there is very little documentation about how to do it in practice. Here is my solution.
- (destroy and) create a folder to hold just the needed files
- copy the (possibly transformed) needed files to that folder
- compress the folder
Here is my Rakefile:
Here are the tasks it creates:
Here is how you can use it:
Here is what you get:
