mirror of
https://github.com/natelandau/shell-scripting-templates.git
synced 2025-11-10 14:13:45 -05:00
Update vscode snippets
This commit is contained in:
40
.vscode/shellscript.code-snippets
vendored
40
.vscode/shellscript.code-snippets
vendored
@@ -9,7 +9,7 @@
|
|||||||
// "Print to console": {
|
// "Print to console": {
|
||||||
// "scope": "javascript,typescript",
|
// "scope": "javascript,typescript",
|
||||||
// "prefix": "log",
|
// "prefix": "log",
|
||||||
// "body": [
|
// "body":
|
||||||
// "console.log('$1');",
|
// "console.log('$1');",
|
||||||
// "$2"
|
// "$2"
|
||||||
// ],
|
// ],
|
||||||
@@ -19,18 +19,17 @@
|
|||||||
"scope": "shellscript",
|
"scope": "shellscript",
|
||||||
"prefix": "_c",
|
"prefix": "_c",
|
||||||
"body": [
|
"body": [
|
||||||
"# DESC:",
|
"\t\t# DESC:",
|
||||||
"#\t\t\t\t\t$1",
|
"\t\t#\t\t\t\t\t$1",
|
||||||
"# ARGS:",
|
"\t\t# ARGS:",
|
||||||
"#\t\t\t\t\t$2",
|
"\t\t#\t\t\t\t\t\\$1 (Required):\t",
|
||||||
"# OUTS:",
|
"\t\t#\t\t\t\t\t\\$2 (Optional):\t",
|
||||||
"#\t\t\t\t\t0 - Success",
|
"\t\t# OUTS:",
|
||||||
"#\t\t\t\t\t1 - Failure",
|
"\t\t#\t\t\t\t\t\t\t 0: Success",
|
||||||
"#\t\t\t\t\tstdout: $4",
|
"\t\t#\t\t\t\t\t\t\t 1: Failure",
|
||||||
"# USAGE:",
|
"\t\t#\t\t\t\t\tstdout: ",
|
||||||
"#\t\t\t\t\t$4",
|
"\t\t# USAGE:",
|
||||||
"# NOTES:",
|
"\t\t#\t\t\t\t\t_nameOfFunc_ \"@\""
|
||||||
"#\t\t\t\t\t$5"
|
|
||||||
],
|
],
|
||||||
"description": "Comment block for a function"
|
"description": "Comment block for a function"
|
||||||
},
|
},
|
||||||
@@ -54,18 +53,17 @@
|
|||||||
"\t\t# DESC:",
|
"\t\t# DESC:",
|
||||||
"\t\t#\t\t\t\t\t$2",
|
"\t\t#\t\t\t\t\t$2",
|
||||||
"\t\t# ARGS:",
|
"\t\t# ARGS:",
|
||||||
"\t\t#\t\t\t\t\t$3",
|
"\t\t#\t\t\t\t\t\\$1 (Required):\t",
|
||||||
|
"\t\t#\t\t\t\t\t\\$2 (Optional):\t",
|
||||||
"\t\t# OUTS:",
|
"\t\t# OUTS:",
|
||||||
"\t\t#\t\t\t\t\t0 - Success",
|
"\t\t#\t\t\t\t\t\t\t 0: Success",
|
||||||
"\t\t#\t\t\t\t\t1 - Failure",
|
"\t\t#\t\t\t\t\t\t\t 1: Failure",
|
||||||
"\t\t#\t\t\t\t\tstdout: $4",
|
"\t\t#\t\t\t\t\tstdout: ",
|
||||||
"\t\t# USAGE:",
|
"\t\t# USAGE:",
|
||||||
"\t\t#\t\t\t\t\t_${1:name}_ ",
|
"\t\t#\t\t\t\t\t${1:name} \"@\"",
|
||||||
"\t\t# NOTES:",
|
|
||||||
"\t\t#\t\t\t\t\t$5",
|
|
||||||
"\t\t",
|
"\t\t",
|
||||||
"\t\t [[ $# == 0 ]] && fatal \"Missing required argument to ${FUNCNAME[0]}\"",
|
"\t\t [[ $# == 0 ]] && fatal \"Missing required argument to ${FUNCNAME[0]}\"",
|
||||||
"\t\t$6",
|
"\t\t",
|
||||||
"}"
|
"}"
|
||||||
],
|
],
|
||||||
"description": "Add a new function"
|
"description": "Add a new function"
|
||||||
|
|||||||
Reference in New Issue
Block a user