From 26f30e9626a4e254a9bee331d5debfe49f541907 Mon Sep 17 00:00:00 2001 From: James Liggett Date: Sun, 1 Jun 2008 19:58:00 -0700 Subject: [PATCH] Implement rebasing --- TODO.tasks | 10 +- plugins/git/Makefile.am | 8 +- plugins/git/anjuta-git.glade | 81 ++++++++++++++- plugins/git/anjuta-git.ui | 9 ++ plugins/git/git-rebase-continue-command.c | 106 +++++++++++++++++++ plugins/git/git-rebase-continue-command.h | 69 +++++++++++++ plugins/git/git-rebase-dialog.c | 166 ++++++++++++++++++++++++++++++ plugins/git/git-rebase-dialog.h | 38 +++++++ plugins/git/git-rebase-start-command.c | 94 +++++++++++++++++ plugins/git/git-rebase-start-command.h | 62 +++++++++++ plugins/git/plugin.c | 43 +++++++- 11 files changed, 678 insertions(+), 8 deletions(-) create mode 100644 plugins/git/git-rebase-continue-command.c create mode 100644 plugins/git/git-rebase-continue-command.h create mode 100644 plugins/git/git-rebase-dialog.c create mode 100644 plugins/git/git-rebase-dialog.h create mode 100644 plugins/git/git-rebase-start-command.c create mode 100644 plugins/git/git-rebase-start-command.h diff --git a/TODO.tasks b/TODO.tasks index 46eead4e..9a849bfc 100644 --- a/TODO.tasks +++ b/TODO.tasks @@ -643,11 +643,6 @@ Fix c++/gobject class generator to allow adding members, methods, signals, prope - - Rebasing - - - Generating patch series (format-patch) @@ -740,6 +735,11 @@ Fix c++/gobject class generator to allow adding members, methods, signals, prope Fetching + + + + + Rebasing diff --git a/plugins/git/Makefile.am b/plugins/git/Makefile.am index b2835b6c..8f7d4ec3 100644 --- a/plugins/git/Makefile.am +++ b/plugins/git/Makefile.am @@ -133,7 +133,13 @@ libanjuta_git_la_SOURCES = \ git-fetch-command.c \ git-fetch-command.h \ git-fetch-dialog.c \ - git-fetch-dialog.h + git-fetch-dialog.h \ + git-rebase-continue-command.c \ + git-rebase-continue-command.h \ + git-rebase-dialog.c \ + git-rebase-dialog.h \ + git-rebase-start-command.c \ + git-rebase-start-command.h libanjuta_git_la_LDFLAGS = $(ANJUTA_PLUGIN_LDFLAGS) diff --git a/plugins/git/anjuta-git.glade b/plugins/git/anjuta-git.glade index 60058fa6..fef0c19a 100644 --- a/plugins/git/anjuta-git.glade +++ b/plugins/git/anjuta-git.glade @@ -1,6 +1,6 @@ - + @@ -2394,4 +2394,83 @@ + + 5 + Rebase + GTK_WIN_POS_CENTER_ON_PARENT + GDK_WINDOW_TYPE_HINT_DIALOG + False + + + True + 2 + + + 250 + True + 0 + GTK_SHADOW_NONE + + + True + 12 + + + True + + + + + + + True + <b>Remote branch to rebase from:</b> + True + + + label_item + + + + + False + 1 + + + + + True + GTK_BUTTONBOX_END + + + True + True + True + gtk-cancel + True + -6 + + + + + True + True + True + gtk-ok + True + -5 + + + 1 + + + + + False + GTK_PACK_END + + + + + diff --git a/plugins/git/anjuta-git.ui b/plugins/git/anjuta-git.ui index 658e8d8d..39d00bf4 100644 --- a/plugins/git/anjuta-git.ui +++ b/plugins/git/anjuta-git.ui @@ -6,6 +6,15 @@ + + + + + + + + + diff --git a/plugins/git/git-rebase-continue-command.c b/plugins/git/git-rebase-continue-command.c new file mode 100644 index 00000000..bceddaf9 --- /dev/null +++ b/plugins/git/git-rebase-continue-command.c @@ -0,0 +1,106 @@ +/* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 4; tab-width: 4 -*- */ +/* + * anjuta + * Copyright (C) James Liggett 2008 + * + * anjuta is free software. + * + * You may redistribute it and/or modify it under the terms of the + * GNU General Public License, as published by the Free Software + * Foundation; either version 2 of the License, or (at your option) + * any later version. + * + * anjuta is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with anjuta. If not, write to: + * The Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor + * Boston, MA 02110-1301, USA. + */ + +#include "git-rebase-continue-command.h" + +struct _GitRebaseContinueCommandPriv +{ + GitRebaseContinueAction action; +}; + +G_DEFINE_TYPE (GitRebaseContinueCommand, git_rebase_continue_command, + GIT_TYPE_COMMAND); + +static void +git_rebase_continue_command_init (GitRebaseContinueCommand *self) +{ + self->priv = g_new0 (GitRebaseContinueCommandPriv, 1); +} + +static void +git_rebase_continue_command_finalize (GObject *object) +{ + GitRebaseContinueCommand *self; + + self = GIT_REBASE_CONTINUE_COMMAND (object); + + g_free (self->priv); + + G_OBJECT_CLASS (git_rebase_continue_command_parent_class)->finalize (object); +} + +static guint +git_rebase_continue_command_run (AnjutaCommand *command) +{ + GitRebaseContinueCommand *self; + + self = GIT_REBASE_CONTINUE_COMMAND (command); + + git_command_add_arg (GIT_COMMAND (command), "rebase"); + + switch (self->priv->action) + { + case GIT_REBASE_CONTINUE_ACTION_CONTINUE: + git_command_add_arg (GIT_COMMAND (command), "--continue"); + break; + case GIT_REBASE_CONTINUE_ACTION_SKIP: + git_command_add_arg (GIT_COMMAND (command), "--skip"); + break; + case GIT_REBASE_CONTINUE_ACTION_ABORT: + git_command_add_arg (GIT_COMMAND (command), "--abort"); + break; + default: + break; + } + + return 0; +} + +static void +git_rebase_continue_command_class_init (GitRebaseContinueCommandClass *klass) +{ + GObjectClass* object_class = G_OBJECT_CLASS (klass); + GitCommandClass* parent_class = GIT_COMMAND_CLASS (klass); + AnjutaCommandClass* command_class = ANJUTA_COMMAND_CLASS (klass); + + object_class->finalize = git_rebase_continue_command_finalize; + parent_class->output_handler = git_command_send_output_to_info; + command_class->run = git_rebase_continue_command_run; +} + +GitRebaseContinueCommand * +git_rebase_continue_command_new (const gchar *working_directory, + GitRebaseContinueAction action) +{ + GitRebaseContinueCommand *self; + + self = g_object_new (GIT_TYPE_REBASE_CONTINUE_COMMAND, + "working-directory", working_directory, + "single-line-output", TRUE, + NULL); + + self->priv->action = action; + + return self; +} diff --git a/plugins/git/git-rebase-continue-command.h b/plugins/git/git-rebase-continue-command.h new file mode 100644 index 00000000..40b85144 --- /dev/null +++ b/plugins/git/git-rebase-continue-command.h @@ -0,0 +1,69 @@ +/* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 4; tab-width: 4 -*- */ +/* + * anjuta + * Copyright (C) James Liggett 2008 + * + * anjuta is free software. + * + * You may redistribute it and/or modify it under the terms of the + * GNU General Public License, as published by the Free Software + * Foundation; either version 2 of the License, or (at your option) + * any later version. + * + * anjuta is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with anjuta. If not, write to: + * The Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor + * Boston, MA 02110-1301, USA. + */ + +#ifndef _GIT_REBASE_CONTINUE_COMMAND_H_ +#define _GIT_REBASE_CONTINUE_COMMAND_H_ + +#include +#include "git-command.h" + +G_BEGIN_DECLS + +#define GIT_TYPE_REBASE_CONTINUE_COMMAND (git_rebase_continue_command_get_type ()) +#define GIT_REBASE_CONTINUE_COMMAND(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GIT_TYPE_REBASE_CONTINUE_COMMAND, GitRebaseContinueCommand)) +#define GIT_REBASE_CONTINUE_COMMAND_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GIT_TYPE_REBASE_CONTINUE_COMMAND, GitRebaseContinueCommandClass)) +#define GIT_IS_REBASE_CONTINUE_COMMAND(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GIT_TYPE_REBASE_CONTINUE_COMMAND)) +#define GIT_IS_REBASE_CONTINUE_COMMAND_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GIT_TYPE_REBASE_CONTINUE_COMMAND)) +#define GIT_REBASE_CONTINUE_COMMAND_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GIT_TYPE_REBASE_CONTINUE_COMMAND, GitRebaseContinueCommandClass)) + +typedef struct _GitRebaseContinueCommandClass GitRebaseContinueCommandClass; +typedef struct _GitRebaseContinueCommand GitRebaseContinueCommand; +typedef struct _GitRebaseContinueCommandPriv GitRebaseContinueCommandPriv; + +struct _GitRebaseContinueCommandClass +{ + GitCommandClass parent_class; +}; + +struct _GitRebaseContinueCommand +{ + GitCommand parent_instance; + + GitRebaseContinueCommandPriv *priv; +}; + +typedef enum +{ + GIT_REBASE_CONTINUE_ACTION_CONTINUE, + GIT_REBASE_CONTINUE_ACTION_SKIP, + GIT_REBASE_CONTINUE_ACTION_ABORT +} GitRebaseContinueAction; + +GType git_rebase_continue_command_get_type (void) G_GNUC_CONST; +GitRebaseContinueCommand *git_rebase_continue_command_new (const gchar *working_directory, + GitRebaseContinueAction action); + +G_END_DECLS + +#endif /* _GIT_REBASE_CONTINUE_COMMAND_H_ */ diff --git a/plugins/git/git-rebase-dialog.c b/plugins/git/git-rebase-dialog.c new file mode 100644 index 00000000..21723ae9 --- /dev/null +++ b/plugins/git/git-rebase-dialog.c @@ -0,0 +1,166 @@ +/* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 4; tab-width: 4 -*- */ +/* + * anjuta + * Copyright (C) James Liggett 2008 + * + * anjuta is free software. + * + * You may redistribute it and/or modify it under the terms of the + * GNU General Public License, as published by the Free Software + * Foundation; either version 2 of the License, or (at your option) + * any later version. + * + * anjuta is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with anjuta. If not, write to: + * The Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor + * Boston, MA 02110-1301, USA. + */ + +#include "git-rebase-dialog.h" + +static void +on_rebase_dialog_response (GtkDialog *dialog, gint response_id, + GitBranchComboData *data) +{ + GtkWidget *rebase_branch_combo; + gchar *branch; + GtkTreeIter iter; + GitRebaseStartCommand *rebase_command; + GitProgressData *progress_data; + + if (response_id == GTK_RESPONSE_OK) + { + rebase_branch_combo = glade_xml_get_widget (data->gxml, + "rebase_branch_combo"); + + gtk_combo_box_get_active_iter (GTK_COMBO_BOX (rebase_branch_combo), + &iter); + branch = git_branch_combo_model_get_branch (data->model, &iter); + + rebase_command = git_rebase_start_command_new (data->plugin->project_root_directory, + branch); + progress_data = git_progress_data_new (data->plugin, + _("Git: Rebasing")); + + g_free (branch); + + create_message_view (data->plugin); + + g_signal_connect (G_OBJECT (rebase_command), "command-finished", + G_CALLBACK (on_command_finished), + data->plugin); + + g_signal_connect (G_OBJECT (rebase_command), "data-arrived", + G_CALLBACK (on_command_info_arrived), + data->plugin); + + g_signal_connect (G_OBJECT (rebase_command), "progress", + G_CALLBACK (on_command_progress), + data->plugin); + + g_signal_connect_swapped (G_OBJECT (rebase_command), + "command-finished", + G_CALLBACK (git_progress_data_free), + progress_data); + + anjuta_command_start (ANJUTA_COMMAND (rebase_command)); + } + + gtk_widget_destroy (GTK_WIDGET (dialog)); + git_branch_combo_data_free (data); +} + +static void +rebase_dialog (Git *plugin) +{ + GladeXML *gxml; + GtkWidget *dialog; + GtkWidget *rebase_branch_combo; + GtkListStore *branch_list_store; + GitBranchComboData *data; + GitBranchListCommand *list_command; + + gxml = glade_xml_new (GLADE_FILE, "rebase_dialog", NULL); + + dialog = glade_xml_get_widget (gxml, "rebase_dialog"); + rebase_branch_combo = glade_xml_get_widget (gxml, "rebase_branch_combo"); + branch_list_store = git_branch_combo_model_new (); + + gtk_combo_box_set_model (GTK_COMBO_BOX (rebase_branch_combo), + GTK_TREE_MODEL (branch_list_store)); + git_branch_combo_model_setup_widget (rebase_branch_combo); + + data = git_branch_combo_data_new (branch_list_store, + GTK_COMBO_BOX (rebase_branch_combo), gxml, + plugin); + + list_command = git_branch_list_command_new (plugin->project_root_directory, + GIT_BRANCH_TYPE_REMOTE); + + g_signal_connect (G_OBJECT (list_command), "data-arrived", + G_CALLBACK (on_list_branch_command_data_arrived), + data); + + g_signal_connect (G_OBJECT (list_command), "command-finished", + G_CALLBACK (on_list_branch_command_finished), + data); + + anjuta_command_start (ANJUTA_COMMAND (list_command)); + + g_signal_connect (G_OBJECT (dialog), "response", + G_CALLBACK (on_rebase_dialog_response), + data); + + gtk_widget_show_all (dialog); +} + +static void +rebase_continue (Git *plugin, GitRebaseContinueAction action) +{ + GitRebaseContinueCommand *rebase_command; + + create_message_view (plugin); + + rebase_command = git_rebase_continue_command_new (plugin->project_root_directory, + action); + + g_signal_connect (G_OBJECT (rebase_command), "command-finished", + G_CALLBACK (on_command_finished), + plugin); + + g_signal_connect (G_OBJECT (rebase_command), "data-arrived", + G_CALLBACK (on_command_info_arrived), + plugin); + + anjuta_command_start (ANJUTA_COMMAND (rebase_command)); +} + +void +on_menu_git_rebase_start (GtkAction *action, Git *plugin) +{ + rebase_dialog (plugin); +} + +void +on_menu_git_rebase_continue (GtkAction *action, Git *plugin) +{ + rebase_continue (plugin, GIT_REBASE_CONTINUE_ACTION_CONTINUE); +} + +void +on_menu_git_rebase_skip (GtkAction *action, Git *plugin) +{ + rebase_continue (plugin, GIT_REBASE_CONTINUE_ACTION_SKIP); +} + +void +on_menu_git_rebase_abort (GtkAction *action, Git *plugin) +{ + rebase_continue (plugin, GIT_REBASE_CONTINUE_ACTION_ABORT); +} diff --git a/plugins/git/git-rebase-dialog.h b/plugins/git/git-rebase-dialog.h new file mode 100644 index 00000000..ae006830 --- /dev/null +++ b/plugins/git/git-rebase-dialog.h @@ -0,0 +1,38 @@ +/* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 4; tab-width: 4 -*- */ +/* + * anjuta + * Copyright (C) James Liggett 2008 + * + * anjuta is free software. + * + * You may redistribute it and/or modify it under the terms of the + * GNU General Public License, as published by the Free Software + * Foundation; either version 2 of the License, or (at your option) + * any later version. + * + * anjuta is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with anjuta. If not, write to: + * The Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor + * Boston, MA 02110-1301, USA. + */ + +#ifndef _GIT_REBASE_DIALOG_H +#define _GIT_REBASE_DIALOG_H + +#include "git-rebase-start-command.h" +#include "git-rebase-continue-command.h" +#include "git-ui-utils.h" +#include "git-branch-combo-model.h" + +void on_menu_git_rebase_start (GtkAction *action, Git *plugin); +void on_menu_git_rebase_continue (GtkAction *action, Git *plugin); +void on_menu_git_rebase_skip (GtkAction *action, Git *plugin); +void on_menu_git_rebase_abort (GtkAction *action, Git *plugin); + +#endif diff --git a/plugins/git/git-rebase-start-command.c b/plugins/git/git-rebase-start-command.c new file mode 100644 index 00000000..bfac7b90 --- /dev/null +++ b/plugins/git/git-rebase-start-command.c @@ -0,0 +1,94 @@ +/* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 4; tab-width: 4 -*- */ +/* + * anjuta + * Copyright (C) James Liggett 2008 + * + * anjuta is free software. + * + * You may redistribute it and/or modify it under the terms of the + * GNU General Public License, as published by the Free Software + * Foundation; either version 2 of the License, or (at your option) + * any later version. + * + * anjuta is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with anjuta. If not, write to: + * The Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor + * Boston, MA 02110-1301, USA. + */ + +#include "git-rebase-start-command.h" + +struct _GitRebaseStartCommandPriv +{ + gchar *remote_branch; +}; + +G_DEFINE_TYPE (GitRebaseStartCommand, git_rebase_start_command, + GIT_TYPE_COMMAND); + +static void +git_rebase_start_command_init (GitRebaseStartCommand *self) +{ + self->priv = g_new0 (GitRebaseStartCommandPriv, 1); +} + +static void +git_rebase_start_command_finalize (GObject *object) +{ + GitRebaseStartCommand *self; + + self = GIT_REBASE_START_COMMAND (object); + + g_free (self->priv->remote_branch); + g_free (self->priv); + + G_OBJECT_CLASS (git_rebase_start_command_parent_class)->finalize (object); +} + +static guint +git_rebase_start_command_run (AnjutaCommand *command) +{ + GitRebaseStartCommand *self; + + self = GIT_REBASE_START_COMMAND (command); + + git_command_add_arg (GIT_COMMAND (command), "rebase"); + git_command_add_arg (GIT_COMMAND (command), self->priv->remote_branch); + + return 0; +} + +static void +git_rebase_start_command_class_init (GitRebaseStartCommandClass *klass) +{ + GObjectClass* object_class = G_OBJECT_CLASS (klass); + GitCommandClass* parent_class = GIT_COMMAND_CLASS (klass); + AnjutaCommandClass* command_class = ANJUTA_COMMAND_CLASS (klass); + + object_class->finalize = git_rebase_start_command_finalize; + parent_class->output_handler = git_command_send_output_to_info; + command_class->run = git_rebase_start_command_run; +} + + +GitRebaseStartCommand * +git_rebase_start_command_new (const gchar *working_directory, + const gchar *remote_branch) +{ + GitRebaseStartCommand *self; + + self = g_object_new (GIT_TYPE_REBASE_START_COMMAND, + "working-directory", working_directory, + "single-line-output", TRUE, + NULL); + + self->priv->remote_branch = g_strdup (remote_branch); + + return self; +} diff --git a/plugins/git/git-rebase-start-command.h b/plugins/git/git-rebase-start-command.h new file mode 100644 index 00000000..8f5c6ae3 --- /dev/null +++ b/plugins/git/git-rebase-start-command.h @@ -0,0 +1,62 @@ +/* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 4; tab-width: 4 -*- */ +/* + * anjuta + * Copyright (C) James Liggett 2008 + * + * anjuta is free software. + * + * You may redistribute it and/or modify it under the terms of the + * GNU General Public License, as published by the Free Software + * Foundation; either version 2 of the License, or (at your option) + * any later version. + * + * anjuta is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with anjuta. If not, write to: + * The Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor + * Boston, MA 02110-1301, USA. + */ + +#ifndef _GIT_REBASE_START_COMMAND_H_ +#define _GIT_REBASE_START_COMMAND_H_ + +#include +#include "git-command.h" + +G_BEGIN_DECLS + +#define GIT_TYPE_REBASE_START_COMMAND (git_rebase_start_command_get_type ()) +#define GIT_REBASE_START_COMMAND(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GIT_TYPE_REBASE_START_COMMAND, GitRebaseStartCommand)) +#define GIT_REBASE_START_COMMAND_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GIT_TYPE_REBASE_START_COMMAND, GitRebaseStartCommandClass)) +#define GIT_IS_REBASE_START_COMMAND(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GIT_TYPE_REBASE_START_COMMAND)) +#define GIT_IS_REBASE_START_COMMAND_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GIT_TYPE_REBASE_START_COMMAND)) +#define GIT_REBASE_START_COMMAND_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GIT_TYPE_REBASE_START_COMMAND, GitRebaseStartCommandClass)) + +typedef struct _GitRebaseStartCommandClass GitRebaseStartCommandClass; +typedef struct _GitRebaseStartCommand GitRebaseStartCommand; +typedef struct _GitRebaseStartCommandPriv GitRebaseStartCommandPriv; + +struct _GitRebaseStartCommandClass +{ + GitCommandClass parent_class; +}; + +struct _GitRebaseStartCommand +{ + GitCommand parent_instance; + + GitRebaseStartCommandPriv *priv; +}; + +GType git_rebase_start_command_get_type (void) G_GNUC_CONST; +GitRebaseStartCommand *git_rebase_start_command_new (const gchar *working_directory, + const gchar *remote_branch); + +G_END_DECLS + +#endif /* _GIT_REBASE_START_COMMAND_H_ */ diff --git a/plugins/git/plugin.c b/plugins/git/plugin.c index 5c9a23cd..10fce230 100644 --- a/plugins/git/plugin.c +++ b/plugins/git/plugin.c @@ -36,6 +36,7 @@ #include "git-reset-dialog.h" #include "git-revert-dialog.h" #include "git-fetch-dialog.h" +#include "git-rebase-dialog.h" #define UI_FILE PACKAGE_DATA_DIR"/ui/anjuta-git.ui" @@ -62,12 +63,52 @@ static GtkActionEntry actions_git[] = { "ActionGitFetch", /* Action name */ GTK_STOCK_CONNECT, /* Stock icon, if any */ - N_("_Fetch..."), /* Display label */ + N_("_Fetch"), /* Display label */ NULL, /* short-cut */ NULL, /* Tooltip */ G_CALLBACK (on_menu_git_fetch) /* action callback */ }, { + "ActionMenuGitRebase", /* Action name */ + NULL, /* Stock icon, if any */ + N_("_Rebase"), /* Display label */ + NULL, /* short-cut */ + NULL, /* Tooltip */ + NULL /* action callback */ + }, + { + "ActionGitRebaseStart", /* Action name */ + NULL, /* Stock icon, if any */ + N_("_Start..."), /* Display label */ + NULL, /* short-cut */ + NULL, /* Tooltip */ + G_CALLBACK (on_menu_git_rebase_start) /* action callback */ + }, + { + "ActionGitRebaseContinue", /* Action name */ + NULL, /* Stock icon, if any */ + N_("_Continue"), /* Display label */ + NULL, /* short-cut */ + NULL, /* Tooltip */ + G_CALLBACK (on_menu_git_rebase_continue) /* action callback */ + }, + { + "ActionGitRebaseSkip", /* Action name */ + NULL, /* Stock icon, if any */ + N_("_Skip"), /* Display label */ + NULL, /* short-cut */ + NULL, /* Tooltip */ + G_CALLBACK (on_menu_git_rebase_skip) /* action callback */ + }, + { + "ActionGitRebaseAbort", /* Action name */ + NULL, /* Stock icon, if any */ + N_("_Abort"), /* Display label */ + NULL, /* short-cut */ + NULL, /* Tooltip */ + G_CALLBACK (on_menu_git_rebase_abort) /* action callback */ + }, + { "ActionGitUnstageFiles", /* Action name */ GTK_STOCK_CANCEL, /* Stock icon, if any */ N_("_Unstage files..."), /* Display label */ -- 2.11.4.GIT