diff --git a/README.md b/README.md index c1c9b36..b9a1d72 100644 --- a/README.md +++ b/README.md @@ -101,6 +101,9 @@ The plugin provides a `:J` command that accepts jj subcommands: ```lua { "nicolasgb/jj.nvim", + dependencies = { + "folke/snacks.nvim", -- Optional only if you use picker's + }, config = function() require("jj").setup({}) local cmd = require "jj.cmd" diff --git a/lua/jj/cmd.lua b/lua/jj/cmd.lua index d53af17..e665215 100644 --- a/lua/jj/cmd.lua +++ b/lua/jj/cmd.lua @@ -176,6 +176,7 @@ local function get_rev_from_log_line(line) } local revset + --TODO: handle x on conflicts -- Try each symbol pattern for _, symbol in pairs(jj_symbols) do @@ -403,7 +404,7 @@ local function handle_log_diff() local revset = get_rev_from_log_line(line) if revset then - local cmd = string.format("jj diff -r %s", revset) + local cmd = string.format("jj show %s", revset) run_floating(cmd) else utils.notify("No valid revision found in the log line", vim.log.levels.ERROR)