version-control

Versioning with Visual Studio 2010 and HG

被刻印的时光 ゝ 提交于 2020-01-11 03:22:06
问题 Recently me and my team got a HG repository for versioning as this would make it easier and better to develop our application. We are using Visual Studio 2010 and c# All of the project is under version control.. Unfortunately, when one of us commits, usually the other gets an error of some kind when opening the solution (due to the various files VS has) My question is: what files should be put under version control? (and removed in my case!) PS: we have 3 Projects: (using XNA) game, contents,

(Git Merging) When to use 'ours' strategy, 'ours' option and 'theirs' option?

与世无争的帅哥 提交于 2020-01-10 19:18:05
问题 Definition of recursive merge strategy pulled from the git merge documentation. This can only resolve two heads using a 3-way merge algorithm. When there is more than one common ancestor that can be used for 3-way merge, it creates a merged tree of the common ancestors and uses that as the reference tree for the 3-way merge. This has been reported to result in fewer merge conflicts without causing mismerges by tests done on actual merge commits taken from Linux 2.6 kernel development history.

Git - How to close commit editor?

若如初见. 提交于 2020-01-10 06:17:28
问题 I'm new to git and learning from a PDF. I just executed a command $ git commit and it opens a new editor. But I'm trying to close that new commit editor. How to do this? I'm using git on windows. 回答1: Save the file in the editor. If it's Emacs: CTRL X CTRL S to save then CTRL X CTRL C to quit or if it's vi: : w q Press esc first to get out from editing. (in windows/vi) 回答2: Had troubles as well. On Linux I used Ctrl + X (and Y to confirm) and then I was back on the shell ready to pull/push.

How does git track file changes internally?

狂风中的少年 提交于 2020-01-10 03:35:06
问题 Could somebody explain how git knows internally that files X, Y and Z have changed? What is the process behind the scenes that recognizes when a file has not yet been added or has modifications? I am asking because, with Subversion it's simple to figure out that it keeps track of these things by having a .svn directory under each folder, but for git I can't seem to find a description of the inner workings of this. I doubt it scans through all the sub-directories for changes, as it's quite

How can I get the latest commit ID of the currently checked out branch in git, using ANT, without having an active git installation?

邮差的信 提交于 2020-01-10 03:21:06
问题 I've used the following ant details to retrieve the checked out branch's latest commit ID, what caveats should I be concerned about using this method? Are there edge cases where I wouldn't retrieve the expected values? <scriptdef name="substring" language="javascript"> <attribute name="text" /> <attribute name="start" /> <attribute name="end" /> <attribute name="property" /> <![CDATA[ var text = attributes.get("text"); var start = attributes.get("start"); var end = attributes.get("end") ||

What do you use the svn tags directory for anyways?

拟墨画扇 提交于 2020-01-10 02:34:06
问题 Ok so we all know the standard SVN set-up of trunk\ branches\ tags\ And I realize that the recommendation is that tags should have "special" commits in it. I've never really used the tags directory however and I don't see why I ever would. My understanding is that tags\ would contain things like "Version1Release\, Version2Release\, ThatTimeWeUpgradedEverthing\" etc. But here's the thing, if you are going in and need to make a change to the Version1Release then it should be a branch, and if

Clearing special permissions from folders in a branch

南楼画角 提交于 2020-01-09 10:30:08
问题 We're a fairly large project with a single trunk branch. Most of it uses the default permissions, but a few folders have custom permissions - say, only "Builders" group is allowed to check-in. We want to allow people to create their own private branches out of trunk, where they can freely check-in and merge later (hopefully often). However, creating a branch, the special permissions are copied along with the folders, meaning that people can't freely check-in into their branch. Is there a way

Git over Email?

久未见 提交于 2020-01-09 10:21:58
问题 Assuming network access is sporadic with no central server, what would be the best way to use git to keep three or more branches in sync? Is there a way to extract just my deltas, email those, and merge them on the other end? 回答1: While "git format-patch" and "git am" are great ways to manage patches from non-git sources, for git repositories you should investigate "git bundle". "git bundle" and the subcommands "create" and "unbundle" can be used to create and use a binary blob of incremental

Backup hosted repository to off-site location

不想你离开。 提交于 2020-01-07 07:43:13
问题 I am still pretty new to VCSs in general. I have a SVN repository hosted at assembla. I know how to check out and commit to the repository. But if I wanted to actually get a backup of the repository itself to save offsite. How can I do that? 回答1: Assembla provides an 'Import/Export' under the Subversion tab which allows you to get complete historical dumps of your repository. On a repository you host yourself, you can use svnadmin dump 来源: https://stackoverflow.com/questions/4596310/backup

How can you tell who merged which branch into git?

风格不统一 提交于 2020-01-07 06:54:22
问题 We are using git for a project, making use of git flow (http://nvie.com/posts/a-successful-git-branching-model/) to manage hotfixes, features, etc. However, somehow the changes in develop (which is weeks ahead of master ) have been merged into master , and a recent git push has published the unstable develop branch! How can I find out who merged develop into master and when this was done? How can I undo this, given that there will likely have been commits made after this merge, and also given