Skip to content

Commit 0b2da3f

Browse files
committed
docs: clarify discovery behavior and improve cross-references
- Explain discovery scans working directory for Git repos, not 'agent directory' - Cross-reference standard devcontainer.json locations instead of repeating - Fix 'Currently available' phrasing to avoid staleness - Improve link placement for customization docs
1 parent eacb146 commit 0b2da3f

File tree

2 files changed

+13
-9
lines changed

2 files changed

+13
-9
lines changed

docs/admin/templates/extending-templates/devcontainers.md

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -121,12 +121,15 @@ by setting this to `false`.
121121

122122
Enables automatic discovery of Dev Containers in Git repositories.
123123

124-
When enabled, the agent will:
124+
When enabled, the agent scans the configured working directory (set via the
125+
`directory` attribute in `coder_agent`, typically the user's home directory) for
126+
Git repositories. If the directory itself is a Git repository, it searches that
127+
project. Otherwise, it searches immediate subdirectories for Git repositories.
125128

126-
- Scan the agent directory for Git repositories
127-
- Look for `.devcontainer/devcontainer.json` or `.devcontainer.json` files
128-
- Surface discovered Dev Containers in the Coder UI
129-
- Respect `.gitignore` patterns during discovery
129+
For each repository found, the agent looks for `devcontainer.json` files in the
130+
[standard locations](../../../user-guides/devcontainers/index.md#1-add-a-devcontainerjson)
131+
and surfaces discovered Dev Containers in the Coder UI. Discovery respects
132+
`.gitignore` patterns.
130133

131134
Set to `false` if you prefer explicit configuration via `coder_devcontainer`.
132135

@@ -153,8 +156,8 @@ block in their `devcontainer.json` file. Available options include:
153156
- `displayApps` — Control which built-in apps appear
154157
- `apps` — Define custom applications
155158

156-
See [Customizing dev containers](../../../user-guides/devcontainers/customizing-dev-containers.md)
157-
for the full reference.
159+
For the full reference, see
160+
[Customizing dev containers](../../../user-guides/devcontainers/customizing-dev-containers.md).
158161

159162
## Complete Template Example
160163

docs/user-guides/devcontainers/working-with-dev-containers.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,8 +138,9 @@ in your `devcontainer.json` file. Coder also maintains a
138138
[repository of features](https://github.com/coder/devcontainer-features) to
139139
enhance your development experience.
140140

141-
Currently available Coder features include
142-
[code-server](https://github.com/coder/devcontainer-features/blob/main/src/code-server):
141+
For example, the
142+
[code-server](https://github.com/coder/devcontainer-features/blob/main/src/code-server)
143+
feature from the [Coder features repository](https://github.com/coder/devcontainer-features):
143144

144145
```json
145146
{

0 commit comments

Comments
 (0)