Add-PartialBranch
SYNOPSIS
Creates a TFS partial branch based on mappings from an existing branch
SYNTAX
Add-PartialBranch [-mappings] <String[]> [-tfsUrl <String>] [-localSourcePath <String>] [-serverPathToBranch <String>] [-partialBranchPath <String>] [-localPathToken <String>] [-force] [<CommonParameters>]
DESCRIPTION
A local workspace is created that takes the mappings passed in and replaces the ServerPathToBranch argument with the PartialBranchPath. A Branch operation is then performed to branch ServerPathToBranch to PartialBranchPath and then the new branch is commited. If the Partial branch already exists, the branch operation will not be included.
PARAMETERS
Mappings
List of mappings from the parent branch workspace to include in partial branch.
TfsUrl
The TFS Collection URL to use for connecting to TFS
LocalSourcePath
Local path where the workspace mappings should be rooted to
ServerPathToBranch
Server path of the TFS directory being branched
PartialBranchPath
Server path of destination branch
LocalPathToken (optional)
String in the local path of the Mappings to be replaced with the LocalSourcePath parameter. The default is 'c:\'.
Force (optional)
If a wokspace already exists that was not created by BigGit then add these mappings to that workspace
EXAMPLE 1
Invoke-TF workfold /workspace:"SomeOtherWorkspace;Matt Wrock" | Add-PartialBranch -tfsUrl http://myserver:8080/tfs -localSourcePath "c:\dev\src\" -localPathToken "c:\" -ServerPathToBranch $/my/branch -PartialBranchPath $/my/new/branch
This will create a new workspace at c:\dev\src and branch $/my/path to $/my/new/path