• Ive been reading about how great this upgrading wordpress via svn is, but HOW exactly do I do it?
    Ive got as far as installing subversion and a client on my Mac. Even connectiong to the wordpress svn and listing the files (even though the WP svn page is less than clear about wtf you do to get this far ?? ).
    Now what do I do? I managed to download the files to my Mac, but I cant get it to diff (I think thats the term) the files so that I dont have to manually replace files. Moreover, how do I then get it to upload to my webserver?

    yours, an svn n00b

Viewing 15 replies - 16 through 30 (of 31 total)
  • I was just trying to add more feathers to my WP bow.
    It’s always good to learn and I hope I haven’t put you off. Just be sure to try things out in a safe environment first:-)

    Thread Starter somefool

    (@somefool)

    No apologies needed, I know how the many good support people here get pissed off with others complaining and I dont expect a walkthrough just because I ask for it.

    I still dont think its unreasonable though, when someone as high up the WP echelons (possibly the top) mentions SVN and the ease of upgrading WP twice in quick succession on his site to hope for detailed examples of SVN in relation to WP and how it would work with upgrading.

    Atleast SOME sort of mention on the codex and more than the pitiful page on the WP downloads area, which unless you have experience of SVN is really no more than “you can use svn, heres some commands” would not seem too much.

    Again, Im grateful for the support there is, I try and help myself when I can, but can those more experienced in certain (possibly more obscure) areas please think about suitable explanations when they are posting what could be truly helpful items.

    … phew, and relax.

    Thread Starter somefool

    (@somefool)

    “It’s always good to learn and I hope I haven’t put you off. Just be sure to try things out in a safe environment first:-)”

    I would, but Im still not sure how to actually proceed and try something. Ive got svn downloading the latest WP through a GUI app to my local drive, but I dont know how I get it to ‘diff’ files or indeed then do this remotely on my server.

    I’m a bit busy with the day job at the moment but if there are no responses, I’ll try to write a quick writeup later this week with step by step instructions.

    Basically though, the process is:
    Telnet or SSH to your remote server
    Navigate to where you want to check out
    svn co https://svn.automattic.com/wordpress/trunk/

    Now in future, if you want to update, do a:
    svn update

    Be aware that SVN does need to be installed on the remote server.

    You don’t need to diff anything, just update, which won’t mess with files you’ve changed. One thing: to be doing it remotely on your server they have to be SVN repositories to start with; you almost absolutely will need access to the shell or other ways of passing commands to it.

    Thread Starter somefool

    (@somefool)

    OK, thanks. Looks like I cant do it then as I cant ssh to my server, I havent tried telneting but I guess I wont be able to do that either.

    Thanks again anyway, Im sure others would find a write up useful though.

    somefool,

    Actually, with a bit of PHP trickery, you could do this withouth SSH access. The real issue is if SVN is installed on your host or not.

    Generall, using system() or exec() you can run code as if you were in SSH via a php script. Example:

    <?php
    echo exec('svn help');
    ?>

    In fact, you might upload a simple php script just like that and see if it works.

    Won’t work if the host disallows use of system() or exec() – mine doesn’t let one do so….

    Thread Starter somefool

    (@somefool)

    chuyskywalker – I put that up as a php file on my server and it didnt output anything, no errors or anything, so I assume it wont work for me?

    Thanks though.

    You may just be stuck then. Write your host? Maybe they’ll be cool and install it for you and give you SSH access.

    I’m with ASO — and they did just that at customer request. Quick too, like, < 12 hour turnaround. Pretty awesome.

    /* Script has shell access */
    $shell_exists = shell_exec('ls');

    if(empty($shell_exists)) {
    echo "<p>Sorry, can't use shell_exec()</p>"; die();
    } else {
    echo "Can use shell_exec(), proceeding!";
    }

    /* The SVN binary is available */
    $svn_exists = shell_exec('which svn');

    if(empty($svn_exists)) {
    echo "<p>Sorry, no SVN</p>"; die();
    } else {
    echo "<p>SVN available!</p>";
    }

    Er… enclose that with <?php at the start and ?> at the end, save to a file with a .php extension, and run it to see what’s up.

    Thread Starter somefool

    (@somefool)

    “Can use shell_exec(), proceeding!
    Sorry, no SVN”

    Ahhh, oh well.

    I might contact my host, Ill have to have a think, cheers again all.

    You can use svn on your local machine and rsync the content to your host. Most hosts support rsync over ssh these days.

    * svn co https://svn.automattic.com/wordpress/trunk/ wp
    * cd wp
    * Setup wp-config.php. Make customizations.
    * svn update #Pull down and merge upstream changes
    * rsync -avz -C --exclude='*.svn' -e ssh ./ [email protected]:/path/to/public_html/wordpress/ # Push the changes to your host.

    Wrote this up yesterday.
    How to use SVN to upgrade WordPress

Viewing 15 replies - 16 through 30 (of 31 total)
  • The topic ‘svn wordpress = how?’ is closed to new replies.