Skip to content

Sharing my approach to use VSCode Settings Sync and official extension market #148

@LER0ever

Description

@LER0ever

First, thanks for this great project, this is much easier to use than Che and Theia

Two problems I've come across during my day of use are

  • Extensions are cached and installed from Coder's server, most of which for now are outdated
  • Cannot Sync settings with VSCode

My approach

So I made a Docker template to automatically configure code-server from Settings Sync Gist.

Using Docker's multi-stage build, I can directly use the actual Visual Studio Code binary to install extensions from Microsoft's server, and then later copy them to code-server. And VSCode settings are also directly fed into code-server.

extensions.json parsing and installing

Is done the UNIX way.

jq -r ".[].metadata.publisherId" extensions.json > extensions.list
while IFS='' read -r line || [[ -n "$line" ]]; do
    echo "Installing $line using VSCode";
    code --user-data-dir /root/.config/Code --install-extension $line
done < "$1" # extensions.list

For those of you who already use Settings Sync, my configuration might be handy as you only need to change the gist id to make the entire thing work.

Relevant Issues: #30 #145
My template: https://github.com/LER0ever/EvDev

Screenshot, almost the same as my VSCode:
image

Metadata

Metadata

Assignees

No one assigned

    Labels

    docsDocumentation related

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions