Skip to content
This repository has been archived by the owner on Jul 15, 2023. It is now read-only.

Commit

Permalink
add snippets for main and init functions (#602)
Browse files Browse the repository at this point in the history

* fixed var naming
  • Loading branch information
marklap authored and ramya-rao-a committed Nov 9, 2016
1 parent 786abb6 commit a0bd14e
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion snippets/go.json
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,18 @@
"test function": {
"prefix": "tf",
"body": "func Test$1(t *testing.T) {\n\t$0\n}"
},
"init function": {
"prefix": "finit",
"body": "func init() {\n\t$1\n}"
},
"main function": {
"prefix": "fmain",
"body": "func main() {\n\t$1\n}"
},
"method declaration": {
"prefix": "meth",
"body": "func (${1:receiver} ${2:type}) ${3:method}($4) $5 {\n\t$0\n}"
}
}
}
}

0 comments on commit a0bd14e

Please sign in to comment.