Jump to content

Updating PW using git merge?


Oliver
 Share

Recommended Posts

I store each of my PW projects in separate repos. When it comes to updating the version of PW used for a project, I'm sure there has to be an easy way to merge the master or dev branch of the PW repo into am update branch of the current project's repo. I already added the PW repo as remote source. But as I'm far from being a git pro, I haven't found the right way to do an update appropriately without getting everything messed up. It would be great if one or two of you guys would sketch their approach to updating a PW installation using git and github in a few words.

  • Like 1
Link to comment
Share on other sites

Most of the web servers I use don't actually have git, so I'm usually just doing this:

mv wire wire.old
mv wire.new wire

When a server does have Git, I'll usually keep the repository somewhere outside of the webroot. Then I'll basically do the above, replacing the wire directory with the new one, after a git pull. But my repository will live in a 'src' directory off of my [non web accessible] home directory. I keep it non web-accessible so that there isn't an extra uninstalled copy of PW lying around the server (which wouldn't be safe).

Perhaps there's a better way to go about this, but since most upgrades only involve replacing the /wire/ directory, I don't usually find it necessary to have the live core files themselves version controlled. Sometimes the /index.php and /.htaccess file will also need to be replaced, but that's fairly rare.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Similar Content

    • By dragan
      A neat new Github feature: 
      https://help.github.com/en/articles/navigating-code-on-github
      And while I'm at it: If you're frequently navigating through GH repos, I can highly recommend this browser add-on: https://www.octotree.io/
    • By Macaco
      Hi there, 
      I have two templates that should talk to each other. One is for events which should access a list of artists (eventually add a new artist) and their images related to that event; the second is the artist page, which the user should be able to add or remove events that they participated, also mentioning which images are related to each event.
      Some sort of feedback loop between the two.
      I have tried searching around the community and google, but maybe I'm not formulating the question properly. 
      Thank you all for the amazing work with Processwire and the community support. I have made a few websites with PCW yet I'm still quite between beginner and intermediate.
    • By louisstephens
      So I have been diving into hooks lately, and I am enjoying them thus far. However, I guess I am a bit stumped on how to achieve what I want too. I am trying to set up a hook that would create a new child page when the parent page is saved. However, when you save the parent page a second time, I just need to update the child page without creating multiple child pages. What would be the best way to go about this?
      So after rereading my post, I believe it is a bit vague so I will try to explain more. 
      The Goal:
      Create a page with a template "one". Once the page is created/saved => create a new child page with the template of "two" If the parent is saved anytime after, do nothing to the child page (limit the parent page to one child page) The parent page is really just being used to output content, whereas the child page is being used to pull out the some fields from the parent to be used elsewhere. I might have made this too complicated in my head.
    • By jsantari
      I have a site that I want to update from 2.6.1 to the latest 2.8. Do I need to go to 2.7 first then 2.8?
    • By BFD Calendar
      I'm still wrestling with the upgrade troubles on OVH.com hosting. I manually upgraded to PW 3.0.98 and Upgrade module 0.0.7. Checking upgrades gives me an "Error loading GitHub branches - https://api.github.com/repos/processwire/processwire/branches - HTTP error(s): 2: fsockopen(): SSL operation failed with code 1. OpenSSL Error messages: error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version, 2: fsockopen(): Failed to enable crypto, 2: fsockopen(): unable to connect to ssl://api.github.com:443 (Unknown error) - Check that HTTP requests are not blocked by your server.".
      Upgrading or installing other modules doesn't work either. I know it probably has to do with some provider setting on OVH.com, but I've tried several things mentioned in the ProcessWireUpgrade support forum, all to no avail. Server is configured to use PHP 7.0. If anyone here is also on OVH.com and knows a solution I'd be most happy to hear about it.
×
×
  • Create New...