Skip to content

Commit ab3a927

Browse files
committed
only install extensions if inside a docker container
1 parent a68d1e2 commit ab3a927

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

.vscode/tasks.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@
140140
"label": "Install All Recommended Extensions",
141141
"type": "shell",
142142
"linux": {
143-
"command": "cat .vscode/extensions.json | jq .recommendations[] | xargs -n 1 code . --install-extension"
143+
"command": "if [ -f /.dockerenv ] || grep -q 'docker\\|lxc' /proc/1/cgroup 2>/dev/null; then echo 'Docker container detected, installing extensions...'; cat .vscode/extensions.json | jq .recommendations[] | xargs -n 1 code . --install-extension; else echo 'Not in Docker container, skipping extension installation'; fi"
144144
},
145145
"runOptions": {
146146
"runOn": "folderOpen"

0 commit comments

Comments
 (0)