Your first commit: Debugging the CLI
July 2, 2026 ยท View on GitHub
This step shows you how to debug the rad CLI in VS Code using the change you made in the previous step. For the full debugging reference, see the Debug rad in VS Code section of the authoritative Develop the Radius CLI guide. If you use another editor, you can skip this step.
๐ Tip: The first time you debug on macOS with a given version of Go, you'll be prompted for your password, and the prompt can take 1โ2 minutes to appear. This is expected.
Debug rad with the predefined configuration
The repository's .vscode/launch.json provides the "Debug rad CLI (prompt for args)" configuration, which launches cmd/rad/main.go and asks you which command-line arguments to run.
-
Set a breakpoint on the line you added in
main.goโ click in the gutter to the left of the line numbers.
-
Open the debug pane and select "Debug rad CLI (prompt for args)" from the drop-down.

-
Click the green triangle to start. The project builds first, which may take a moment.

-
When prompted, enter the arguments to run (for example
version) and confirm.
Execution stops at your breakpoint, where you can step through the code:

When you're done, hit the red square stop icon to end the session.