Skip to content

Commit 1c25a43

Browse files
author
Linearb CI
committed
docs: update README to include managing action and plugin dependencies
1 parent b99082b commit 1c25a43

1 file changed

Lines changed: 18 additions & 0 deletions

File tree

README.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,24 @@ help in improving gitStream!
3131
To add support for `.cm` files in your code editor, see our
3232
[FAQ](https://docs.gitstream.cm/faq/#is-there-cm-syntax-highlighting).
3333

34+
## Managing Dependencies
35+
36+
### Action dependencies (`package.json``dependencies`)
37+
38+
Imported by the action's source code. Must be listed in `package.json` for build time.
39+
40+
To add:
41+
1. `npm install <package>` and import it in `src/`
42+
2. If it can't be bundled by ncc (WASM, native addons), add `--external <package>` to the `package` script and add it to `vendor-plugins` as well
43+
44+
### Plugin dependencies (`vendor-plugins` script in `package.json`)
45+
46+
Packages that user plugins can `require()` at runtime. Installed into `dist/node_modules/` at build time and committed to the repo.
47+
48+
To add:
49+
1. Add with a pinned version to the `vendor-plugins` script in `package.json`
50+
2. Run `npm run package` and commit the updated `dist/node_modules/`
51+
3452
## License
3553

3654
The gitStream GitHub Action is licensed under the Apache License. See

0 commit comments

Comments
 (0)