aboutsummaryrefslogtreecommitdiff
path: root/template
diff options
context:
space:
mode:
Diffstat (limited to 'template')
-rw-r--r--template/go/pattern.stpl7
1 files changed, 7 insertions, 0 deletions
diff --git a/template/go/pattern.stpl b/template/go/pattern.stpl
index 8bfb8b8..db46c5d 100644
--- a/template/go/pattern.stpl
+++ b/template/go/pattern.stpl
@@ -16,3 +16,10 @@
\(\S\+\)\.log$
log.Println({{$1}})
{{_cursor_}}
+
+\(\S\+\)\.close$
+ defer {{$1}}.Close()
+ {{_cursor_}}
+
+\(\S\+\)\.query$
+ {{$1}}.Query("{{_cursor_}}")