From 4f52ecd3fa0222c03f7917f3c70aef77ce2d6306 Mon Sep 17 00:00:00 2001 From: Fredrik Fornwall Date: Tue, 29 Aug 2017 23:23:40 +0200 Subject: [PATCH] neovim: Update to latest git master This allows us to drop our tui.c patch as it has been merged. --- packages/neovim/build.sh | 7 +- packages/neovim/src-nvim-tui-tui.c.patch | 147 ----------------------- 2 files changed, 3 insertions(+), 151 deletions(-) delete mode 100644 packages/neovim/src-nvim-tui-tui.c.patch diff --git a/packages/neovim/build.sh b/packages/neovim/build.sh index b5d5348ea..70ba4bf26 100644 --- a/packages/neovim/build.sh +++ b/packages/neovim/build.sh @@ -1,9 +1,8 @@ TERMUX_PKG_HOMEPAGE=https://neovim.io/ TERMUX_PKG_DESCRIPTION="Ambitious Vim-fork focused on extensibility and agility (nvim)" -local _COMMIT=9ff0cc70855fc3eb11ad0162ee02e742f354d360 -TERMUX_PKG_VERSION=0.2.1~20170822 -TERMUX_PKG_REVISION=1 -TERMUX_PKG_SHA256=8d97b6d3e7b185ee41992fb599db5df10beeba311b57580c75ec8fb078aa3e02 +local _COMMIT=5566f30006a73c30dfbdeece2e08830826d28aa4 +TERMUX_PKG_VERSION=0.2.1~20170826 +TERMUX_PKG_SHA256=fe288d4da7021c4fbbed000b327fb56887d66f704f34292900e0615579cde418 TERMUX_PKG_SRCURL=https://github.com/neovim/neovim/archive/${_COMMIT}.zip TERMUX_PKG_DEPENDS="libuv, libmsgpack, libandroid-support, libvterm, libtermkey, libutil, liblua" TERMUX_PKG_FOLDERNAME="neovim-$_COMMIT" diff --git a/packages/neovim/src-nvim-tui-tui.c.patch b/packages/neovim/src-nvim-tui-tui.c.patch deleted file mode 100644 index 6b7ea279d..000000000 --- a/packages/neovim/src-nvim-tui-tui.c.patch +++ /dev/null @@ -1,147 +0,0 @@ -Discussed at https://github.com/neovim/neovim/pull/7204 - -diff -u -r ../neovim-9ff0cc70855fc3eb11ad0162ee02e742f354d360/src/nvim/tui/tui.c ./src/nvim/tui/tui.c ---- ../neovim-9ff0cc70855fc3eb11ad0162ee02e742f354d360/src/nvim/tui/tui.c 2017-08-22 01:46:43.000000000 +0200 -+++ ./src/nvim/tui/tui.c 2017-08-22 13:09:48.599217223 +0200 -@@ -234,9 +234,9 @@ - unibi_out(ui, unibi_keypad_xmit); - unibi_out(ui, unibi_clear_screen); - // Enable bracketed paste -- unibi_out(ui, data->unibi_ext.enable_bracketed_paste); -+ unibi_out_ext(ui, data->unibi_ext.enable_bracketed_paste); - // Enable focus reporting -- unibi_out(ui, data->unibi_ext.enable_focus_reporting); -+ unibi_out_ext(ui, data->unibi_ext.enable_focus_reporting); - uv_loop_init(&data->write_loop); - if (data->out_isatty) { - uv_tty_init(&data->write_loop, &data->output_handle.tty, data->out_fd, 0); -@@ -263,9 +263,9 @@ - unibi_out(ui, unibi_keypad_local); - unibi_out(ui, unibi_exit_ca_mode); - // Disable bracketed paste -- unibi_out(ui, data->unibi_ext.disable_bracketed_paste); -+ unibi_out_ext(ui, data->unibi_ext.disable_bracketed_paste); - // Disable focus reporting -- unibi_out(ui, data->unibi_ext.disable_focus_reporting); -+ unibi_out_ext(ui, data->unibi_ext.disable_focus_reporting); - flush_buf(ui, true); - uv_tty_reset_mode(); - uv_close((uv_handle_t *)&data->output_handle, NULL); -@@ -426,14 +426,14 @@ - data->params[0].i = (fg >> 16) & 0xff; // red - data->params[1].i = (fg >> 8) & 0xff; // green - data->params[2].i = fg & 0xff; // blue -- unibi_out(ui, data->unibi_ext.set_rgb_foreground); -+ unibi_out_ext(ui, data->unibi_ext.set_rgb_foreground); - } - - if (bg != -1) { - data->params[0].i = (bg >> 16) & 0xff; // red - data->params[1].i = (bg >> 8) & 0xff; // green - data->params[2].i = bg & 0xff; // blue -- unibi_out(ui, data->unibi_ext.set_rgb_background); -+ unibi_out_ext(ui, data->unibi_ext.set_rgb_background); - } - } else { - if (fg != -1) { -@@ -679,7 +679,7 @@ - data->params[1].i = grid->bot; - unibi_out(ui, unibi_change_scroll_region); - if (grid->left != 0 || grid->right != ui->width - 1) { -- unibi_out(ui, data->unibi_ext.enable_lr_margin); -+ unibi_out_ext(ui, data->unibi_ext.enable_lr_margin); - if (data->can_set_lr_margin) { - data->params[0].i = grid->left; - data->params[1].i = grid->right; -@@ -700,7 +700,7 @@ - UGrid *grid = &data->grid; - - if (0 <= data->unibi_ext.reset_scroll_region) { -- unibi_out(ui, data->unibi_ext.reset_scroll_region); -+ unibi_out_ext(ui, data->unibi_ext.reset_scroll_region); - } else { - data->params[0].i = 0; - data->params[1].i = ui->height - 1; -@@ -717,7 +717,7 @@ - data->params[0].i = ui->width - 1; - unibi_out(ui, unibi_set_right_margin_parm); - } -- unibi_out(ui, data->unibi_ext.disable_lr_margin); -+ unibi_out_ext(ui, data->unibi_ext.disable_lr_margin); - } - unibi_goto(ui, grid->row, grid->col); - } -@@ -730,7 +730,7 @@ - if (!got_winch) { // Try to resize the terminal window. - data->params[0].i = (int)height; - data->params[1].i = (int)width; -- unibi_out(ui, data->unibi_ext.resize_screen); -+ unibi_out_ext(ui, data->unibi_ext.resize_screen); - // DECSLPP does not reset the scroll region. - if (data->scroll_region_is_full_screen) { - reset_scroll_region(ui); -@@ -836,7 +836,7 @@ - { - TUIData *data = ui->data; - if (!data->mouse_enabled) { -- unibi_out(ui, data->unibi_ext.enable_mouse); -+ unibi_out_ext(ui, data->unibi_ext.enable_mouse); - data->mouse_enabled = true; - } - } -@@ -845,7 +845,7 @@ - { - TUIData *data = ui->data; - if (data->mouse_enabled) { -- unibi_out(ui, data->unibi_ext.disable_mouse); -+ unibi_out_ext(ui, data->unibi_ext.disable_mouse); - data->mouse_enabled = false; - } - } -@@ -864,7 +864,7 @@ - if (attr > 0) { - attrentry_T *aep = syn_cterm_attr2entry(attr); - data->params[0].i = aep->rgb_bg_color; -- unibi_out(ui, data->unibi_ext.set_cursor_color); -+ unibi_out_ext(ui, data->unibi_ext.set_cursor_color); - } - } - -@@ -875,7 +875,7 @@ - default: WLOG("Unknown shape value %d", shape); break; - } - data->params[0].i = shape + (int)(c.blinkon == 0); -- unibi_out(ui, data->unibi_ext.set_cursor_style); -+ unibi_out_ext(ui, data->unibi_ext.set_cursor_style); - } - - /// @param mode editor mode -@@ -1189,11 +1189,23 @@ - const char *str = NULL; - - if (unibi_index >= 0) { -- if (unibi_index < unibi_string_begin_) { -- str = unibi_get_ext_str(data->ut, (unsigned)unibi_index); -- } else { -- str = unibi_get_str(data->ut, (unsigned)unibi_index); -- } -+ str = unibi_get_str(data->ut, (unsigned)unibi_index); -+ } -+ -+ if (str) { -+ unibi_var_t vars[26 + 26] = {{0}}; -+ unibi_format(vars, vars + 26, str, data->params, out, ui, NULL, NULL); -+ } -+} -+ -+static void unibi_out_ext(UI *ui, int unibi_index) -+{ -+ TUIData *data = ui->data; -+ -+ const char *str = NULL; -+ -+ if (unibi_index >= 0) { -+ str = unibi_get_ext_str(data->ut, (unsigned)unibi_index); - } - - if (str) {