Commit Graph

125 Commits

Author SHA1 Message Date
Philippe Miossec 2ef7feb69d update libgit2sharp to v0.12 2013-06-04 00:31:25 +02:00
Matt Burke a0b228661e Merge remote-tracking branch 'origin/master'
Conflicts:
	GitTfs/Core/GitTfsRemote.cs
2013-05-29 10:23:59 -04:00
Matt Burke a5b56e8223 Merge pull request #361 from spraints/update-ref
Replace Process.Start with libgit2sharp. (closes #360)
2013-05-08 06:54:05 -07:00
Matt Burke f1d3f18e3e Use the new refs API.
Thanks @Saaman!!!!
2013-05-03 16:21:36 -04:00
Matt Burke 09606b228d Eliminate Process.Start("git", "update-ref", ...) 2013-04-29 12:00:34 -04:00
Matt Burke bac056c50e Update libgit2sharp. 2013-04-29 11:48:51 -04:00
Philippe Miossec bb9d724b1d Replace git command update-ref by a LibGit2Sharp call to UpdateRef() 2013-04-22 21:57:32 +02:00
Ed Parcell 22100d99cc Try to use full path in HashAndInsertObject in bare repositories. Fixes #285. 2013-04-18 14:17:47 -04:00
J.Ru db9a445089 Unshelve based on the parent changeset Id 2013-04-17 14:40:49 +02:00
J.Ru d23af4b952 Rename UpdateTfsHead and new purpose for UpdateRef 2013-04-17 14:40:27 +02:00
Matt Burke 52c6af1ba2 Merge remote-tracking branch 'origin/master' into gitattributes-added
Conflicts:
	GitTfs.sln
2013-03-25 11:39:23 -07:00
ivan-danilov 8b921e4cf3 Removed duplicated line after Matt's review. 2013-03-21 14:53:28 +02:00
ivan.danilov-econ e74170291a Fix: Rcheckin ignores --no-build-default-comment option (during rcheckin of merge commit prevents including all comments from merged commits below original merge-commit comment in git) 2013-03-21 14:53:28 +02:00
ivan.danilov-econ 690ccef82e Normalized line endings to be LF in repository (line ending in the working copy managed by core.autocrlf option) 2013-03-21 14:35:22 +02:00
ivan.danilov-econ 416543cd7a Fix: git-tfs tries to authenticate against all TFS instances in the branch no matter how old they were in use and if they needed at all.
Our TFS instance recently changed URL and without this change it is required to filter-branch entire repository and change every git-tfs-id line in comments just to make git-tfs stop going to old URL to check. With it one should just keep config section for old branch and change the very last commit's comment (for each TFS branch). Also theoretically should save some time if several TFS instances are used as only specified with -i option is authenticated against.
2013-03-11 15:47:16 +02:00
Philippe Miossec 6e78b56d4d rcheckin --quick : reset current branch to tfs remote to be synchronized with tfs 2013-03-09 11:23:21 +01:00
Philippe Miossec 39a68b0b23 Replace Count() by Any() when possible 2013-03-08 22:04:20 +01:00
doug fe2a741e68 Cleaning up logic around currentCommit variable 2013-02-22 09:31:55 -05:00
doug f1402509d2 Handle parsing merge commit messages with multiple TFS changeset ids
The original code would null out currentCommit after parsing the FIRST changeset id in the
log message, and associate the null commit hash with any additional changeset ids in the message
for the same commit. This eventually leads to a null reference error when executing git commands
that require the hash.

The new code ignores all of the changeset ids in the commit message except for the last one, which
is the only one that matters.
2013-02-21 16:44:57 -05:00
Philippe Miossec 00a6e34d8c Add create Tfs branch option to branchcommand
+ other small refactoring
2013-02-03 22:17:58 +01:00
Philippe Miossec a334a57952 Add move and delete branch option to branchcommand
and add a DeleteTfsRemote() and MoveRemote() in GitRepository
2013-02-03 18:53:16 +01:00
Philippe Miossec e30b5a5ab7 CreateTfsRemote() should return a GitTfsRemote authenticated 2013-01-12 21:31:16 +01:00
Matt Burke bee409ed42 Fallout from those merge conflicts. 2013-01-09 16:58:05 -05:00
Matt Burke d062991eff Merge branch 'master' into refactor-to-functional-core
Conflicts:
	GitTfs/Commands/Init.cs
	GitTfs/Core/GitRepository.cs
	GitTfs/Core/GitTfsRemote.cs
	GitTfsTest/Integration/CloneTests.cs
	GitTfsTest/Integration/IntegrationHelper.cs
2013-01-09 15:39:59 -05:00
Matt Burke d7cca94d4c Merge pull request #274. 2013-01-08 07:03:59 -05:00
Philippe Miossec f8972459aa Authenticate remotes on TFS only when needed
Prevent to authenticate all the remotes (which takes time) and is not needed for nearly all commands
2013-01-07 21:55:20 +01:00
Sean M. Collins 5f3c7ae5eb Merge pull request #276 from pmiossec/add_notes_for_workitems
Add a note on the commit to keep trace of the workitems
2013-01-07 12:21:24 -08:00
Philippe Miossec a2e3184c21 Remove call to git command to set config (use libgit2sharp instead) 2013-01-06 23:30:39 +01:00
Philippe Miossec b5fb9b5b5b Add a note on the commit to keep trace of the workitems
Manage workitems when fetching changesets with adding a note with the workitems
displaying Id, title and a link to the workitem
2013-01-04 13:38:46 +01:00
Daniel Lee 4784e99fde Add Fetch/Pull tests
Created tests for comparing the tfs url, legacy urls and
the repository path with mixed case when calling git tfs fetch or
git tfs pull. Used libgit2sharp to count the commits before and after.
Added support for running commands from the project directory (git
tfs clone is called from outside the project directory).
2013-01-03 00:49:58 +01:00
Daniel Lee 6e42acb54b Add method to compare Tfs url and Repo path to GitTfsRemote
Moving logic from TfsHelper.Common and GitRepository into GitTfsRemote.
Easier to test as TfsHelper is tightly connected to Tfs and GitRepository is
difficult to test directly. Added tests for GitTfsRemote.
2013-01-02 23:54:36 +01:00
David Alpert 637569c424 trailing slashes are stripped from incoming TFS repository paths so that exact comparisons match properly. 2013-01-02 00:50:19 -06:00
Philippe Miossec 6577c3ca8d Look for remotes only in local config list! 2012-12-23 00:25:51 +01:00
Matt Burke 4d97b71542 Use a custom workspace, if desired. 2012-12-20 16:24:59 -05:00
Philippe Miossec 4d7e0f4125 Add a 'labels' command to get TFS labels of a branch
Synthaxe is similar to 'fetch' command with '-i' and '--all' options...
+ Add an option `--with-labels` to the 'fetch' command to get TFS labels when fetching TFS changesets
2012-12-15 13:45:04 +01:00
Kim Gybels f3325488fa Merge branch 'master' into unicode
Conflicts:
	GitTfsTest/Core/GitChangeInfoTests.cs
	GitTfsTest/Integration/CloneTests.cs
	GitTfsTest/Integration/IntegrationHelper.cs

Conflicts were because extra unit tests were added and existing unit
tests were changed in the unicode branch, and this was done before
the move to xUnit.
2012-12-09 18:29:24 +01:00
Matt Burke 2302a52b28 Use the ligit2 force. 2012-11-30 11:29:00 -05:00
Philippe Miossec 3bf9fa4fb5 init-branch : Update libgit2sharp to use IsValidName() 2012-11-22 19:08:40 +01:00
Philippe Miossec 5a5c7c3812 GitRepository : verify if _repository is null before disposing (it could happened...) 2012-11-19 22:03:59 +01:00
Philippe Miossec 3bd03ad60f init-branch : to manage TFS branches with '.' in their names (which is supported by Git but not by git-tfs at the moment!) 2012-11-19 22:03:59 +01:00
Philippe Miossec da5a6201a5 Creation of the command "init-branch" to manage the cloning of a TFS branch (or all) from a TFS Server (2010, 2012 and 2008 partly)
Compiled for TFS Server 2008, 2010, 2012 and tested with TFS Server 2010, 2012

!! This command need that the clone of the TFS repository was made from the trunk (and not on the whole repository) and with history (not a quick-clone).

Usage for TFS 2010 and 2012 :
-------------------------------
* to clone one branch
git tfs init-branch $/Repository/path <git-branch-name-wished>
ex :
git tfs init-branch $/Repository/ProjectBranch
git tfs init-branch $/Repository/ProjectBranch myNewBranch

* to clone all branches
git tfs init-branch --all

Usage for TFS 2008 :
---------------------
* to clone one branch
git tfs init-branch--parent-branch=$/Repository/ProjectParentBranch $/Repository/path <git-branch-name-wished>

ex :
git tfs init-branch --parent-branch=$/Repository/ProjectParentBranch $/Repository/ProjectBranch
git tfs init-branch --parent-branch=$/Repository/ProjectParentBranch $/Repository/ProjectBranch myNewBranch
2012-11-19 22:03:42 +01:00
Ivan Korneliuk ed95fc1dc6 Normalize commit message line endings to CR+LF style.
This forces commit message to be shown correctly in TFS check-in dialog,
regardless of line endings specified in the original git commit message.
2012-10-23 09:50:59 +03:00
Sam Critchley c0d57b82ad removed an out of convention new line 2012-10-20 17:14:08 +11:00
Sam Critchley 28d7c0d2ff modified TfsCommitInfoRegex to be multiline and its now used to remove tfs ids from the result of GitRepository.GetCommitMessage 2012-10-20 17:10:04 +11:00
Matt Burke 6dd896eecd Unit tests for the configuration for a new tfs remote. 2012-10-16 13:53:13 -04:00
Matt Burke 455b5f2536 New config reader for tfs remotes. 2012-09-10 23:18:36 -04:00
Eldhuset, Åsmund 3a1d996aad Making GitRepository.GetObjects() return file names with forward slashes.
The problems caused by TFS changesets that differ in case from existing tree entries have already been solved by TfsChangeset.UpdateToMatchExtantCasing(), except when LibGit2Sharp returns tree entries with backslashes instead of forward slashes, which causes TfsChangeset.UpdateToMatchExtantCasing() to miss the existing entries.
2012-08-16 20:43:48 +02:00
Kim Gybels 186a0184c2 Use -z option with git diff-tree.
When -z has been given, diff-tree does not munge pathnames and uses
NULs as output field terminators. This allows for secure parsing of
the output.

Quoted paths were not correctly interpreted as UTF-8. This avoids the
problem by not having quoted paths.
2012-08-11 19:22:56 +02:00
Sean M. Collins 9c994a4fdf Replace Git shell command with LibGit2Sharp tree operations 2012-06-07 15:33:18 -04:00
Sean M. Collins b0eb392cab Replace GitSharp FileMode with LibGit2Sharp.Mode 2012-05-31 15:00:52 -04:00