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

Allow default configuration for integrators #8737

Open
ofek opened this issue Nov 17, 2023 · 4 comments
Open

Allow default configuration for integrators #8737

ofek opened this issue Nov 17, 2023 · 4 comments
Labels
cli Related to the command-line interface wish Not on the current roadmap; maybe in the future

Comments

@ofek
Copy link
Contributor

ofek commented Nov 17, 2023

I am integrating with Ruff and wish to provide out-of-the-box configuration that users can override if they wish. Essentially, a flag to set the extend option like --config-extend would be perfect.

My use case is a new fmt command for Hatch but I imagine others would wish to integrate in a similar way, like Visual Studio Code.

@ofek
Copy link
Contributor Author

ofek commented Nov 20, 2023

Would this be easy to implement?

@MichaReiser
Copy link
Member

I'm not sure about the implementation complexity and I see your use case. A related issue is that larger projects want to share some configuration across projects that may be stored in different git repositories. I started looking into this in March but have since then be busy implementing the formatter. The main idea is that you can specify a named configuration (git URL / python package name / or something else) in extend. I believe that could solve your use case too:

  • No user configuration: Pass the default configuration
  • A user configuration exists: The user should extend your base configuration

@MichaReiser MichaReiser added cli Related to the command-line interface wish Not on the current roadmap; maybe in the future labels Nov 27, 2023
@T-256
Copy link
Contributor

T-256 commented Feb 13, 2024

@ofek
Does #9599 solve your issue?

@ofek
Copy link
Contributor Author

ofek commented Feb 19, 2024

Thanks for the heads up! Unfortunately it does not work: #10035

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cli Related to the command-line interface wish Not on the current roadmap; maybe in the future
Projects
None yet
Development

No branches or pull requests

3 participants