Documentation · Source control

Source control

A deliberately small Git surface inside the Editor: enough to understand and commit a workspace without turning Warden into a general-purpose Git GUI.

Current scope

The Source tab activates when the opened workspace root is itself a Git repository. It reports the current branch and separates staged changes from working-tree changes.

  • open a changed file directly in the editor;
  • stage or unstage individual paths;
  • stage or unstage all changes;
  • enter a commit message and create a commit;
  • refresh status at any time, with saves also refreshing source-control state.

Why it is bounded

Warden does not expose a free-form Git command box through the source-control UI. The backend invokes Git with fixed operations and structured arguments. More advanced Git work remains available through the terminal.

Workspace root means repository root.

The current implementation intentionally does not reach upward into a parent repository. Open the repository root as the Warden workspace to use Source Control.

Commits use the Git identity configured for the Warden process user. If user.name or user.email is missing, Git returns its normal configuration error rather than Warden inventing an identity.

Repository trust boundary

Repository hooks, external diff commands, pagers and interactive credential prompts are disabled for dashboard operations. User-controlled filenames are passed after Git's -- option terminator. Commands have a ten-second deadline and a 4 MiB combined-output limit. The integrated terminal remains the deliberate escape hatch for operators who choose to run a repository's own tooling or hooks.

Likely next steps

Useful additions include per-file diff viewing, discard/revert with confirmation, commit history and branch switching. Those should earn their way in through use rather than importing the entire VS Code Source Control feature set at once.