Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: allow for multiple values in cli options for adding extensions #1070

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

zakiali
Copy link
Collaborator

@zakiali zakiali commented Feb 4, 2025

Currently, you can only specify one extension on the cli through each of the --with-builtin and --with-extension options: goose session --with-extension "npx -y @modelcontextprotocol/server-memory" --with-builtin "developer". This PR extends the cli to allow for multiple values to be specified for each of these options:
goose session --with-builtin developer,memory --with-extension "npx -y @modelcontextprotocol/server-memory" --with-extension "npx -y @modelcontextprotocol/server-github"

This enables running goose in "headless" mode without modifying configurations and adding extensions on the fly

Copy link
Collaborator

@kalvinnchau kalvinnchau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

curious does this also work?

--with-builtin developer --with-builtin memory

or is it only the comma separated version?

extension: Option<String>,
builtin: Option<String>,
extensions: Vec<String>,
builtin: Vec<String>,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: lets name this builtins to be consistent with extensions

Copy link
Collaborator

@wendytang wendytang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: add example to using-extensions.md doc

@zakiali
Copy link
Collaborator Author

zakiali commented Feb 5, 2025

@kalvinnchau just tried it, and it works with both appraches

@zakiali zakiali requested a review from angiejones February 5, 2025 23:39
@zakiali
Copy link
Collaborator Author

zakiali commented Feb 5, 2025

@angiejones made some documentation updates. feel free to adjust

Copy link

github-actions bot commented Feb 5, 2025

PR Preview Action v1.6.0

🚀 View preview at
https://block.github.io/goose/pr-preview/pr-1070/

Built to branch gh-pages at 2025-02-05 23:40 UTC.
Preview will be ready when the GitHub Pages deployment is complete.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants