Skip to content
| Marketplace
Sign in
Visual Studio Code>Programming Languages>DDK - Delphi Development KitNew to Visual Studio Code? Get it now.
DDK - Delphi Development Kit

DDK - Delphi Development Kit

Snowcaloid

|
628 installs
| (1) | Free
Utilities for developing in Delphi using VS Code
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Delphi DevKit

GitHub Release

Utilities for developing in Delphi using VS Code.

This project is not affiliated, associated, authorized, endorsed by, or in any way officially connected with Embarcadero Technologies, or any of its subsidiaries or its affiliates. The official Embarcadero Technologies website can be found at https://www.embarcadero.com/.

This extension does not include any proprietary Embarcadero code, libraries or binaries. To build Delphi projects, you must have a valid Delphi installation and the necessary environment variables set up. This extension does not work with the Delphi Community Edition due to its limitations on command-line compilation.

This extension is currently developed in my free time, and any feedback is welcome.

Features

  • Dual Project Views: Two separate project management approaches:
    • Self-Defined Workspaces: User-customizable project workspaces with drag & drop support
    • Loaded Group Project: Load and manage Delphi group projects (.groupproj) - readonly view
  • Multi-Compiler Support: Configure and switch between multiple Delphi versions (Delphi 2007 → Delphi 13.0 Florence built-in)
  • Project Management: Compile, recreate, run, and manage Delphi projects with keyboard shortcuts
  • Bulk Compilation: Compile or recreate all projects in a workspace or group project at once; cancellable at any time
  • Workspace Management: Create, rename, remove workspaces and move projects between them
  • File System Integration: Show projects in Explorer, open in File Explorer
  • Configuration Management: Create and configure .ini files for executables
  • Visual Indicators: File icons for Delphi files and missing file indicators
  • Configuration Import/Export: Backup and restore your entire DDK configuration
  • File-Based Persistence: Project and compiler data stored as RON files in %APPDATA%/ddk/
  • File Navigation: .pas <-> .dfm swapping with Alt+F12 hotkey
  • Smart Navigation: .dfm -> .pas jumps with Ctrl+click
  • Compiler Output Enhancements: Timestamps, clickable file links, and diagnostics published to the Problems panel
  • Formatter Support: Configurable Delphi code formatter.
  • DelphiLSP Settings Generation: Generate the .delphilsp.json file Embarcadero's DelphiLSP extension needs for code insight, without ever opening RAD Studio
  • LSP Server: Bundled ddk-server (Rust) handles all project state, compilation, and formatting
  • MCP Server: Bundled ddk-mcp-server exposes project and compiler management as MCP tools for AI assistants (VS Code Copilot, Claude Desktop, etc.)
  • CLI (ddk): Standalone command-line interface for managing projects and compilers outside of VS Code. Install via WinGet or use the bundled binary.

Installation

VS Code Extension

Install from the Visual Studio Marketplace. The extension bundles all Rust binaries — no extra setup needed.

CLI (standalone)

winget install ValentinBaron.DDK

Or download ddk-windows-x86_64.zip from the latest release and add ddk.exe to your PATH.

CLI Usage

ddk project list                       # List all known projects
ddk project select <ID>                # Select a project by ID
ddk projects add <PATH> <WORKSPACE>    # Add a .dproj/.dpr/.dpk to a workspace (by name)
ddk projects add_workspace <NAME> <COMPILER>  # Create a workspace bound to a compiler
ddk compiler list                      # List available compiler configurations
ddk compiler set <KEY>                 # Set the group project compiler
ddk compile                            # Compile the active project
ddk compile <ID|NAME>                  # Compile a project by ID or name (= -p; lists candidates if ambiguous)
ddk compile -p <ID|NAME>               # Same, explicit flag form
ddk compile --rebuild -p <ID>          # Rebuild a specific project by ID
ddk compile <PATH>                     # Compile a .dproj/.dpr/.dpk (uses the owning project if managed, else ad-hoc)
ddk compile <PATH> -c "Delphi 12"      # ...choosing the compiler (key or product name)
ddk compile <PATH> --config Release --platform Win64   # ...with build overrides
ddk compile --show-warnings            # Include warnings verbatim
ddk compile --show-hints               # Include hints verbatim
ddk compile --summarize-diagnostics    # Append `<file>: X warn, Y hint` per project
ddk compile -e windows-1252            # Decode compiler output with a specific encoding
ddk compile --fail-on-error            # Exit non-zero when the compile fails
ddk compile <ID|NAME> -- /p:Foo=Bar    # Pass extra arguments verbatim to MSBuild (after `--`)
ddk run                                # Run the active project's executable
ddk run <ID|NAME>                      # Run a project by ID or name (= -p; lists candidates if ambiguous)
ddk run <PATH>                         # Run a .exe directly, or a .dproj/.dpr/.dpk's owning project
ddk run -a "-flag \"value with spaces\""  # Override the project's saved Start Parameters for this run
ddk delphilsp-config                   # Write the active project's .delphilsp.json (DelphiLSP code insight)
ddk delphilsp-config <ID|NAME|PATH>    # ...for a specific project (lists candidates if ambiguous)
ddk delphilsp-config <PATH> -c "Delphi 12"   # ...choosing the compiler for an unmanaged path
ddk delphilsp-config <PATH> -o <FILE>  # ...writing somewhere else instead of next to the project
ddk env                                # Show active project & compiler info
ddk info                               # Print the DDK README
ddk --json <command>                   # Output as JSON

ddk compile <PATH> compiles a .dproj/.dpr/.dpk. If the file already belongs to a managed project it is compiled as that project (and a file shared by several projects lists the candidates instead of compiling); otherwise it is compiled ad-hoc without adding it to the saved project list (handy for one-off builds). For the ad-hoc case --compiler/-c selects the compiler by exact key (12.0) or product name (Delphi 12), defaulting to the newest installed compiler. The same is exposed to AI tooling via the MCP delphi_compile_file, delphi_add_project, and delphi_add_workspace tools.

Anything after a -- separator on ddk compile is passed verbatim to MSBuild (e.g. ddk compile be -- /p:DCC_Define=FOO /m). These extra arguments are appended after DDK's own /p:Config//p:Platform args, so a /p: override here wins (MSBuild takes the last value). They have no effect on a bare .dpr/.dpk target, which is compiled with the command-line compiler (dcc) rather than MSBuild — DDK prints a note when they are ignored.

ddk compile --json (and the MCP compile tools) return a fully machine-coded result: structured header fields (project, project_path, compiler, config, platform, action, success, code) plus a diagnostics object grouped into errors/warnings/hints, each entry carrying {code, file, line, message}. There is no raw log text. Diagnostics obey the same --show-warnings / --show-hints filters — errors always appear, warnings only with --show-warnings, hints only with --show-hints — so a slim compile stays slim; pass both flags to get every diagnostic. Compiler output is decoded using the active console output codepage (what chcp sets); use -e/--encoding (or the DDK_COMPILER_ENCODING environment variable) to force a specific encoding. By default ddk compile exits 0 even on a failed compile (the result is in the JSON); pass --fail-on-error to exit with the compiler's exit code instead (a cancelled compile exits 2).

Compile output for the CLI and the MCP delphi_compile_project tool is trimmed for AI / token-efficient consumption: the decorative banner box is stripped and warning / hint lines are hidden by default. Errors and the final status line are always shown.

ddk run <PATH> dispatches on the file extension: a .exe is launched directly; a .dproj/.dpr/.dpk must already belong to a managed project (its stored executable is run, same resolution as by name) — it is never compiled or run ad-hoc. A project with a configured Host Application (the Debugger_HostApplication from Project > Options > Debugger in the Delphi IDE, or the DevKit Set Host Application override, which wins) runs that host executable instead — matching the IDE, and making a .dpk package project runnable at all. --args/-a overrides the run parameters for that one run; the process is launched detached, so the CLI/MCP call returns immediately without waiting for it to exit. The same is exposed to AI tooling via the MCP delphi_run_project and delphi_run_file tools.

ddk delphilsp-config writes the <project>.delphilsp.json settings file that Embarcadero's DelphiLSP VS Code extension reads for code insight (completion, go-to-definition). That file is normally produced only when the project is opened in the RAD Studio IDE, so code insight is dead for anyone working purely in VS Code. DDK reconstructs it from the project's .dproj (evaluated for the effective configuration/platform), the compiler installation's bin\rsvars.bat, and the IDE's global Library Path, Browsing Path and user-defined environment variables read from HKCU\SOFTWARE\Embarcadero\BDS\<version>. Search-path entries whose $(MACRO) cannot be resolved are dropped and reported as warnings. The target resolves like ddk compile: an ID, a name, or a path (ad-hoc when the path belongs to no workspace). Re-run it after changing the project's search paths, defines, configuration or platform. The same is exposed to AI tooling via the MCP delphi_generate_delphilsp_config tool, and to the VS Code extension via the delphilsp/generate LSP request.

Every file DDK writes carries a top-level "generatedBy": "delphi-devkit" key next to "settings". RAD Studio never writes that key, so it marks the file as DDK's to maintain: the VS Code extension refreshes a stale configuration only when the marker is present, and leaves an IDE-generated or hand-written .delphilsp.json alone. Running ddk delphilsp-config explicitly always rewrites the file regardless of the marker.

In the VS Code extension the integration activates only when the DelphiLSP extension (EmbarcaderoTechnologies.delphilsp) is installed — no commands or menu items appear otherwise, and installing it later enables them on the fly. A Generate DelphiLSP Config context-menu action is added to projects in the DDK tree, and whenever the active project changes DDK keeps DelphiLSP in sync automatically (ddk.delphilsp.autoSync, on by default): it points DelphiLSP's delphiLsp.settingsFile at the active project's .delphilsp.json, generating the file on the fly when it is missing — or regenerating it when it is DDK-owned and its .dproj content has changed since generation — so code insight always resolves units, defines and search paths in the context of the project you are actually working on. Because the generated files are machine-specific, DDK also keeps them out of version control by adding *.delphilsp.json to the owning repository's local .git/info/exclude (ddk.delphilsp.autoIgnoreDelphiLspFiles, on by default; disabling it removes exactly the entry DDK added, nothing else). Because DelphiLSP's server applies a settings change only to files opened afterwards (its own Select project settings command leaves already-open files with stale diagnostics until they are edited), DDK also re-validates every open Delphi file after the switch via an invisible language-mode round-trip that re-emits didOpen — tabs, focus, cursor, dirty state and undo history are untouched (ddk.delphilsp.revalidateOpenFilesOnSwitch, on by default).

With both extensions active the Problems view would otherwise show the same error twice — once from DDK's last compile and once from DelphiLSP's live analysis — and DDK's copy would go stale the moment the code is fixed, since it only refreshes on the next compile. DDK therefore merges the two: whenever DelphiLSP reports live diagnostics for a file, every DDK compile diagnostic matching one of them (same line, same Exxxx code) is removed, leaving only the live entry with its precise token range — and when DelphiLSP later clears that entry because the error was fixed in the editor (even without recompiling), no stale compile copy resurfaces. Compile diagnostics DelphiLSP knows nothing about (files it has not validated, link errors) keep their normal lifetime, and without DelphiLSP installed nothing is ever removed (ddk.delphilsp.mergeDiagnostics, on by default).

Without --args, a project runs with the .dproj's own Debugger_RunParams — the Run Parameters set via Project > Options > Run in the Delphi IDE, resolved against the project's active configuration/platform — fused with the saved Start Parameters (see Set Start Parameters below): the dproj value comes first, the saved value is appended after, so both take effect rather than one silently replacing the other. In the VS Code extension this can be turned off with the ddk.projects.useDebuggerRunParams setting: disable it to always use only the saved Start Parameters, ignoring the dproj's Run Parameters entirely. The CLI/MCP always fuse Debugger_RunParams in, since there is no extension setting for them to consult.

Demos

Add a Workspace and drag in a Project

Add workspace and drag project

Add a Project via dialog

Add project dialog

Load a Group Project

Select group project

Compile a Project

Compile selected project

Transfer Group Project to Workspace

Transfer group project to workspace

Format Delphi Source

Formatter

Commands

File Navigation

  • Swap .DFM/.PAS - Switch between form and unit files (Alt+F12)

Project Management

  • Select Delphi Compiler for Group Projects - Choose the active compiler configuration for .groupproj files
  • Pick Group Project - Load a Delphi group project (.groupproj)
  • Unload Group Project - Unload the currently loaded group project
  • Transfer Group Project to Workspace - Convert the loaded group project into a self-defined workspace
  • Refresh - Refresh the projects view and discover file paths

Workspace Management

  • Add Workspace - Create a new self-defined workspace
  • Rename Workspace - Rename an existing workspace
  • Remove Workspace - Delete a workspace and its projects
  • Add Project - Add projects to a workspace
  • Remove Project - Remove projects from a workspace

Configuration

  • Import Configuration - Import DDK configuration from JSON file
  • Export Configuration - Export DDK configuration to JSON file
  • Edit Default .ini - Edit the default INI template file
  • Edit Formatter Config - Edit the Delphi formatter configuration file
  • Reset Formatter Config - Reset the formatter configuration to defaults
  • Edit Compiler Configurations - Open the compiler configurations RON file directly
  • Edit Projects Data - Open the projects data RON file directly

Project Actions (Available via context menu and keyboard shortcuts)

  • Compile Selected Project - Compile the selected project (Ctrl+F9)
  • Recreate Selected Project - Clean and rebuild the selected project (Shift+F9)
  • Compile All in Workspace - Compile all projects in a workspace
  • Recreate All in Workspace - Clean and rebuild all projects in a workspace
  • Compile All in Group Project - Compile all projects in the loaded group project
  • Recreate All in Group Project - Clean and rebuild all projects in the loaded group project
  • Cancel Compilation - Cancel the active compilation (Ctrl+F2)
  • Run Selected Project - Execute the selected project (F9)
  • Set Start Parameters - Configure command-line arguments passed to the executable when run
  • Set Host Application - Configure the executable that hosts the project when run (e.g. the application loading a .dpk package); overrides the dproj's own Debugger_HostApplication
  • Configure/Create .ini - Create or edit INI configuration files
  • Set Manual Path - Manually set the .dproj path for a project

Extension Settings

  • ddk.compiler.encoding: Character encoding used to decode MSBuild output (oem by default, use utf8 if your paths contain non-ASCII characters).
  • ddk.projects.useDebuggerRunParams: When running a project, fuse the .dproj's own Debugger_RunParams with the saved Start Parameters, dproj first (true by default). Disable to always use only the saved Start Parameters.

Compiler Configurations

Compiler configurations are stored in %APPDATA%\ddk\compilers.ron and managed by the DDK server. The extension ships with built-in presets for all Delphi versions from Delphi 2007 to Delphi 13.0 Florence.

You can view and edit them directly via the Edit Compiler Configurations command. Each entry includes:

  • product_name / compiler_version / package_version — version identifiers
  • installation_path — root path of your Delphi installation
  • build_arguments — MSBuild arguments passed during compilation
  • condition — optional expression to enable/disable the entry

The first entry whose Formatter.exe is found in its installation path is used for formatting.

Project Views

Self-Defined Workspaces

  • Customizable: Create and organize your own project workspaces
  • Drag & Drop: Move projects within and between workspaces
  • Compiler Assignment: Each workspace has a predefined compiler
  • Persistent: Projects and workspaces are stored in %APPDATA%\ddk\projects.ron

Loaded Group Project

  • Read-Only: View projects from .groupproj files
  • Compiler Selection: Use the compiler picker for group project compilation
  • Cross-Copy: Drag projects from group projects to self-defined workspaces

Visual Indicators

  • Selected Project: Shows ←S indicator for the currently selected project
  • Missing Files: Shows ! indicator for files that don't exist
  • File Type Icons: Custom icons for .pas, .dfm, .dpr, .dpk, .dproj files

Keyboard Shortcuts

  • Alt+F12 - Swap between .PAS and .DFM files
  • Ctrl+F9 - Compile selected project (when project is selected)
  • Shift+F9 - Recreate selected project (when project is selected)
  • F9 - Run selected project (when project has executable)
  • Ctrl+F2 - Cancel active compilation

Known Issues

None so far.

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
  • Your Privacy Choices
  • Consumer Health Privacy
© 2026 Microsoft