### Function

# Ggit RevertOptions new

#### Declaration [src]

    GgitRevertOptions*
    ggit_revert_options_new (
      guint mainline,
      GgitMergeOptions* merge_options,
      GgitCheckoutOptions* checkout_options
    )

#### Description [src]

Create a new `GgitRevertOptions`. Note that the passed in `merge_options` and `checkout_options` are copied by this function, and alterations in either after this call are therefore not reflected in the revert options.

The `mainline` indicates which parent to use for the revert when reverting a merge commit.

#### Parameters

`mainline`

  Type: `guint`

  The mainline.

`merge_options`

  Type: `GgitMergeOptions`

  A `GgitMergeOptions`.

  The argument can be `NULL`.
  The data is owned by the caller of the function.

`checkout_options`

  Type: `GgitCheckoutOptions`

  A `GgitCheckoutOptions`.

  The argument can be `NULL`.
  The data is owned by the caller of the function.

#### Return value

Type: `GgitRevertOptions`

A `GgitRevertOptions` or `NULL`.

The caller of the function takes ownership of the data, and is responsible for freeing it.
The return value can be `NULL`.