maintaining configuration differences between dev and live environments during deployment from SVN

后端 未结 4 722
陌清茗
陌清茗 2021-02-10 13:41

We use the ExpressionEngine CMS (php) to create websites. For each site, we set up a subversion repository and commit the EE installation as well as any custom templates, images

4条回答
  •  孤城傲影
    2021-02-10 14:39

    Another alternative is to branch the configuration files once, into a release branch, and then mark them as edited on the destination, and then use a merge script that remember how to do a three-way merge. If the configuration changes on the source, then it will likely generate a conflict, which is a good thing, because you probably need to do similar changes on the destination.

    Thus, you keep two trees going for the lifetime of the project: development, and release. As things mature in development, you integrate them over to release. You can have a third, QA, tree as well, if you have a more involved release process.

    When you pull a new release, you copy from the working area to the "release" area (as a merge/integration), rather than pull a brand new branch. If you also want a snapshot-in-time of the release tree at that point, then make a separate branch/copy/tag that you use only for archival purposes.

    Btw: this is one of the areas where Perforce shines -- it remembers what you already merged, and won't ever attempt to merge twice.

提交回复
热议问题