Skip to content

Commit bc07391

Browse files
author
alexanderwoehler
committed
fix(snippets): add missing "then" to existence checks
1 parent 81125b8 commit bc07391

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

server/src/snippets.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -153,14 +153,14 @@ export const SNIPPETS: BashCompletionItem[] = [
153153
{
154154
label: 'if-defined',
155155
documentation: 'if with variable existence check',
156-
insertText: ['if [[ -n "${${1:variable}+x}" ]]', '\t${2:command ...}', 'fi'].join(
156+
insertText: ['if [[ -n "${${1:variable}+x}" ]]; then', '\t${2:command ...}', 'fi'].join(
157157
'\n',
158158
),
159159
},
160160
{
161161
label: 'if-not-defined',
162162
documentation: 'if with variable existence check',
163-
insertText: ['if [[ -z "${${1:variable}+x}" ]]', '\t${2:command ...}', 'fi'].join(
163+
insertText: ['if [[ -z "${${1:variable}+x}" ]]'; then, '\t${2:command ...}', 'fi'].join(
164164
'\n',
165165
),
166166
},

0 commit comments

Comments
 (0)