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

Docs Readability: Newlines in Import sections #1672

Merged
merged 3 commits into from
Feb 5, 2024

Conversation

guineveresaenger
Copy link
Contributor

This PR allows docsgen to retain newlines in import sections by adding a double newline placeholder to the end of every line in the Import section of the docs.

Previously, newlines were not honored except around the import code part itself.

Tests are adjusted to reflect newlines being appended rather than prepended.

Here is a registry preview

Screenshot from that preview:

Screenshot 2024-02-02 at 5 33 14 PM

Closes pulumi/pulumi-gcp#1375.

@guineveresaenger guineveresaenger requested review from Frassle, iwahbe and a team February 3, 2024 01:34
Copy link
Contributor

@VenelinMartinov VenelinMartinov left a comment

Choose a reason for hiding this comment

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

Looks good! Might be nice to add one of the broken motivating examples as a test!

Copy link
Member

@iwahbe iwahbe left a comment

Choose a reason for hiding this comment

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

The GCP imports look much better. 2 things to address before merging:

  • I agree with @VenelinMartinov. Let's make sure we add a regression test for gcp-style imports.

  • If you haven't done this already, lets make sure this doesn't break imports for aws and azure.

@guineveresaenger
Copy link
Contributor Author

This change will add extra newlines to import sections of resource descriptions across the board. It should not affect how they are displayed.

A test of AWS registry docs is building here

@guineveresaenger
Copy link
Contributor Author

No diff in display on docs preview on AWS import instructions, see before/after screenshots. Given the ✅ here and improved rendering for GCP, I am going to merge.

Screenshot 2024-02-05 at 10 47 18 AM Screenshot 2024-02-05 at 10 47 12 AM

@guineveresaenger guineveresaenger merged commit f2504a5 into master Feb 5, 2024
7 checks passed
@guineveresaenger guineveresaenger deleted the guin/newlines-for-imports branch February 5, 2024 18:50
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.

Service account import issues
3 participants