Skip to content

Commit

Permalink
sync fork upstream Oct 15, 2018 last
Browse files Browse the repository at this point in the history
  • Loading branch information
avelino committed Feb 25, 2019
1 parent 375419e commit 5088752
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions snippets/go.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@

{
".source.go": {
"single import": {
Expand Down Expand Up @@ -50,6 +51,11 @@
"body": "switch ${1:expression} {\ncase ${2:condition}:\n\t$0\n}",
"description": "Snippet for switch statement"
},
"select statement": {
"prefix": "sel",
"body": "select {\ncase ${1:condition}:\n\t$0\n}",
"description": "Snippet for select statement"
},
"case clause": {
"prefix": "cs",
"body": "case ${1:condition}:$0",
Expand All @@ -62,7 +68,7 @@
},
"for range statement": {
"prefix": "forr",
"body": "for ${1:var} := range ${2:var} {\n\t$0\n}",
"body": "for ${1:_, }${2:var} := range ${3:var} {\n\t$0\n}",
"description": "Snippet for a for range loop"
},
"channel declaration": {
Expand Down Expand Up @@ -97,7 +103,7 @@
},
"if err != nil": {
"prefix": "iferr",
"body": "if err != nil {\n\t${1:return}\n}",
"body": "if err != nil {\n\t${1:return ${2:nil, }${3:err}}\n}",
"description": "Snippet for if err != nil"
},
"fmt.Println": {
Expand Down Expand Up @@ -246,4 +252,4 @@
"description": "Snippet for sample hello world webapp"
}
}
}
}

0 comments on commit 5088752

Please sign in to comment.