Skip to content

Commit d2b29e8

Browse files
authored
feat: add snippets for most basic terraform blocks (rafamadriz#426)
* feat: add basic terraform snippets * fix: remove periods in placeholder text
1 parent 72227f5 commit d2b29e8

File tree

1 file changed

+40
-0
lines changed

1 file changed

+40
-0
lines changed

snippets/terraform.json

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6944,5 +6944,45 @@
69446944
" }",
69456945
"}"
69466946
]
6947+
},
6948+
"data_source": {
6949+
"prefix": "data",
6950+
"description": "Define a data source",
6951+
"body": [
6952+
"data \"${data_source_type}\" \"${data_source_name}\" {",
6953+
" ${value} = \"${identifier}\"",
6954+
"}"
6955+
]
6956+
},
6957+
"input_variable": {
6958+
"prefix": "input",
6959+
"description": "Define an input variable",
6960+
"body": [
6961+
"variable \"${name}\" {",
6962+
" type = \"${type}\"",
6963+
" description = \"${description}\"",
6964+
" default = \"${default_value}\"",
6965+
"}"
6966+
]
6967+
},
6968+
"output_variable": {
6969+
"prefix": "output",
6970+
"description": "Define an output value",
6971+
"body": [
6972+
"output \"${output_name}\" {",
6973+
" value = ${resource_name_attribute}",
6974+
" description = ${description}",
6975+
"}"
6976+
]
6977+
},
6978+
"resource": {
6979+
"prefix": [ "resource", "res" ],
6980+
"description": "basic resource definition",
6981+
"body": [
6982+
"resource \"${resource_type}\" \"${resource_name}\" {",
6983+
" ${field} = \"${value}\"",
6984+
"}"
6985+
6986+
]
69476987
}
69486988
}

0 commit comments

Comments
 (0)