• I’m REALLY interested in this whole “clean SVN checkout” feature touted in the 2.6 release notes, but I can’t seem to find information about it anywhere. Am I crazy? Just missing something? Anyone know?

Viewing 10 replies - 1 through 10 (of 10 total)
  • Moderator Jan Dembowski

    (@jdembowski)

    Forum Moderator and Brute Squad

    I didn’t try the WordPress search on this page, but looking this up on Google was worthwhile.

    A clean install instructions can be found at this codex link here.

    Thread Starter grid

    (@grid)

    Hmmm. perhaps I was not clear enough. I don’t need instructions on how to install WP via SVN. I want instructions on how to convert an existing SVN checkout of wordpress to a “clean” checkout. Here is the relevant portion of the release notes:

    Ability to move your wp-config file and wp-content directories to a custom location, for “clean” SVN checkouts.

    Anyone know anything about this?

    Thread Starter grid

    (@grid)

    There is no information about this anywhere… it appears that it has something to do with the WP_CONTENT_URL constant. I think it would be sweet to store all my wp-content outside of the svn checkouts. I assume I’m not the only one, since this (apparently) got done in the first place.

    This is what I did:

    1. Move (or check out) the WordPress application files into a subdirectory, and set that as your “WordPress address” (either in the General Settings panel or by setting the WP_SITEURL constant in wp-config.php)
    2. Move wp-config.php, index.php, and .htaccess into the main directory, and edit index.php so it points to the new location:
      /** Loads the WordPress Environment and Template */
      require './wp/wp-blog-header.php';
    3. Put wp-content wherever you want and set WP_CONTENT_DIR (full local path) and WP_CONTENT_URL (full URI) constants in wp-config. When I did this, I also had to empty the “Store uploads in this folder” field in the Miscellaneous Settings panel — the default wp-content/uploads seems to be relative to the application path (ABSPATH), and that’s not what you want.

    You end up with a structure like this (I put the application files in the wp folder):

    /.htaccess
    /index.php
    /wp-config.php
    /wp-content/
    /wp/
    /wp/wp-blog-header.php
    /wp/wp-load.php
    /wp/…

    (If you want, you can also move the plugins and uploads directories: set the WP_PLUGIN_DIR and WP_PLUGIN_URL constants in wp-config.php, and set the local upload path and upload URL in the Miscellaneous Settings panel.)

    If you make updates with Subversion, it looks like the working copy has an extra index.php file and wp-content folder that never get used — ?

    Thread Starter grid

    (@grid)

    Thanks Sam, really appreciate your response.

    I’m sort of surprised the WP_CONTENT_URL and WP_CONTENT_DIR don’t also change the WP_PLUGIN_DIR and WP_PLUGIN_URL constants automatically. They use them in their definitions… does wp-settings.php get included before the wp-config?

    If you define the WP_PLUGIN constants yourself (in wp-config.php), those values get used; otherwise WordPress defines them (based on the WP_CONTENT values) in wp-settings.php.

    So you don’t need to set the WP_PLUGIN constants in wp-config.php unless you’ve moved the plugins directory outside of the content directory.

    Moderator Samuel Wood (Otto)

    (@otto42)

    WordPress.org Admin

    It’s not necessary to move your wp-content directory and wp-config files to use SVN updates. The SVN does not contain a wp-config.php at all, and unless you’re using the default or classic themes, your themes and plugins and such also won’t be in the SVN.

    I take this does not mean we can re-name the directories?

    Check the second half of my presentation from WordCamp UK here for a walk through:

    http://unlettered.files.wordpress.com/2008/08/wp-plus-subversion.pdf

    sam_a

    (@sam_a)

    Codex: Installing WordPress with clean Subversion repositories

    I could never figure out what to do with the index.php file 😉 — anyway, you do move wp-config and wp-content, but (unlike my advice above) you leave index.php where it is and instead edit the mod_rewrite rules to pass requests there.

    I take this does not mean we can re-name the directories?

    Any of the directories WordPress allows you to move you can also rename, as long as you tell WordPress the new location — either in the Admin panels or wp-config, usually.

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘clean SVN checkout’ is closed to new replies.