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 import for external .codeclimate.yml configurations #1026

Open
GarreBrenn opened this issue Jul 2, 2021 · 2 comments
Open

Allow import for external .codeclimate.yml configurations #1026

GarreBrenn opened this issue Jul 2, 2021 · 2 comments
Assignees

Comments

@GarreBrenn
Copy link

I am working on triggering code quality tests on multiple GitLab repositories from the CI/CD flow of a single GitLab project. We have decided on a .codeclimate.yml configuration that should work for all of our projects. It would be nice to not have to physically copy that configuration into every single project we intend to test, as there are likely 100+ and manually updating these in the case of a change to our default configuration would be quite cumbersome.

While it's documented that you can use external configurations for engines, I don't see any documentation relating to using external .codeclimate.yml files. It would be great if we could instead include a configuration file like:

# here you can see the ability to include several configurations 
prepare:
  fetch:
  - url: "https://raw.githubusercontent.com/thoughtbot/guides/master/.codeclimate.yml"
    path: ".codeclimate.yml"
    name: cc_config_1
  - url: "https://raw.githubusercontent.com/thoughtbot/guides/feature/.codeclimate.yml"
    path: ".codeclimate.yml"
    name: cc_config_2

# here you could specify which codeclimate configurations you would like to enable
codeclimate:
  cc_config_1
    enabled: true
  cc_config_2
    enabled: false

# below here would add to or override the included configuration
plugins:
...

I apologize if this feature already exists, but if it does, this could serve as a reminder that the documentation is unclear.

@filipesperandio
Copy link
Contributor

@GarreBrenn
Copy link
Author

@filipesperandio Thank you for your reply! While I am a little embarrassed I didn't see that documentation earlier, I do still think this feature set up the way I mentioned above could be valuable. Since Code Climate is offered via GitLab's Code Quality, it would nice to simply reference another configuration from within the .codeclimate.yml file instead of creating a Code Climate account and managing things that way so my team only has to interact with GitLab. Also this would help minimize the number of API calls users would have to write. What do you think?

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

No branches or pull requests

3 participants