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 documentation for new commands #556

Merged
merged 22 commits into from
May 29, 2023

Conversation

mhmohona
Copy link
Contributor

@mhmohona mhmohona commented May 12, 2023

Description

The script is been added has following workflow -

  • Create and update temp README file
  • Generate command help documentation using oclif
  • Extract usage information from README
  • Update the usage.md file with the extracted usage information and a header
  • Append the contents of the README file to the end of the usage file
  • Remove the temp README file

Related issue(s): Resolves: #123

cc: @derberg

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.

just had a great call with @mhmohona on how this PR can be improved 💪🏼

scripts/update_usage_docs.js Outdated Show resolved Hide resolved
@mhmohona
Copy link
Contributor Author

just had a great call with @mhmohona on how this PR can be improved 💪🏼

Thank you so much for your amaizing guideline @derberg ^_^

scripts/updateUsageDocs.js Outdated Show resolved Hide resolved
scripts/updateUsageDocs.js Outdated Show resolved Hide resolved
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.

left two more comments

I think it would make sense to add some note in readme, in development guide section (if we have one, if not, just create) that the given markdown file should not be edited manually as it is generated by the CI

unless we can just generate inside usage.md file some kind of note about it, a note that will be visible in markdown but not on the website, would have to be between <!-- AUTOGENERATED and info how -->

what do you think?

@derberg
Copy link
Member

derberg commented May 18, 2023

@mhmohona so what do you thinks about my comment concerning readme or <!-- AUTOGENERATED and info how -->

@mhmohona
Copy link
Contributor Author

mhmohona commented May 19, 2023

@derberg oh, i typed the reply and forgot to click on comment button :3
Yes, its a great idea! I think in script it should be added instead of readme to keep readme clean which will make users be able to focus. Also how about having a separate doc for something like developer's guild? There all these details would be added so some individual who wants to contribute will easily be able to understand whats going on.

I was also thinking of writing a blog about on which approach I first wanted to go and later on what happened.

@mhmohona mhmohona requested a review from derberg May 21, 2023 03:26
@derberg
Copy link
Member

derberg commented May 23, 2023

@mhmohona definitely sounds good but that is a stuff for separate PR for sure

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.

Awesome work, so let's merge and see what will happen 😄

I will change PR title from feat: too docs: as this is not a library relevant change that requires a release of new CLI version.

now, I just noticed we do not have in CLI an automation that would run assets generation without release

please copy to this repo this workflow -> https://github.com/asyncapi/generator/blob/master/.github/workflows/update-docs-on-docs-commits.yml

and I will suggest additional improvements

but basically

# PR should be created within this GH action only if it is a docs: commit
# Otherwise it will conflict with release workflow
if: startsWith(github.event.commits[0].message, 'docs:')

should be moved under:

name: 'Generate docs and create PR'

and

on:
  push:
    branches:
      - master

should be changed to

on:
  push:
    branches:
      - master

@mhmohona mhmohona changed the title feat: add usage documentation for new commands docs: add usage documentation for new commands May 25, 2023
@mhmohona mhmohona changed the title docs: add usage documentation for new commands docs: update usage documentation for new commands May 25, 2023
@mhmohona mhmohona requested a review from derberg May 25, 2023 10:08
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 🚀

let's merge and see if automation works and usage.md will be updated

@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@derberg
Copy link
Member

derberg commented May 29, 2023

/rtm

@asyncapi-bot
Copy link
Contributor

🎉 This PR is included in version 0.45.1 🎉

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
bounty AsyncAPI Bounty program related label ready-to-merge released
Projects
Status: Completed
Development

Successfully merging this pull request may close these issues.

readme is missing documentation for the new commands
3 participants