From c29fa4f43ff584d18fb067234c2db1013339c81d Mon Sep 17 00:00:00 2001 From: Harrison Cramer Date: Mon, 28 Aug 2023 08:21:31 -0400 Subject: [PATCH] Bugfix: Fixed default state --- README.md | 4 ++-- lua/gitlab/state.lua | 10 +++++++--- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index bd14ec8..0a87dbf 100644 --- a/README.md +++ b/README.md @@ -146,14 +146,14 @@ require("gitlab").create_comment() Gitlab groups threads of comments together into "discussions." -To display discussions for the current MR, use the `list_discussions()` command, which will show the discussions in a split window. +To display discussions for the current MR, use the `toggle_discussions()` command, which will show the discussions in a split window. You can jump to the comment's location the reviewer window by using the `m` key, or the actual file with the 'j' key, when hovering over the line in the tree. Within the discussion tree, you can delete/edit/reply to comments, or toggle them as resolved or not. ```lua -require("gitlab").list_discussions() +require("gitlab").toggle_discussions() require("gitlab").delete_comment() require("gitlab").edit_comment() require("gitlab").reply() diff --git a/lua/gitlab/state.lua b/lua/gitlab/state.lua index 0130ae4..e749d63 100644 --- a/lua/gitlab/state.lua +++ b/lua/gitlab/state.lua @@ -10,6 +10,7 @@ local M = {} M.settings = { port = 21036, log_path = (vim.fn.stdpath("cache") .. "/gitlab.nvim.log"), + reviewer = "delta", popup = { exit = "", perform_action = "s", @@ -17,6 +18,7 @@ M.settings = { discussion_tree = { toggle = "d", jump_to_file = "o", + jump_to_reviewer = "m", edit_comment = "e", delete_comment = "dd", reply = "r", @@ -29,9 +31,11 @@ M.settings = { unresolved = '' }, review_pane = { - added_file = "", - modified_file = "", - removed_file = "", + delta = { + added_file = "", + modified_file = "", + removed_file = "", + } }, dialogue = { focus_next = { "j", "", "" },