Skip to content

Commit d1233cc

Browse files
authored
fix: goto definition error out due to buffer is not modifiable (nvim-java#74)
1 parent 02e3d5c commit d1233cc

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

lua/java/startup/decompile-watcher.lua

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,9 @@ function M.setup()
2929
:java_decompile(opts.file)
3030

3131
local lines = vim.split(text, '\n')
32+
33+
vim.bo[buffer].modifiable = true
34+
3235
vim.api.nvim_buf_set_lines(buffer, 0, -1, true, lines)
3336

3437
vim.bo[buffer].swapfile = false
@@ -44,7 +47,7 @@ function M.setup()
4447
.catch(get_error_handler('decompilation failed for ' .. opts.file))
4548
.run()
4649

47-
vim.wait(3000, function()
50+
vim.wait(10000, function()
4851
return done
4952
end)
5053
end,

0 commit comments

Comments
 (0)