We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
In some cases auto_install_extensions won't if the workspace has not been checkout yet.
auto_install_extensions
Ideally coder should provide a method to wait on a dependent task from completing.
A work around is to poll for the folder to be created before running the install like so.
if [ "${AUTO_INSTALL_EXTENSIONS}" = true ]; then if ! command -v jq > /dev/null; then echo "jq is required to install extensions from a workspace file." exit 0 fi WORKSPACE_DIR="$HOME" if [ -n "${FOLDER}" ]; then WORKSPACE_DIR="${FOLDER}" fi TIMEOUT=10 INTERVAL=1 ELAPSED=0 while [ $ELAPSED -lt $TIMEOUT ]; do if [ -d "$WORKSPACE_DIR" ]; then echo "Directory $WORKSPACE_DIR exists." break fi sleep $INTERVAL ELAPSED=$((ELAPSED + INTERVAL)) done if [ -f "$WORKSPACE_DIR/.vscode/extensions.json" ]; then printf "🧩 Installing extensions from %s/.vscode/extensions.json...\n" "$WORKSPACE_DIR" extensions=$(jq -r '.recommendations[]' "$WORKSPACE_DIR"/.vscode/extensions.json) for extension in $extensions; do if extension_installed "$extension"; then continue fi $CODE_SERVER "$EXTENSION_ARG" --force --install-extension "$extension" done fi fi
The text was updated successfully, but these errors were encountered:
No branches or pull requests
In some cases
auto_install_extensions
won't if the workspace has not been checkout yet.Ideally coder should provide a method to wait on a dependent task from completing.
A work around is to poll for the folder to be created before running the install like so.
The text was updated successfully, but these errors were encountered: