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: update usage doc with info about --watch flag and absence of --version flag #1142

Merged
merged 7 commits into from
Apr 3, 2024

Conversation

eelcofolkertsma
Copy link
Contributor

To reflect changes in asyncapi generate fromTemplate command for --watch option

Documentation update to follow asyncapi generate fromTemplate --help

To reflect changes in asyncapi generate fromTemplate command for --watch option
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Welcome to AsyncAPI. Thanks a lot for creating your first pull request. Please check out our contributors guide useful for opening a pull request.
Keep in mind there are also other channels you can use to interact with AsyncAPI community. For more details check out this issue.

@eelcofolkertsma eelcofolkertsma changed the title bug: Update usage.md to reflect --watch option on generate fromTemplate iso --watchTemplate fix: Update usage.md to reflect --watch option on generate fromTemplate iso --watchTemplate Mar 15, 2024
@derberg derberg changed the title fix: Update usage.md to reflect --watch option on generate fromTemplate iso --watchTemplate fix: update usage doc with info about --watch flag and absence of --version flag Mar 19, 2024
derberg
derberg previously approved these changes Mar 19, 2024
Copy link
Member

@derberg derberg left a comment

Choose a reason for hiding this comment

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

lgtm, thanks!

just updated the PR title and removed fix as this is docs update, so no need to trigger patch release

@derberg derberg changed the title fix: update usage doc with info about --watch flag and absence of --version flag docs: update usage doc with info about --watch flag and absence of --version flag Mar 19, 2024
@derberg
Copy link
Member

derberg commented Mar 19, 2024

@Florence-Njeri hey, please have a look and approve

@Florence-Njeri
Copy link
Collaborator

@derberg taking a look

docs/usage.md Outdated
@@ -149,4 +154,4 @@ try {
}
```

See the [API documentation](api) for more examples and full API reference information.
See the [API documentation](/docs/tools/generator/api) for more examples and full API reference information.
Copy link
Collaborator

Choose a reason for hiding this comment

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

This leads to a 404 error. We should leave it as is @derberg any thought about this?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I do not know how/why link was incorrect, but I have accepted suggestion so now reference is working again

Copy link
Member

Choose a reason for hiding this comment

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

@Florence-Njeri actually both are good - not sure where you see 404

I personally prefer full relative links like /docs/tools/generator/api but api works as well. Let's leave it as api as my approach for full relative links is an old habit that I follow but brainfart every time I try to find in my brain the reason for doing it 😄

- <template>: Name of the generator template like for example @asyncapi/html-template or https://github.com/asyncapi/html-template
ARGUMENTS
ASYNCAPI - Local path, url or context-name pointing to AsyncAPI file
TEMPLATE - Name of the generator template like for example @asyncapi/html-template or https://github.com/asyncapi/html-template

Copy link
Collaborator

Choose a reason for hiding this comment

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

@derberg correct me if I am wrong but I feel the changes being made to this file might be unnecessary especially this part asyncapi generate fromTemplate [ASYNCAPI] [TEMPLATE] [-h] [-d <value>] [-i] [--debug] [-n <value>] [-o <value>] [--force-write] [-w] [-p <value>] [--map-base-url <value>] why not just leave it as was asyncapi generate fromTemplate <asyncapi> <template> [<options>]

Copy link
Contributor Author

Choose a reason for hiding this comment

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

See earlier argument. Keep documentation in sync with help-output generated from code

Copy link
Member

Choose a reason for hiding this comment

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

yeah, I think in this particular case good to follow the output from CLI that is following best practices

docs/usage.md Outdated Show resolved Hide resolved
- <asyncapi>: Local path or URL pointing to AsyncAPI document for example https://bit.ly/asyncapi
- <template>: Name of the generator template like for example @asyncapi/html-template or https://github.com/asyncapi/html-template
ARGUMENTS
ASYNCAPI - Local path, url or context-name pointing to AsyncAPI file
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hi @Florence-Njeri , @derberg
I did "construct" my update by copy/pasting output of asyncapi generate fromTemplate --help. The suggestions break alignment between code and documentation. Do you really want to go that direction?

Alternative: apply suggestions to code (help text) and documentation in parallel. @derberg, can you point me to the help text?

Bring forward fix to 404 error

Co-authored-by: Florence Njeri <[email protected]>
@eelcofolkertsma
Copy link
Contributor Author

This is my second PR ever, so apologies where I behave in unexpected ways. Please coach me

@Florence-Njeri
Copy link
Collaborator

Florence-Njeri commented Mar 27, 2024

Hey @eelcofolkertsma no, you are doing amazing and the continuous improvements to our docs are a great help to our community. Let me take a nother look from your latest feedback

@derberg
Copy link
Member

derberg commented Mar 27, 2024

@eelcofolkertsma great contributions so far 👏🏼

Copy link
Collaborator

@Florence-Njeri Florence-Njeri left a comment

Choose a reason for hiding this comment

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

Hey @eelcofolkertsma I took another look at your PR and it looks good. Good job and thank you for providing some extra context in the comments

Copy link

sonarqubecloud bot commented Apr 3, 2024

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

@derberg
Copy link
Member

derberg commented Apr 3, 2024

/rtm

@asyncapi-bot asyncapi-bot merged commit d31b847 into asyncapi:master Apr 3, 2024
14 checks passed
@asyncapi-bot
Copy link
Contributor

🎉 This PR is included in version 1.17.18 🎉

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
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants