[libgit2-glib] Fix ggit_repository_reset for api break
- From: Ignacio Casal Quinteiro <icq src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libgit2-glib] Fix ggit_repository_reset for api break
- Date: Sun, 18 Jan 2015 15:55:38 +0000 (UTC)
commit 40edf539d8a8e987bec767e6458c68099c9f42a4
Author: Ignacio Casal Quinteiro <icq gnome org>
Date: Sun Jan 18 16:55:22 2015 +0100
Fix ggit_repository_reset for api break
libgit2-glib/ggit-repository.c | 16 ++++++++++------
libgit2-glib/ggit-repository.h | 1 +
2 files changed, 11 insertions(+), 6 deletions(-)
---
diff --git a/libgit2-glib/ggit-repository.c b/libgit2-glib/ggit-repository.c
index ec20ccd..6b48438 100644
--- a/libgit2-glib/ggit-repository.c
+++ b/libgit2-glib/ggit-repository.c
@@ -1966,6 +1966,7 @@ ggit_repository_submodule_foreach (GgitRepository *repository,
* @repository: a #GgitRepository.
* @target: the target #GgitObject which is a commit or a tag.
* @reset_type: the #GgitResetType to perform.
+ * @checkout_options: the #GgitCheckoutOptions to be used for a HARD reset.
* @signature: a #GgitSignature that will used to populate the reflog entry.
* @log_message: The one line long message to be appended to the reflog.
* @error: a #GError for error reporting, or %NULL.
@@ -1974,17 +1975,19 @@ ggit_repository_submodule_foreach (GgitRepository *repository,
* or @error will be set.
*/
void
-ggit_repository_reset (GgitRepository *repository,
- GgitObject *target,
- GgitResetType reset_type,
- GgitSignature *signature,
- const gchar *log_message,
- GError **error)
+ggit_repository_reset (GgitRepository *repository,
+ GgitObject *target,
+ GgitResetType reset_type,
+ GgitCheckoutOptions *checkout_options,
+ GgitSignature *signature,
+ const gchar *log_message,
+ GError **error)
{
gint ret;
g_return_if_fail (GGIT_IS_REPOSITORY (repository));
g_return_if_fail (GGIT_IS_OBJECT (target));
+ g_return_if_fail (GGIT_IS_CHECKOUT_OPTIONS (checkout_options));
g_return_if_fail (GGIT_IS_SIGNATURE (signature));
g_return_if_fail (log_message != NULL);
g_return_if_fail (error == NULL || *error == NULL);
@@ -1992,6 +1995,7 @@ ggit_repository_reset (GgitRepository *repository,
ret = git_reset (_ggit_native_get (repository),
_ggit_native_get (target),
(git_reset_t)reset_type,
+ (git_checkout_options *)_ggit_checkout_options_get_checkout_options
(checkout_options),
_ggit_native_get (signature),
log_message);
diff --git a/libgit2-glib/ggit-repository.h b/libgit2-glib/ggit-repository.h
index 2a99e7e..39ba2d0 100644
--- a/libgit2-glib/ggit-repository.h
+++ b/libgit2-glib/ggit-repository.h
@@ -307,6 +307,7 @@ gboolean ggit_repository_submodule_foreach (GgitRepository
void ggit_repository_reset (GgitRepository *repository,
GgitObject *target,
GgitResetType reset_type,
+ GgitCheckoutOptions *checkout_options,
GgitSignature *signature,
const gchar *log_message,
GError **error);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]