Skip to content


Subversion checkout URL

You can clone with
Download ZIP


Fixing whippet deploy #25

tomdxw opened this Issue · 5 comments

2 participants


This proposal should fix #1 and #2.

Here's the current logic:

//    1. Clone WP
//    2. Delete wp-content etc
//    3. Make sure wp-content is up to date
//    4. Copy our wp-content, omitting gitfoo
//    5. ?? Theme/plugin build steps ?? (Makefile-esque thing?)
//    6. Symlink required files from shared dir

We should change that to be:

  1. Clone WP
  2. Delete wp-content etc
  3. Make sure wp-content is up to date (merely fetch, checkout the branch, and run "git clean -dxff" to remove all untracked files in the workdir - this will include submodules that have been removed)
  4. Copy the entire workdir, not just the wp-content directory
  5. In the copied workdir: git submodule update --init --recursive
  6. In the copied workdir: Install plugins
  7. (In future, maybe) In the copied workdir: run theme/plugin build steps
  8. In the copied workdir: Remove gitfoo
  9. Move wp-content to the appropriate place, and delete the copied workdir

This will mean that we're starting out with a totally clean workdir, so plugins should not persist and there should be no issue moving between plugins and submodules.

@harry-m Does this sound reasonable?

@tomdxw tomdxw added the bug label
@harry-m harry-m was assigned by tomdxw

Why not do steps 5, 6, & 7 in the workdir, and then copy and remove gitfoo?


@harry-m Because then somebody will have to SSH into the machine and rm -rf the original workdir and run chef-client every time we want to delete a submodule or plugin.


Must be missing something. If we have a repo that is always checked out, from which deploys are generated, why wouldn't we make sure that repo is definitely in the correct state and then generate the deployable site from that? Why is it necessary to do the updates in a copy? Can't we just git clean -dxff in the always-checked-out repo?


@harry-m I obviously wasn't thinking when I said that. Yeah, the clean -dxff command will mean we can do those commands in the main directory.

So with that in mind, maybe all we need to change is to add a single line which runs "git clean -dxff" before pull/submodule update/etc.

@harry-m harry-m removed their assignment
@tomdxw tomdxw was assigned by harry-m

Swish. Let's do it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.