Merge

Contains helper functions which allow to deal with git merge.

Nested types and modules

TypeDescription
MergeType

Git merge option.

Functions and values

Function or valueDescription
compareBranches(...)
Signature: repositoryDir:string -> local:string -> remote:string -> MergeType

Tests whether branches and their "origin" counterparts have diverged and need merging first.

Parameters

  • repositoryDir - The git repository.
  • local - The local branch name.
  • remote - The remote branch name.
FastForwardFlag
Signature: string

Allows git to use fast-forward merges

getMergeMessage(repositoryDir)
Signature: repositoryDir:string -> string

Gets the current merge message.

merge repositoryDir flags branch
Signature: repositoryDir:string -> flags:string -> branch:string -> unit

Performs a merge of the given branch with the current branch

Parameters

  • repositoryDir - The git repository.

  • flags - Additional flags.

  • branch - The branch we want to merge in.

    Sample

    merge @"C:\code\Fake" NoFastForwardFlag "master"

NoFastForwardFlag
Signature: string

Forbids git to use fast-forward merges