Getting Started with VS Code
Purpose and Scope
This page gives a first-run path for developers who are new to Visual Studio Code and want to become productive without treating the editor, terminal, command line, extensions, source control, and AI assistance as separate products. The official user journey starts by opening a folder or workspace, learning the Command Palette, reviewing settings, and using the integrated terminal to run commands in the same context as the editor. In this repository slice, that journey is grounded most directly in the terminal suggestion extension, which teaches the shell about VS Code commands such as code, code-insiders, code-tunnel, and code-tunnel-insiders.
Sources: extensions/terminal-suggest/src/completions/code.ts, extensions/terminal-suggest/src/completions/code-insiders.ts, extensions/terminal-suggest/src/completions/code-tunnel.ts, extensions/terminal-suggest/src/completions/code-tunnel-insiders.ts
The important idea for a new user is that VS Code is both an editor and a tool hub. You edit files in windows and workspaces, but you also run build tools, Git commands, language servers, cloud CLIs, and helper commands from inside the integrated terminal. The completion specs in this page do not implement the full workbench UI, but they show how VS Code exposes a first-class command-line contract to terminal users. That contract includes opening folders, comparing files, merging conflicts, navigating to exact file locations, managing extensions, collecting troubleshooting output, and connecting to remote tunnel workflows.
Core Primitives
A workspace is the set of one or more folders opened in a VS Code window. Most first runs begin with a single folder, but the command-line options include --add to add folders to the last active window and --remove to remove folders from it. A window is the visible workbench instance where editors, side-bar views, the panel, and the terminal live. The code command can force a new window with --new-window, reuse an existing one with --reuse-window, or wait for files to close with --wait, which is useful when another tool launches VS Code as an editor.
Sources: extensions/terminal-suggest/src/completions/code.ts
The Command Palette is the interactive command surface for discovering VS Code functionality, while the integrated terminal is the shell surface for running external commands. The terminal getting-started flow recommends opening a folder, opening the terminal with the menu or keyboard shortcut, and running a simple command such as ls. The repository evidence here complements that flow by defining completion metadata for the code family of commands. That metadata makes the terminal smarter about VS Code-specific arguments, file path templates, folder path templates, locale suggestions, and remote tunnel options.
Sources: extensions/terminal-suggest/src/completions/code.ts, extensions/terminal-suggest/src/fig/api-bindings/types.ts, extensions/terminal-suggest/src/fig/autocomplete/fig/hooks.ts
AI assistance is another core primitive in the current VS Code user journey. Official docs describe chat, Agent mode, slash commands such as /newNotebook, inline chat, and context references in notebook prompts. These features sit above the editor and workspace model: you still open a folder, edit files, review generated changes, and run commands in the terminal. For a first run, treat AI as an assistant attached to your existing workflow rather than a replacement for it: ask it to scaffold, explain, or edit, then use the editor, source control, terminal, and tests to verify the result.
Relevant Source Files
extensions/terminal-suggest/src/completions/code.ts— Defines the shared completion model for thecodecommand, including workspace/window options, file navigation, diff and merge helpers, locale selection, user data directories, profiles, extension management groups, troubleshooting groups, and tunnel-related exports used by sibling specs.extensions/terminal-suggest/src/completions/code-insiders.ts— Reuses the stablecodecompletion model for thecode-insidersexecutable and selects common, extension-management, and troubleshooting options for the Insiders build.extensions/terminal-suggest/src/completions/code-tunnel.ts— Defines thecode-tunnelcompletion spec and tunnel-specific options such as CLI data storage, log levels, telemetry controls, verbose output, and help.extensions/terminal-suggest/src/completions/code-tunnel-insiders.ts— Combines tunnel subcommands and options for the Insiders tunnel executable, including shared tunnel, extension-management, and troubleshooting groups.extensions/terminal-suggest/src/fig/api-bindings/types.ts— Describes shell context data available to completion logic, including the current process, working directory, terminal session, shell path, hostname, exported environment variables, and aliases.extensions/terminal-suggest/src/fig/autocomplete/fig/hooks.ts— Defines the runtime completion state used by Fig-style hooks, including buffer text, cursor location, current working directory, process context, SSH context, aliases, environment variables, and optional shell context.
First-Run Workflow
Start with a folder because many VS Code features become more useful when the editor knows the project root. From the desktop UI, use the file menu to open a folder. From a shell, run code . in the project directory. Once the folder is open, use the Command Palette for discovery and the terminal for commands. The code completion spec models common shell entry points such as reading from stdin with -, opening a file at a line and character with --goto, comparing two files with --diff, and performing a three-way merge with --merge.
Sources: extensions/terminal-suggest/src/completions/code.ts
Next, connect editing to verification. Use the integrated terminal for build, test, package manager, or Git commands while staying in the same workspace. When command output prints file paths or URLs, the terminal can make them actionable in the editor experience described by the official terminal docs. The completion binding types show why context matters: a completion request can know the current working directory, shell path, hostname, exported environment variables, aliases, and process information. That information lets terminal suggestions match the command being typed and the environment where it will run.
Sources: extensions/terminal-suggest/src/fig/api-bindings/types.ts, extensions/terminal-suggest/src/fig/autocomplete/fig/hooks.ts
After you are comfortable opening folders and running commands, add extensions for the technologies you use. The official Azure getting-started flow, for example, installs the Azure Tools extension pack, opens the Azure Resources view from the Activity Bar, signs in, and uses the Command Palette to search Azure commands. The code and tunnel completion specs include extension-management option groups, which is a useful reminder that extensions are not only managed from the Extensions view; the command line also participates in installing, listing, and troubleshooting extension-based workflows.
Sources: extensions/terminal-suggest/src/completions/code.ts, extensions/terminal-suggest/src/completions/code-tunnel.ts
Terminal and CLI Reference
The code command is the most important command-line entry point for a first-run user. Use it to open the current folder, open a specific file, compare files, merge conflicts, or control which window receives the request. The completion spec exposes --user-data-dir for separate user data, --profile for opening a folder or workspace with a named profile, and --locale with suggested locale identifiers such as en, zh-CN, fr, de, ja, and pt-br. Those options are advanced, but they matter when you want reproducible environments, multiple isolated instances, or localized UI behavior.
Sources: extensions/terminal-suggest/src/completions/code.ts
| Command surface | First-run use | Source-backed options |
|---|---|---|
code | Open folders, files, diffs, merges, profiles, and windows | --diff, --merge, --add, --remove, --goto, --new-window, --reuse-window, --wait, --locale, --user-data-dir, --profile |
code-insiders | Use the Insiders build with the same common command shape | Common options plus extension-management and troubleshooting option groups |
code-tunnel | Work with remote tunnel command flows from the terminal | --cli-data-dir, --log-to-file, --log, --telemetry-level, --verbose, --disable-telemetry, --help |
code-tunnel-insiders | Use Insiders tunnel flows with shared tunnel subcommands and options | Common, extension-management, troubleshooting, global tunnel, and tunnel options |
Use code-insiders when you intentionally want the daily Insiders build. Its completion spec spreads the base code model and changes the executable name and description to Visual Studio Code Insiders. Use code-tunnel when your workflow depends on tunnel-oriented access rather than a local desktop window. Its options include log-level choices from trace through off, a hidden telemetry-level initializer, an explicit current-command telemetry disable switch, and a verbose mode that implies waiting. The Insiders tunnel spec combines the same tunnel concepts with the Insiders executable name.
Sources: extensions/terminal-suggest/src/completions/code-insiders.ts, extensions/terminal-suggest/src/completions/code-tunnel.ts, extensions/terminal-suggest/src/completions/code-tunnel-insiders.ts
AI, Extensions, Source Control, and Terminal Fit Together
A practical first session can be linear: open a folder, install the recommended language or cloud extensions, open the terminal, initialize or inspect source control, and ask AI for help only after the workspace context is available. If you are creating a notebook, official AI docs show that you can request a new notebook from chat with /newNotebook or ask Agent mode in natural language. If you are editing an existing notebook or source file, inline chat can propose changes in place. In both cases, you should review the diff, run commands in the terminal, and commit intentional changes through source control.
The terminal completion state reinforces this integrated model. It carries the command buffer and cursor location for what the user is typing, the current working directory for workspace-relative completion, process and SSH context for environment-sensitive behavior, aliases for shell-specific command names, and environment variables for exported state. Those details are not visible to a new user, but they are what make a polished editor feel connected to the shell instead of merely embedding a terminal window. As you learn VS Code, prefer workflows that keep context together: project folder, terminal directory, AI prompt, and source-control review should all refer to the same work.
Sources: extensions/terminal-suggest/src/fig/autocomplete/fig/hooks.ts, extensions/terminal-suggest/src/fig/api-bindings/types.ts
Suggested Next Steps
For your first hour, focus on a small loop rather than every feature. Open a real project folder, run code . from the shell, open the integrated terminal, and run a harmless command such as ls or your project test command. Then try code --goto path/to/file:1 from the terminal, use the Command Palette to find a setting or extension command, and install one extension relevant to your stack. If AI features are enabled in your environment, ask chat to explain a file or scaffold a small change, then verify it manually in the editor and terminal before committing.
Read the terminal and command-line pages next if you want deeper CLI behavior, the Copilot and AI overview if you are adopting chat or Agent mode, and the extension marketplace page if your next task is adding language, cloud, or source-control integrations. The source files on this page are a narrow but useful window into the first-run experience: they show that VS Code invests in making the terminal understand the editor’s own command surface, including stable, Insiders, and tunnel workflows.