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

Add submodule configuration #4464

Closed
5 tasks
agjohnson opened this issue Aug 3, 2018 · 0 comments
Closed
5 tasks

Add submodule configuration #4464

agjohnson opened this issue Aug 3, 2018 · 0 comments
Assignees
Labels
Accepted Accepted issue on our roadmap Feature New feature

Comments

@agjohnson
Copy link
Contributor

Migrated from readthedocs/readthedocs-build#30

Seems a number of projects are hitting issues with submodule clone steps, and this should be configurable in our config. Because git doesn't provide the mechanism for optional submodules, we can do something like:

submodules:
  include: []
  recursive: false

as implicit default. And:

submodules:
  include:
    - foo/
    - bar/

As include example.

submodules:
  exclude:
    - foo/

^ is the exclude example.

Legacy projects implemented before this change would have an implicit configuration of:

submodules:
  include: all
  recursive: true

It's not possible to include and exclude submodules, this is a validation error.

This would eventually alter the code that rtfd/readthedocs.org uses for submodule cloning, and would only selectively clone things? The changes there are likely moving to specific submodule clone commands.

  • Currently submodule cloning takes place in the git checkout step. This will need to be moved to a new step after we parse the configuration
  • New behavior will be to not clone submodules automatically
  • If possible, we won't recursively clone as well. Maybe this is another option on the spec?
  • We'll add a new project.Feature, plus migration, to lock old users into the old behavior (all submodules are cloned)
  • We can perhaps also detect that a project has submodules that won't be cloned and raise a warning. This warning shouldn't be a build failure, but a notification on-site/through email?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Accepted Accepted issue on our roadmap Feature New feature
Projects
None yet
Development

No branches or pull requests

2 participants