svn

git使用中的一些命令及心得

风流意气都作罢 提交于 2019-12-21 01:25:04
Git 与 SVN 区别点: 1、Git 是分布式的,SVN 不是:这是 Git 和其它非分布式的版本控制系统,例如 SVN,CVS 等,最核心 的区别。 2、Git 把内容按元数据方式存储,而 SVN 是按文件:所有的资源控制系统都是把文件的元信息隐藏在一个 类似 .svn、.cvs 等的文件夹里。 3、Git 分支和 SVN 的分支不同:分支在 SVN 中一点都不特别,其实它就是版本库中的另外一个目录。 4、Git 没有一个全局的版本号,而 SVN 有:目前为止这是跟 SVN 相比 Git 缺少的最大的一个特征。 5、Git 的内容完整性要优于 SVN:Git 的内容存储使用的是 SHA-1 哈希算法。这能确保代码内容的完整 性,确保在遇到磁盘故障和网络问题时降低对版本库的破坏。 命令: 0.切换磁盘,从C盘切换到E盘: cd E: ; 与cmd不同,cmd为: E: ; 1.创建一个名为test的目录 : mkdir test 2.初始化一个 Git 仓库,即把这个目录变成Git可以管理的仓库: git init 3.Git 配置 : git config + 其他相关命令(参考:https://www.runoob.com/git/git-install- setup.html 或 https://www.liaoxuefeng.com/wiki

How to export changed files between two SVN revisions

和自甴很熟 提交于 2019-12-21 01:23:09
问题 How can I export changed files in SVN that have changed between two revisions. I need a solution either via command line or by using any scripts (with proper folder structure). In addition, I need windows based solution. e.g. sth like: export {svn diff --summarize -r 50:HEAD} I want a directory tree with a copy of the files that where changed in any revision from 50 on 回答1: As far as I know, svn does not provide such a feature. But you may write a simple c# program using SharpSVN to do it.

Xcode7 failed to check modified files for svn

感情迁移 提交于 2019-12-21 01:21:21
问题 Yesterday I checked out certain version of remote respository and made some change. And now I have two 'branches' in local respository, one is master, another is certain version. However, when I try to check commit history of svn in Xcode today, I find it fails to show modified files and an alert, saying The source control operation failed because no working copy could be found. Make sure the file is in a valid working copy and try again. It's really annoying to unable to check any detail

GIT和SVN之间的五个基本区别

眉间皱痕 提交于 2019-12-21 00:00:05
如果你在读这篇文章,说明你跟大多数开发者一样对GIT感兴趣,如果你还没有机会来试一试GIT,我想现在你就要了解它了。 GIT不仅仅是个版本控制系统,它也是个内容管理系统(CMS),工作管理系统等。如果你是一个具有使用SVN背景的人,你需要做一定的思想转换,来适应GIT提供的一些概念和特征。所以,这篇文章的主要目的就是通过介绍GIT能做什么、它和SVN在深层次上究竟有什么不同来帮助你认识它。 那好,这就开始吧… GIT是分布式的,SVN不是: 这是GIT和其它非分布式的版本控制系统,例如SVN,CVS等,最核心的区别。 如果你能理解这个概念,那么你就已经上手一半了。需要做一点声明,GIT并不是目前第一个或唯一的分布式版本控制系统。还有一些系统,例如Bitkeeper, Mercurial等,也是运行在分布式模式上的。但GIT在这方面做的更好,而且有更多强大的功能特征。 GIT跟SVN一样有自己的集中式版本库或服务器。但,GIT更倾向于被使用于分布式模式,也就是每个开发人员从中心版本库/服务器上chect out代码后会在自己的机器上克隆一个自己的版本库。可以这样说,如果你被困在一个不能连接网络的地方时,就像在飞机上,地下室,电梯里等,你仍然能够提交文件,查看历史版本记录,创建项目分支,等。对一些人来说,这好像没多大用处,但当你突然遇到没有网络的环境时,这个将解决你的大麻烦。 同样

Migrate a Source Safe database to SubVersion with history

久未见 提交于 2019-12-20 23:27:22
问题 Folks, We have a number of Source Safe databases that should be migrated to SubVersion. Is there a (tested and proven) way to migrate them with history ? Thanks Essam 回答1: You can try VssMigrate. It is a C# port of PowerAdmin's VssMigrate which has the capability to "Resolve the individual VSS-checkins to atomic SVN commits via the approximate timestamp". 回答2: I'm considering the migration too and I have found some pages that may help you in the process: Moving from Visual SourceSafe to

Using git-svn to merge a svn branch back into trunk and trunk back into the branch

微笑、不失礼 提交于 2019-12-20 20:31:34
问题 So I'm using git and interacting with an svn repo. I have a svn TRUNK that looks like this: A-B-C-D And a svn bug_fixes branch that branches off at commit B or C: -c-d-e-f-g-h-i Now I need to get the cdefghi commits that are in my svn branch back into the master branch. I'm aware that I could just do a squashed commit, let's call it squash SQUASH (which would contain cdefghi), but then it seems like I would have to kill the bug_fixes branch and start a new branch to cleanly continue. Here:

Using git-svn to merge a svn branch back into trunk and trunk back into the branch

这一生的挚爱 提交于 2019-12-20 20:31:03
问题 So I'm using git and interacting with an svn repo. I have a svn TRUNK that looks like this: A-B-C-D And a svn bug_fixes branch that branches off at commit B or C: -c-d-e-f-g-h-i Now I need to get the cdefghi commits that are in my svn branch back into the master branch. I'm aware that I could just do a squashed commit, let's call it squash SQUASH (which would contain cdefghi), but then it seems like I would have to kill the bug_fixes branch and start a new branch to cleanly continue. Here:

svn: E175002: Unable to connect to a repository at URL

怎甘沉沦 提交于 2019-12-20 19:47:39
问题 I'm trying to svn checkout this library https://code.google.com/p/google-api-objectivec-client/source/checkout but my svn doesn't connect from a particular macbook, same internet connection but different macbook it is able to checkout successfully I get: svn: E175002: Unable to connect to a repository at URL 'http://google-api-objectivec-client.googlecode.com/svn' svn: E175002: OPTIONS of 'http://google-api-objectivec-client.googlecode.com/svn': Could not read status line: connection was

Nested svn repositories

别说谁变了你拦得住时间么 提交于 2019-12-20 18:34:50
问题 I got a "Project A" in repository. But in that project I'm using a library, which is hosted on Google Code. There is my question: is there any way, to have that library files "hooked" to Google Code SVN, and simultaneously my project in my repo (it's parent to that library), so I can commit library files into my repository when I decide, that outer project revision is ok? I've tried to do checkout in the library folder, files were downloaded from Google's Code repository. But I that case wasn

Get Last file Commit Date from SVN

左心房为你撑大大i 提交于 2019-12-20 18:33:51
问题 Noob to Subversion, so please bear with me. Is there a way to get the last commit date for a file from the command line? 回答1: svn info filename 回答2: svn log -vl1 filename-or-url will give you the commit log for the last change that altered your file. 回答3: Use this to export only the last changed date. svn info filename | grep '^Last Changed Date:'| sed -e 's/^Last Changed Date: //' 来源: https://stackoverflow.com/questions/1798040/get-last-file-commit-date-from-svn