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

Make it easier to configure docsite builds, allow to override collection URLs and installation instructions #26

Merged
merged 4 commits into from
Aug 20, 2022

Conversation

felixfontein
Copy link
Collaborator

@felixfontein felixfontein commented Aug 17, 2022

@felixfontein felixfontein force-pushed the config branch 3 times, most recently from bd496a6 to e7f8239 Compare August 20, 2022 14:39
@felixfontein felixfontein changed the title [WIP] Make it easier to configure docsite builds [WIP] Make it easier to configure docsite builds, allow to override collection URLs and installation instructions Aug 20, 2022
@felixfontein
Copy link
Collaborator Author

The PR now contains code that allows to override the way a collection URL is composed, and the way the collection installation command is composed. This resolves #15.

For example, you can write the following in the configuration file for a docsite (the sphinx-init command now creates a default one which has some explanations for these options):

collection_url = {
  * = "https://galaxy.ansible.com/{namespace}/{name}"
  community.crypto = https://ansible.fontein.de/collections/community/crypto/
  felixfontein.* = "https://galaxy.fontein.de/{namespace}/{name}"
}

collection_install = {
  * = "ansible-galaxy collection install {namespace}.{name}"
  community.* = "git clone https://github.com/ansible-collections/community.{name}.git ~/ansible/collections/ansible_collections/community/{name}"
}

(In case you're wondering, the configuration file format is perky's format: https://github.com/larryhastings/perky/#readme)

@felixfontein
Copy link
Collaborator Author

FYI: before this can be un-WIP-ed, ansible-community/antsibull-core#7 needs to be merged, antsibull-core 1.2.0 released, and f5a727d removed from this branch. But that's basically the only thing that's missing from my side.

Copy link
Contributor

@briantist briantist left a comment

Choose a reason for hiding this comment

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

this is great! really looking forward to it

@@ -0,0 +1,8 @@
minor_changes:
- "The ``sphinx-init`` subcommand now also creates an ``antsibull-docs.cfg`` file and moves configuration settings from CLI flags in ``build.sh`` to this configuration file (https://github.com/ansible-community/antsibull-docs/pull/26)."
Copy link
Contributor

Choose a reason for hiding this comment

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

excellent, this should make for some interesting possibilities in https://github.com/ansible-community/github-docs-build/ maybe 🤔

@felixfontein felixfontein force-pushed the config branch 2 times, most recently from 419ab55 to 21da701 Compare August 20, 2022 18:13
@felixfontein felixfontein changed the title [WIP] Make it easier to configure docsite builds, allow to override collection URLs and installation instructions Make it easier to configure docsite builds, allow to override collection URLs and installation instructions Aug 20, 2022
@felixfontein
Copy link
Collaborator Author

Now that antsibull-core 1.2.0 has been released, this can be merged.

@felixfontein felixfontein merged commit 63d8f6a into ansible-community:main Aug 20, 2022
@felixfontein felixfontein deleted the config branch August 20, 2022 18:42
@felixfontein
Copy link
Collaborator Author

@briantist thanks for reviewing this!

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.

Be able to override note on ansible-galaxy commands
2 participants