Managing VSCode Profiles for the Polyglot Developers
Tags: vscode, tutorial, productivity, tips
Published: 2020-06-07 11:06:58

![Programming languages meme](https://dev-to-uploads.s3.amazonaws.com/i/ev1gvv6xlsy3eypvyqzx.png)
> Image credit: https://programmerhumour.tumblr.com/post/187131622245/javascript-mocking-joke-645342

If you use multiple programming languages in your daily life, you probably need numerous extensions which target specific programming languages.

I use Go, Node.js, Python (sometimes), Rust and since one month, Deno. I need ESLint for Node, Go Extension for Golang, RLS for Rust and so on.

My laptop is 10 years old and it's getting slower every day so as my vscode profile. It is bloated with extensions. Think of getting minimum 3 extensions for every language you write! So what's the solution? If you don't like to hack stuff like I do, search for an extension that can help with this issue (look at the irony here). But if you're like me, the solution is **VSCode Profiles!**

***Note:*** Some steps are taken from https://dev.to/jsjoeio/how-to-create-code-profiles-in-vscode-3ofo - Check out this amazing post too!

## First, create the root of profiles directory by pasting following line to your terminal
```bash
cd $HOME && mkdir code-profiles && cd code-profiles
```
You've probably know what the above line does but here's the explanation for those who don't: It navigates to your home directory (of your current terminal user) and creates a directory then it navigates into it.

## Second, prepare the profile directory for the language you'll work with
It can be anything, I can't force you to work with a specific language or a tool 😄, but as an example I'll go with Deno.
```bash
mkdir deno
cd deno
mkdir data extensions
```

## (Optional) Copy your settings file
If you want to keep your current settings, open `settings.json` in VSCode and copy your settings. Then while in the `deno` directory we've just created:
```bash
cd data
mkdir User
nano settings.json
```
And paste the content of `settings.json`.

## Making our lives easier, adding an alias!
Actually this step is optional too but I strongly recomment it or you'll have to write two paths and two flags each time you want to open your profile.
```bash
cd $HOME
# I'll open my bashrc file because I'm using linux with bash but other shells are similar too
nano .bashrc
```
And at the end of the file add this:
```bash
alias code-deno="code --user-data-dir ~/code-profiles/deno/data/ --extensions-dir ~/code-profiles/deno/extensions/"
```
Save and close it.

Then restart your terminal or source your bashrc file:
```bash
source .bashrc
```

## Voila!
```
code-deno
```
You now have a vscode profile for Deno with extensions specific to it! When you want to code with another PL just repeat the same steps for that language, and you'll have a fresh VSCode without bloated with extensions!

### References
[How to Create Code Profiles in VSCode ](https://dev.to/jsjoeio/how-to-create-code-profiles-in-vscode-3ofo "How to Create Code Profiles in VSCode ")
[Managing Extensions in Visual Studio Code](https://code.visualstudio.com/docs/editor/extension-gallery#_command-line-extension-management "Managing Extensions in Visual Studio Code")