From 92e9eb46f66b20ef7c6f9125bbf1708fe647c8b2 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Tue, 1 Oct 2024 22:00:20 +0200 Subject: checkpoint --- after/plugin/luasnip.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'after/plugin/luasnip.lua') diff --git a/after/plugin/luasnip.lua b/after/plugin/luasnip.lua index c7ee31b..6d9f38d 100644 --- a/after/plugin/luasnip.lua +++ b/after/plugin/luasnip.lua @@ -27,8 +27,8 @@ ls.config.set_config({ ls.add_snippets("go", { ls.parser.parse_snippet("main", "package main\n\nfunc main() {\n\t$0\n}"), - ls.parser.parse_snippet("e", "if err != nil {\n\tfmt.Println(err)$1\n}\n$0"), - ls.parser.parse_snippet("ee", "if err != nil {\n\tfmt.Println(err)$1\n\tos.Exit(${2:1})\n}\n$0"), + ls.parser.parse_snippet("e", "if err != nil {\n\tpanic(err)$1\n}\n$0"), + ls.parser.parse_snippet("ee", "if err != nil {\n\tfmt.Fprintln(os.Stderr, err)$1\n\tos.Exit(${2:1})\n}\n$0"), ls.parser.parse_snippet("eif", "if err := $1; err != nil {\n\tfmt.Println(err)$2\n}\n$0"), ls.parser.parse_snippet("pf", "fmt.Printf($0)"), ls.parser.parse_snippet("pl", "fmt.Println($0)"), -- cgit v1.2.3