feat: json2go (#130)

* feat(json2go): implement

* feat(json2go): support manual input

* chore(readme): add json2go

* chore(docs): add docs
This commit is contained in:
Oleksandr Smirnov 2025-12-08 21:29:34 +02:00 committed by GitHub
parent 4a2384ade8
commit 6a3924cee5
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
16 changed files with 312 additions and 1 deletions

View file

@ -70,6 +70,12 @@ cmd("GoTagClear", function()
require("gopher").tags.clear()
end)
-- :GoJson
cmd("GoJson", function(opts)
local inp = ((opts.args ~= "" and opts.args) or nil)
require("gopher.json2go").json2go(inp)
end, "*")
-- :GoTest
cmd("GoTestAdd", function()
require("gopher").test.add()
@ -89,7 +95,6 @@ cmd("GoMod", function(opts)
end, "*")
cmd("GoGet", function(opts)
vim.print(opts)
require("gopher").get(opts.fargs)
end, "*")