-
Notifications
You must be signed in to change notification settings - Fork 37.4k
Closed
Labels
feature-requestRequest for new features or functionalityRequest for new features or functionalitygood first issueIssues identified as good for first-time contributorsIssues identified as good for first-time contributorshelp wantedIssues identified as good community contribution opportunitiesIssues identified as good community contribution opportunitiesrelease-notesRelease notes issuesRelease notes issuessnippetsverification-neededVerification of issue is requestedVerification of issue is requestedverifiedVerification succeededVerification succeeded
Milestone
Description
We have several of the same snippets in our snippets json:
"Function-Advanced": {
"prefix": "function-advanced",
"body": [
"function ${1:Verb-Noun} {",
"\t[CmdletBinding()]",
"\tparam (",
"\t\t$0",
"\t)",
"\t",
"\tbegin {",
"\t}",
"\t",
"\tprocess {",
"\t}",
"\t",
"\tend {",
"\t}",
"}"
],
"description": "Script advanced function definition snippet"
},
"Cmdlet": {
"prefix": "cmdlet",
"body": [
"function ${1:Verb-Noun} {",
"\t[CmdletBinding()]",
"\tparam (",
"\t\t$0",
"\t)",
"\t",
"\tbegin {",
"\t}",
"\t",
"\tprocess {",
"\t}",
"\t",
"\tend {",
"\t}",
"}"
],
"description": "Script cmdlet definition snippet"
},This could be avoided by supporting an array of prefixes like so:
"Cmdlet": {
"prefix": ["function-advanced", "cmdlet"], // <--- here
"body": [
"function ${1:Verb-Noun} {",
"\t[CmdletBinding()]",
"\tparam (",
"\t\t$0",
"\t)",
"\t",
"\tbegin {",
"\t}",
"\t",
"\tprocess {",
"\t}",
"\t",
"\tend {",
"\t}",
"}"
],
"description": "Script cmdlet definition snippet"
}It'd help slim down snippet json files and support snippets that might go by different names.
reyalpsirc, timoline, jaceglassbrook, mishschmid, McPrescott and 23 more
Metadata
Metadata
Assignees
Labels
feature-requestRequest for new features or functionalityRequest for new features or functionalitygood first issueIssues identified as good for first-time contributorsIssues identified as good for first-time contributorshelp wantedIssues identified as good community contribution opportunitiesIssues identified as good community contribution opportunitiesrelease-notesRelease notes issuesRelease notes issuessnippetsverification-neededVerification of issue is requestedVerification of issue is requestedverifiedVerification succeededVerification succeeded