Skip to content

Commit 90228ca

Browse files
Automated documentation update [skip ci] (#261)
1 parent 2a79d75 commit 90228ca

1 file changed

Lines changed: 45 additions & 0 deletions

File tree

src/add-script/README.md

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
2+
# add-script (add-script)
3+
4+
Add a script from a URL or inline text to /usr/local/bin during devcontainer build
5+
6+
## Example Usage
7+
8+
```json
9+
"features": {
10+
"ghcr.io/devcontainer-community/devcontainer-features/add-script:1": {}
11+
}
12+
```
13+
14+
## Options
15+
16+
| Options Id | Description | Type | Default Value |
17+
|-----|-----|-----|-----|
18+
| name | Name for the script placed in /usr/local/bin. | string | - |
19+
| url | URL of a script to download. | string | - |
20+
| script | Inline script text to add. | string | - |
21+
22+
# add-script
23+
24+
## Project
25+
26+
_No upstream project — this is a utility feature._
27+
28+
## Description
29+
30+
A utility feature that adds a custom script to `/usr/local/bin` during devcontainer build. Accepts either a URL pointing to a script to download, or an inline script supplied directly as text. The script is placed at `/usr/local/bin/<name>` and made executable, but is **not** executed during install. Exactly one of `url` or `script` must be provided along with a `name`.
31+
32+
## Installation Method
33+
34+
No binary is installed. The feature downloads (via `wget` or `curl`) or writes the provided script to `/usr/local/bin/<name>` and sets its permissions to executable (`755`). If neither `wget` nor `curl` is available, `curl` is installed automatically via `apt`.
35+
36+
## Other Notes
37+
38+
- If both `url` and `script` are provided the feature fails with an error.
39+
- If neither `url` nor `script` is provided, or if `name` is not provided, the feature exits successfully without doing anything.
40+
- The script is **not** executed during the devcontainer build — it is only placed at the target path for later use.
41+
42+
43+
---
44+
45+
_Note: This file was auto-generated from the [devcontainer-feature.json](https://github.com/devcontainer-community/devcontainer-features/blob/main/src/add-script/devcontainer-feature.json). Add additional notes to a `NOTES.md`._

0 commit comments

Comments
 (0)