From 3ab230400f77116de07f29e2e8536b623cce77bf Mon Sep 17 00:00:00 2001 From: Marc Coquand Date: Sat, 13 Jul 2024 15:16:54 -0500 Subject: Vim updates --- vim/pack/downloads/opt/snippets/snippets.vim | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) (limited to 'vim/pack/downloads/opt/snippets') diff --git a/vim/pack/downloads/opt/snippets/snippets.vim b/vim/pack/downloads/opt/snippets/snippets.vim index 24d2ce3..92f0af7 100644 --- a/vim/pack/downloads/opt/snippets/snippets.vim +++ b/vim/pack/downloads/opt/snippets/snippets.vim @@ -1,17 +1,24 @@ autocmd FileType go - \ :iabbrev err@ if err != nil {} + \ :iabbrev err@ if err != nil {} autocmd FileType go - \ :iabbrev hand@ ^ifunc A(c *gin.Context) { + \ :iabbrev h@ ^ifunc A(c *gin.Context) {} autocmd FileType go - \ :iabbrev test@ ^ifunc A(t *testing.T) { + \ :iabbrev t@ ^ifunc A(t *testing.T) {} + +autocmd FileType go + \ :iabbrev f@ ^ifunc A() {}f(li autocmd FileType go \ :iabbrev fat@ log.Fatal(" %v", err)F%i -:autocmd FileType php,html.twig,html,javascript,typescript,vue,go +:autocmd FileType go + \ :iabbrev if@ if {}%i + + +:autocmd FileType php,html.twig,html,javascript,typescript,vue \ :iabbrev if@ if() {}%i -- cgit v1.2.3