[wp-hackers] GitHub submodule theme development?

Micky Hulse mickyhulse.lists at gmail.com
Mon Jul 8 19:33:23 UTC 2013

Hi Harry! Thanks again for the help, it's much appreciated. :)

It's great hearing about your workflow too, so thanks for that as well.

On Mon, Jul 8, 2013 at 11:58 AM, Harry Metcalfe <harry at dxw.com> wrote:
>> How to do you test/develop those submodules (or, are they other
>> people's code that you're just linking to ... i.e you don't modify
>> directly)?
> Yup, the latter. As soon as we need to modify something, it goes into a
> separate repo just for the project. As a rule, if we're going to apply
> upstream updates, we use a submodule. For repos which contain local
> modifications it allows us to easily make sure we don't overwrite one of our
> changes, and to resolve any conflicts. For ones that don't, we have a script
> that downloads the newer plugin version, unzips it, commits it, and tags it
> with the version. This makes updating it everywhere really easy, because we
> can just update the submodule to the new tag for each site, commit
> wp-content, and push to the production branch which auto-deploys.

That sounds like an awesome workflow/setup! Thank you for giving
me/the list more details.

My personal WP workflow will probably never get to that high of a
level (honestly, some of it sounds more complex than my brain could
handle). :D

>> If you have the time to go into some details, I'm really curious to
>> hear more about how you develop themes locally and then push/pull
>> to/from remote/local.
> Well, the theme usually just lives in the wp-content repo. Sometimes we'll
> have one of the default themes as a submodule, if it's a parent theme.
> I'm not sure what more there is to add here -- did you have something
> specific in mind? Other than the production branch which we use for deploys,
> it's all fairly normal.

No, that's great! I think I get it now. Thank you for the additional details!

>> That makes sense. Do you have any publicly viewable repos that have
>> this type of setup? Just curious (I think I follow your setup, but I'd
>> love to have a visual too). :-}
> I'm afraid I don't think we do. We have a theme available:
>   https://github.com/dxw/govuk-blogs/

Awesome, thanks! Checking it out now. :)

Thanks for sharing!

> Which shows how grunt is set up, and how we submodule roots and bootstrap
> into themes. That repo is then a submodule in a wp-content repo which also
> has a few plugins submoduled. The site is here:
> http://blog.gov.uk

Oooh, nice! Impressive work! I'm looking forward to
installing/dissecting your theme. :)

Thanks again Harry!!!! Much appreciated.

Have an awesome day.


More information about the wp-hackers mailing list