VS Codium tutorial

VS Codium tutorial VS Codium tutorial.md

VS Codium tutorial

Versione italiana

VS Codium è una versione libera e open-source di Visual Studio Code (VS Code), l'editor di codice sviluppato da Microsoft. La differenza principale è che VS Codium rimuove il tracciamento e i componenti proprietari presenti in VS Code, rendendolo una scelta popolare tra gli sviluppatori che preferiscono software completamente open-source.

Ecco una guida completa su come iniziare con VS Codium, dalle installazioni alle funzionalità avanzate.


1. Installazione di VS Codium

Su Windows

  1. Vai al sito ufficiale di VS Codium: https://vscodium.com/.
  2. Scarica il file di installazione per Windows (.exe).
  3. Esegui il file di installazione e segui le istruzioni.

Su macOS

  1. Vai al sito ufficiale di VS Codium.
  2. Scarica il file .dmg per macOS.
  3. Apri il file .dmg e trascina l'icona di VS Codium nella cartella "Applicazioni".

Su Linux

  • Debian/Ubuntu:
    1. Scarica il file .deb dal sito ufficiale.
    2. Installa usando il comando:
      sudo apt install ./nome-file.deb
  • Fedora/RHEL:
    1. Scarica il file .rpm.
    2. Installa usando:
      sudo dnf install ./nome-file.rpm
  • Altri metodi:
    • Puoi anche usare Snap o Flatpak:
      sudo snap install codium --classic
      Oppure:
      flatpak install flathub com.vscodium.codium

2. Configurazione iniziale

Interfaccia utente

  • L'interfaccia di VS Codium è identica a quella di VS Code. È composta da:
    • Sidebar: Contiene esplora file, ricerca, estensioni, ecc.
    • Editor: Area principale per scrivere codice.
    • Terminale integrato: Accessibile tramite Ctrl + `` (o Cmd + `` su macOS).

Temi e personalizzazione

  • Puoi cambiare il tema dell'editor:
    1. Vai su File > Preferenze > Tema colore.
    2. Scegli tra i temi predefiniti o installane di nuovi tramite estensioni.
  • Personalizza la barra laterale, la barra di stato e i menu tramite File > Preferenze > Impostazioni.

Impostazioni sincronizzate

  • Se vuoi sincronizzare le impostazioni tra più dispositivi, puoi usare estensioni come Settings Sync (disponibile anche per VS Codium).

3. Estensioni

Installazione delle estensioni

  1. Apri il pannello delle estensioni cliccando sull'icona delle estensioni nella sidebar o premendo Ctrl + Shift + X.
  2. Cerca l'estensione che ti interessa e clicca su "Installa".

Estensioni consigliate

  • Python: Supporto per il linguaggio Python (debugging, linting, formattazione).
  • Pylance: Analisi del codice Python.
  • GitLens: Integrazione avanzata con Git.
  • Prettier: Formattazione automatica del codice.
  • Live Server: Server di sviluppo per HTML/CSS/JavaScript.
  • Docker: Supporto per Docker.
  • Remote - SSH: Sviluppo remoto su server SSH.

4. Funzionalità avanzate

Terminale integrato

  • Puoi aprire un terminale integrato direttamente in VS Codium premendo `Ctrl + ``.
  • Supporta PowerShell, Bash, Zsh, ecc., a seconda del sistema operativo.

Debugging

  • VS Codium include un potente debugger integrato.
    1. Apri un file di codice.
    2. Imposta i breakpoint cliccando a sinistra dei numeri di riga.
    3. Avvia il debugger premendo F5 o cliccando su Esegui > Avvia debug.

Controllo di versione con Git

  • VS Codium ha un'integrazione nativa con Git.
    1. Apri una cartella con un repository Git.
    2. Usa la sidebar "Source Control" (Ctrl + Shift + G) per gestire commit, push e pull.

Sviluppo remoto

  • Puoi usare estensioni come Remote - SSH o Remote - Containers per sviluppare su macchine remote o dentro container Docker.

5. Suggerimenti e scorciatoie

Scorciatoie comuni

  • Ctrl + N: Nuovo file.
  • Ctrl + O: Apri file.
  • Ctrl + S: Salva file.
  • Ctrl + Shift + P: Apri la palette dei comandi.
  • Ctrl + F: Cerca nel file.
  • Ctrl + Shift + F: Cerca in tutti i file.
  • Ctrl + /: Commenta/rimuovi commento.
  • Alt + ↑/↓: Sposta una riga di codice su/giù.

Snippet di codice

  • Puoi creare snippet personalizzati per velocizzare la scrittura del codice:
    1. Vai su File > Preferenze > Snippet utente.
    2. Scegli il linguaggio e definisci il tuo snippet.

6. Personalizzazione avanzata

File di configurazione

  • VS Codium utilizza file JSON per le impostazioni (settings.json) e i comandi (keybindings.json).
  • Puoi modificarli manualmente aprendo la palette dei comandi (Ctrl + Shift + P) e cercando "Apri impostazioni (JSON)".

Estensioni personalizzate

  • Se hai bisogno di funzionalità specifiche, puoi cercare estensioni sul Marketplace di VS Code e installarle manualmente in VS Codium.

7. Differenze tra VS Code e VS Codium

  • Licenza: VS Codium è completamente open-source, mentre VS Code contiene componenti proprietari.
  • Telemetria: VS Codium non invia dati di telemetria a Microsoft.
  • Estensioni: Alcune estensioni proprietarie potrebbero non funzionare in VS Codium, ma la maggior parte sono compatibili.

8. Risorse utili

English version

VS Codium tutorial

VS Codium is a free and open-source version of Visual Studio Code (VS Code), the code editor developed by Microsoft. The main difference is that VS Codium removes the tracing and proprietary components present in VS Code, making it a popular choice among developers who prefer fully open-source software.

Here is a complete guide on how to get started with VS Codium, from installations to advanced features.


1. Installing VS Codium

On Windows

  1. Go to the official VS Codium website: https://vscodium.com/.
  2. Download the Windows installation file (.exe).
  3. Run the installation file and follow the instructions.

On macOS

  1. Go to the official VS Codium website.
  2. Download the macOS .dmg file.
  3. Open the .dmg file and drag the VS Codium icon to the "Applications" folder.

On Linux

  • Debian/Ubuntu:
  1. Download the .deb file from the official website.
  2. Install using the command:
sudo apt install ./filename.deb
  • Fedora/RHEL:
  1. Download the .rpm file.
  2. Install using:
sudo dnf install ./filename.rpm
  • Other methods:
  • You can also use Snap or Flatpak:
sudo snap install codium --classic

Or:

flatpak install flathub com.vscodium.codium

2. Initial setup

User interface

  • The interface of VS Codium is identical to that of VS Code. It consists of:
  • Sidebar: Contains file explorer, search, extensions, etc.
  • Editor: Main area for writing code.
  • Integrated terminal: Accessible via Ctrl + `` (or Cmd + `` on macOS).

Themes and customization

  • You can change the theme of the editor:
  1. Go to File > Preferences > Color theme.
  2. Choose from the predefined themes or install new ones via extensions.
  • Customize the sidebar, status bar and menus via File > Preferences > Settings.

Synchronized settings

  • If you want to sync settings between multiple devices, you can use extensions like Settings Sync (also available for VS Codium).

3. Extensions

Installing Extensions

  1. Open the Extensions panel by clicking on the Extensions icon in the sidebar or by pressing Ctrl + Shift + X.
  2. Find the extension you want and click "Install".
  • Python: Python language support (debugging, linting, formatting).
  • Pylance: Python code analysis.
  • GitLens: Advanced Git integration.
  • Prettier: Automatic code formatting.
  • Live Server: HTML/CSS/JavaScript development server.
  • Docker: Docker support.
  • Remote - SSH: Remote development on SSH server.

4. Advanced Features

Integrated Terminal

  • You can open an integrated terminal directly in VS Codium by pressing `Ctrl + ``.
  • It supports PowerShell, Bash, Zsh, etc., depending on your operating system.

Debugging

  • VS Codium includes a powerful integrated debugger.
  1. Open a code file.
  2. Set breakpoints by clicking to the left of line numbers.
  3. Start the debugger by pressing F5 or clicking Run > Start Debugging.

Version Control with Git

  • VS Codium has a native integration with Git.
  1. Open a folder with a Git repository.
  2. Use the "Source Control" sidebar (Ctrl + Shift + G) to manage commits, pushes and pulls.

Remote Development

  • You can use extensions like Remote - SSH or Remote - Containers to develop on remote machines or inside Docker containers.

5. Tips and Shortcuts

Common Shortcuts

  • Ctrl + N: New file.
  • Ctrl + O: Open file.
  • Ctrl + S: Save file.
  • Ctrl + Shift + P: Open the command palette.
  • Ctrl + F: Search in file.
  • Ctrl + Shift + F: Search in all files.
  • Ctrl + /: Comment/uncomment.
  • Alt + ↑/↓: Move a line of code up/down.

Code Snippets

  • You can create custom snippets to speed up your code writing:
  1. Go to File > Preferences > User Snippets.
  2. Choose the language and define your snippet.

6. Advanced customization

Configuration files

  • VS Codium uses JSON files for settings (settings.json) and commands (keybindings.json).
  • You can edit them manually by opening the command palette (Ctrl + Shift + P) and searching for "Open settings (JSON)".

Custom extensions

  • If you need specific functionality, you can search for extensions on the VS Code Marketplace and install them manually in VS Codium.

7. Differences between VS Code and VS Codium

  • License: VS Codium is completely open-source, while VS Code contains proprietary components.
  • Telemetry: VS Codium does not send telemetry data to Microsoft.
  • Extensions: Some proprietary extensions may not work in VS Codium, but most are compatible.

8. Useful resources

Commenti