This project is read-only.



Clones a GIT repository from a TFS server path


Add-PartialBranchGitClone [[-tfsUrl] <String>] [[-branch] <String>] [[-localSourcePath] <String>] [[-remoteOrigin] <String>] [<CommonParameters>]


This is intended to be the git clone of the partial branch creatred by Add-PartialBranch. It uses git-tf to clone the TFS server path specified in the Branch argument to a git repository located at the path specifile in the LocalSourcePath argument. If a RemoteOrigin argument is provided, a origin Remote is added to the repository pointing to the path given in that parameter. A bare git repo of the repo just created is then cloned to that path. Autocrlf is set to false and ignorecase is set to true. If a NonVolatile workspace was created using Add-NonVolatileEnlistment then its directories are symbolicaly linked and an excludes file is added to .git\info for those directories.



The TFS Collection URL to use for connecting to TFS


The TFS Serverpath to be cloned


Local path where the git repository will reside

RemoteOrigin (optional)

Path where a bare repository will be cloned to and added as the origin Remote. If a http or git:// based URI is enterd, the repo will not be cloned, instead the uri will simply be added as the remote origin.


Add-PartialBranchGitClone -tfsUrl http://myserver:8080/tfs -branch $/my/branch -localSourcePath "c:\dev\src\" -RemoteOrigin \\server\share\repo
This will create a git repository of $my/branch located at c:\dev\src and the repo will be cloned to \\server\share\repo. All git pushes and pulls will be directed tothat remote location.

Last edited Jan 14, 2013 at 6:32 AM by mwrock, version 2


No comments yet.