From cf0343df52ac99e47fbb4291097d7f0701239ccf Mon Sep 17 00:00:00 2001 From: Kyle Carberry Date: Tue, 19 Sep 2023 13:20:55 -0500 Subject: [PATCH] Fix code-server without extensions --- README.md | 23 +++++++++++++++++++++-- code-server/run.sh | 3 +++ 2 files changed, 24 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index a78fbc7..c84593f 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,25 @@ -# Modules +
+

+ Modules +

-Modules extend Workspaces to provide self-contained building-blocks on your development environment. +[Registry](https://registry.coder.com) | [Coder Docs](https://coder.com/docs) | [Why Coder](https://coder.com/why) | [Coder Enterprise](https://coder.com/docs/v2/latest/enterprise) + +[![discord](https://img.shields.io/discord/747933592273027093?label=discord)](https://discord.gg/coder) +[![license](https://img.shields.io/github/license/coder/modules)](./LICENSE) + +
+ +Modules extend Templates to create reusable components for your development environment. + +e.g. + +```hcl +module "code-server" { + source = "https://registry.coder.com/modules/code-server" + agent_id = coder_agent.main.id +} +``` - [code-server](https://registry.coder.com/modules/code-server): Install on start, create an app to access via the dashboard, install extensions, and pre-configure editor settings. - [personalize](https://registry.coder.com/modules/personalize): Run a script on workspace start that allows developers to run custom commands to personalize their workspace. diff --git a/code-server/run.sh b/code-server/run.sh index ae75193..116af8c 100755 --- a/code-server/run.sh +++ b/code-server/run.sh @@ -17,6 +17,9 @@ CODE_SERVER="${INSTALL_PREFIX}/bin/code-server" # Install each extension... for extension in "$${EXTENSIONS[@]}"; do + if [ -z "$extension" ]; then + continue + fi printf "🧩 Installing extension $${CODE}$extension$${RESET}...\n" output=$($CODE_SERVER --install-extension "$extension") if [ $? -ne 0 ]; then