DEV Community

Cover image for Linux development setup on non-Linux environment (with VSCode)
hiro
hiro

Posted on

Linux development setup on non-Linux environment (with VSCode)

Hello Windows and macOS users!

Have you ever thought about learning C/C++, or low level programming in other languages? Perhaps you've even bought a book, or explored related blogs, only to discover at the end of the day that the resources you've gathered are tailored exclusively for Linux.

"Oh... this only works for Linux..."

Now, you're faced with several options. The most costly one would be investing in dedicated hardware to fulfill your programming desire. Alternatively, you could set up a Linux virtual machine on your computer or explore cloud-based solutions, among other possibilities.

Developing Inside a Container

Or, you can create a Linux container and bind your local folder on your computer to the container, which is for free, and probably the fastest way to achieve it (if your choice of text editor is Visual Studio Code).

(It should work on Windows using the same way I haven't tried it though)

Prerequisite

  • Visual Studio Code
  • and Docker Desktop

Steps

  1. Start Docker Desktop (if you didn't)
  2. Install Dev Containers extension
  3. In your VSCode, click "Open a remote window" button on the bottom left
  4. Click "New Dev Container". Then select the language of your choice (for example, 'Go'). This will build a new Linux container for your development.
  5. Be patient until it's ready (it probably takes a few minutes...)

After finishing the steps above, you will see your dev container is up and running now!

Links

Thanks for reading ✌️

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

Top comments (0)

The Most Contextual AI Development Assistant

Pieces.app image

Our centralized storage agent works on-device, unifying various developer tools to proactively capture and enrich useful materials, streamline collaboration, and solve complex problems through a contextual understanding of your unique workflow.

👥 Ideal for solo developers, teams, and cross-company projects

Learn more

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay