使用“export"从SVN释放然后?如何升级? [英] release from SVN using "export" and then? how to upgrade?

查看:58
本文介绍了使用“export"从SVN释放然后?如何升级?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

使用 SVN,我正在考虑使用 SVN 导出命令将第一个版本(1.0 版)发布到生产服务器.

Using SVN, I was thinking about releasing the first build (ver 1.0) to production server using SVN export command.

升级的下一步是什么?例如,如果我想发布将是 1.1 的下一个版本,应该怎么做?不删除所有文件,有没有办法只从标签升级?

What's the next step for upgrading? For example, if i want to release the next build which will be 1.1, how should this be done? Without deleting all files, is there a way to just upgrade from the tag?

推荐答案

一般发布步骤:

  1. 创建标签主/测试分支.这是发布的代码.并且不能在没有分支的情况下进行修改.这是 1.0 版.您在生产服务器上构建和部署此代码.

  1. Create a Tag from the main/tested branch. This is released code. And can't be modified without branching. This is version 1.0. You build and deploy this code on production server.

在主分支(主干)中继续编码 1.1 版.在 v1.1 结束时,您将创建另一个标签,该标签将发布版本 1.1.等等.

Continue coding for version 1.1 in the main branch (trunk). At the end of v1.1, you will create another tag which will be release version 1.1. And so on.

理想情况下,每个版本保留一个标签.如果有修复的地方必须转到以前发布的版本,您 (1)从该标签创建一个分支(比如 1.0),(2)修复分支中的问题,(3)从这个分支创建另一个标签作为发布版本 1.0.1

Ideally, you keep one tag per release. If there are spot fixed that has to go to a previously released version, you (1)create a branch from that tag (say 1.0), (2)Fix the issue in the branch, (3) create another tag from this branch as release version 1.0.1

请注意,整个过程不会删除任何文件.您只是在创建新的分支,这些分支是廉价副本 你的代码库.

Please note, that no files are deleted in the whole process. You are just creating new branches, which are cheap-copies of your code-base.

更新

但是我怎样才能在生产中升级到标签 1.1?SVN导出会不会覆盖现有文件,删除标签1.1中删除的文件?这是我关心的问题.

But then how can i upgrade to tag 1.1 in production? Will SVN export overwrite existing files and delete files that are deleted in tag 1.1? This is my concern.

两件事

  1. 导出不会从任何地方删除任何文件.它下载您作为参数提供给它的 URL 的干净副本(没有 .svn 和其他 SVN 特定内容).请参阅此处svn export

  1. Export does not delete any files from anywhere. It downloads a clean copy (without .svn and other SVN specific stuffs) of the URL that you have provided to it as an argument. See here svn export

创建分支或标记您时应该复制.而不是先导出再导入.最常见的发布流程如下图所示:(对不起画风)

When creating a branch or tag you should copy. And NOT export followed by import. The most common release flow looks like the diagram below: (sorry for the pathetic art)

随时间变化的 SVN 存储库状态

                                                        /---> Tag 1.0.1(release to prod)
                    /--- Branch 1.0.1 for spot-fixes----|
                   /                                    |
             /---Tag 1.0 (released to prod)             v (merge fixes)    /---Tag 1.1 (released to prod)
 Trunk ----->'------Development for v1.1----------------'----------------->'----Development for v1.2-->  

您会看到没有任何内容被删除,并且每个版本都有标签.

You see nothing is ever deleted and you have tags for each releases.

这篇关于使用“export"从SVN释放然后?如何升级?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆