Skip to content

Conversation

@floralph
Copy link

Summary

Add support for specifying additional MCP configuration files via the --mcp-config-paths CLI argument, enabling users to organize and share MCP server configurations across multiple projects and environments.

Description of changes

  1. New CLI argument: Add --mcp-config-paths argument to specify additional MCP configuration files
  2. Cross-platform support: Use OS-specific path separators (: on Unix/Mac, ; on Windows) for multiple paths
  3. Configuration precedence: Implement clear precedence order: global < workspace < additional paths (left to right)
  4. Path handling: Support tilde expansion (~/config.json) and relative paths in additional config paths
  5. Error handling: Provide clear warnings for configuration conflicts and missing files
  6. Comprehensive testing: Add extensive tests covering path parsing, precedence rules, and error scenarios

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

* Add --mcp-config-paths argument to specify additional MCP configuration files
* Support OS-specific path separators (: on Unix/Mac, ; on Windows)
* Implement configuration precedence: global < workspace < additional paths
* Add comprehensive tests for path parsing, precedence, and error handling
* Support tilde expansion and relative paths in additional config paths
* Provide clear warnings for configuration conflicts and missing files
@floralph floralph requested a review from a team as a code owner June 13, 2025 00:03
@brandonskiser
Copy link
Contributor

Note that we are currently making some changes w/ how MCP configuration will be handled, so not sure if we want to include this as a new feature if it'll be immediately replaced with another modality.

@chaynabors @mschrage what do you think?

@dingfeli
Copy link
Contributor

dingfeli commented Jul 4, 2025

Hi! We have moved the development of q chat back to our original repo: https://github.com/aws/amazon-q-developer-cli. Please rebase your branch onto our original repo. You can do so via the following:

With github cli:
Install gh cli if you haven't already:

brew install gh 

And run the following:

BRANCH=your-feature-branch-name
gh repo fork aws/amazon-q-developer-cli 
cd amazon-q-developer-cli git remote add autocomplete https://github.com/aws/amazon-q-developer-cli-autocomplete
git fetch amazon-q-developer-cli-autocomplete $BRANCH
git push origin $BRANCH

Or if you would like to do this without install the github cli:

  1. Add amazon-q-developer-cli-autocomplete as remote for amazon-q-developer-cli
cd /path/to/your/fork/of/amazon-q-developer-cli

git remote add amazon-q-developer-cli-autocomplete url/to/your/fork/of/amazon-q-developer-cli-autocomplete
  1. Fetch your feature branch from amazon-q-developer-cli-autocomplete
git fetch amazon-q-developer-cli-autocomplete your-feature-branch-name
  1. Remake your PR
git push origin-to-your-fork your-feature-branch-name
brew install github
github repo fork amazon-q-developer-cli

Thank you for your contribution!
If you need any help, please reach out to @dingfeli.

@dingfeli dingfeli closed this Jul 4, 2025
@dingfeli
Copy link
Contributor

dingfeli commented Jul 4, 2025

In addition to the moving message, we have also just recently overhauled the chat config with agent: aws/amazon-q-developer-cli#2222, which overlaps with the goal of this PR.

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