简体   繁体   English

非版本SVN目录?

[英]Non-versioned SVN directory?

The issue we have is a customer supplies us with content to include in releases, and this includes a lot of video files. 我们遇到的问题是客户向我们提供了要包含在发行版中的内容,其中包括许多视频文件。 Their content generally goes in SVN but since they don't have access to it, versioning these large binary files doesn't really seem to fit SVN well. 它们的内容通常放在SVN中,但是由于他们无法访问它,因此对这些大的二进制文件进行版本管理似乎不太适合SVN。 Our testing doesn't require these files (we just have to test we can launch a video if it's found) and we aren't responsible for checking/testing the customer's supplied content. 我们的测试不需要这些文件(我们只需要测试是否可以启动发现的视频),我们就不负责检查/测试客户提供的内容。

So I wondered if it's possible to have a SVN dir which isn't versioned, and is just a regular directory which can still be pulled when updating/checking-out? 所以我想知道是否有可能没有版本的SVN目录,而仅仅是一个常规目录,在更新/签出时仍可以将其拉出? Or maybe SVN has a way to pull files from a non-SVN source, somewhat like svn:externals but not looking at another repo? 也许SVN可以从非SVN来源中提取文件,有点像svn:externals,但不查看其他存储库?

Is there a SVN solution to this, or if we want to avoid versioning the files should we simply put them in another store and configure a build/deploy script to pull them separately? 是否有SVN解决方案,或者如果我们想避免对文件进行版本控制,是否应该将它们简单地放在另一个存储中并配置构建/部署脚本以分别拉出它们?

Alas no, subversion stores all versions committed to it - there's no flag to set to tell it to keep just the last version. no,不行,Subversion存储了所有提交给它的版本-没有设置标记来告诉它仅保留最后一个版本。 Maybe one day after obliterate is implemented, but don't hold your breath waiting for that :) 也许在抹除后的一天,但不要屏住呼吸等待:)

Basically, there isn't a SVN solution to this - so you need to look at a document-management server, or just a separate file store. 基本上,没有针对此的SVN解决方案-因此,您需要查看文档管理服务器,或者只是一个单独的文件存储。

There is one option that might work for you though, if you use TortoiseSvn, you can use its client-side hooks to automatically pull the video files from the file store to the local system. 但是,有一个选项可能对您有用,如果您使用TortoiseSvn,则可以使用其客户端挂钩自动将视频文件从文件存储拉到本地系统。

The alternative for an all-subversion solution is to store your video files in it as normal, but then regularly dump/filter/load the repository to clean out the old versions. 全颠覆解决方案的替代方法是将视频文件照常存储在其中,然后定期转储/过滤/加载存储库以清除旧版本。 this can take some time if the video files are very large so I'm not sure if I recommend it, but if you stored them in their own repo, you could simply get the latest version, delete the entire repo, and re-import the file you just got to re-initialise the repo with 1 version. 如果视频文件很大,可能要花一些时间,所以我不确定是否建议这样做,但是如果将它们存储在自己的存储库中,则只需获取最新版本,删除整个存储库,然后重新导入您刚要使用1个版本重新初始化存储库的文件。 Saves space, and could be scripted, but probably isn't worth the hassle comapred to just telling everyone "get your video files off "\\server\\videos". 节省空间并且可以编写脚本,但是仅仅告诉每个人“从“ \\ server \\ videos”中删除视频文件”这一麻烦可能并不值得。

Is the problem the bridge between your client and the SVN repo, or the versioning of binary files ? 问题是您的客户端和SVN存储库之间的桥梁,还是二进制文件的版本控制?

For the second one, I think there's no big deal. 对于第二个,我认为没有什么大不了的。 Read from here : http://help.collab.net/index.jsp?topic=/faq/svnbinary.html 从这里阅读: http : //help.collab.net/index.jsp?topic=/faq/svnbinary.html

Note that whether or not a file is binary does not affect the amount of repository space used to store changes to that file, nor does it affect the amount of traffic between client and server. 请注意,文件是否为二进制文件不会影响用于存储对该文件的更改的存储库空间量,也不会影响客户端和服务器之间的通信量。 For storage and transmission purposes, Subversion uses a diffing method that works equally well on binary and text files; 为了存储和传输,Subversion使用了一种差异化方法,该方法在二进制文件和文本文件中同样有效; this is completely unrelated to the diffing method used by the svn diff command. 这与svn diff命令使用的差异方法完全无关。

Since versioning of big files can be rude for developers when updating/committing small changes, you can use a dedicated series of branches. 由于开发人员在更新/提交小更改时对大文件进行版本控制可能是不礼貌的,因此您可以使用一系列专门的分支。

I don't know if I got you right but as far as I've understood it you are after isolation between your code and your customer's huge binary files. 我不知道我是否正确,但据我所知,您是在将代码与客户的巨大二进制文件隔离之后。

What about this, Set up a separate dedicated SVN repository for your large files. 那么,为您的大文件设置一个单独的专用SVN存储库。 Grant the customer access only to that repository. 仅向客户授予对该存储库的访问权限。 Use the svn:externals to pull these files into your code tree. 使用svn:externals将这些文件拉入代码树。

SVN do handle large binary files pretty well and if you put them in a separate repo they won't pollute your code repo. SVN确实可以很好地处理大型二进制文件,如果将它们放在单独的存储库中,它们将不会污染代码存储库。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何签出SVN存储库,覆盖非版本化的本地目录? - How do I checkout an SVN repository, overwiting a non-versioned local directory? svn update覆盖现有的非版本化文件 - svn update over-write existing non-versioned files 想要在Visual SVN上的存储库中上载非版本文件/文件夹 - Want to upload the non-versioned files/folders in a Repository on Visual SVN SVN外部文件夹和文件显示为“非版本化” - SVN External Folders and Files show up as 'non-versioned' 用非版本化文件替换版本化文件 - Replace versioned file with non-versioned file 从SVN远程仓库中删除目录/文件,而不会导致删除本地非版本副本 - Delete dir/files from SVN remote repo without causing local non-versioned copy to be deleted SVN外部未在TortoiseSVN的存储库浏览器中正确显示,并且在本地标记为非版本 - SVN externals not properly displayed in TortoiseSVN's Repository Browser and locally marked as non-versioned 使用SVN,如何将标记/路径与非版本文件进行比较? - Using SVN, how can I compare a tag/path against non-versioned files? SVN提交以前导入的非版本文件的新/更新修订版 - SVN commit new/updated revision of previously imported, non-versioned files 从工作副本分支并包括非版本文件 - Branch from working copy and include non-versioned files
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM