Skip to content

Conversation

@piotrpdev
Copy link
Contributor

Resolves: #78

Throws error if description field is not surrounded by double quotation marks.

@dsanders11 @erickzhao @VerteDinde

@piotrpdev piotrpdev added ✨ enhancement New feature or request javascript Pull requests that update Javascript code labels Aug 6, 2024
@piotrpdev piotrpdev requested a review from a team as a code owner August 6, 2024 00:30
@piotrpdev piotrpdev changed the title feat(api-history): --check-descriptions feat(api-history): --check-descriptions Aug 7, 2024
Copy link
Member

@dsanders11 dsanders11 left a comment

Choose a reason for hiding this comment

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

This looks good minus one comment about a continue statement.

Worth noting that this only allows for single-line quoted descriptions. In theory the user could provide a multi-line quoted description, but I think it's fine to only support single-line for now.

Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
Reference: #80 (comment)
@piotrpdev
Copy link
Contributor Author

@dsanders11 Worth noting that this only allows for single-line quoted descriptions. In theory the user could provide a multi-line quoted description, but I think it's fine to only support single-line for now.

https://stackoverflow.com/a/21699210

There are 5 6 NINE (or 63*, depending how you count) different ways to write multi-line strings in YAML.

I think I might leave that for someone else to figure out 😭

@dsanders11 dsanders11 merged commit dacce87 into main Aug 9, 2024
@dsanders11 dsanders11 deleted the feat/check-descriptions branch August 9, 2024 23:25
dsanders11 added a commit that referenced this pull request Aug 9, 2024
* feat(api-history): `--check-descriptions`

Reference: #78 (comment)

* test(api-history): description test

* fix(api-history): only double quotes

* feat(api-history): `--disallow-comments`

Reference: #79

* feat(api-history): traverse tree instead

* fix(api-history): description `for` loop

Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
Reference: #80 (comment)

* style(api-history): fix lint, leave comment

---------

Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
@continuous-auth
Copy link

🎉 This PR is included in version 2.4.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

javascript Pull requests that update Javascript code released ✨ enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Enforce use of double quotation marks for descriptions in API History

3 participants