auto icon indicating copy to clipboard operation
auto copied to clipboard

Docs inconsistency for hook overview

Open bnigh opened this issue 3 years ago • 3 comments

Describe the bug

The diagram detailing when hooks (especially release lifecycle hooks) are invoked for each command are incredibly useful when writing a plugin or trying to understand how different plugins will behave together. However, when tracing through the code, I've noticed the following inconsistency(ies) between the diagram and the implementation:

  • next flow invokes makeRelease hook, but is missing from diagram

This can lead to confusion especially in relation to existing discussions of potential hook refactoring, ie:

  • https://github.com/intuit/auto/issues/1054#issuecomment-780236482
  • https://github.com/intuit/auto/issues/917

Additional context

Since the diagrams are images, it makes it difficult for others to contribute when flows / hooks are changed. I'm not familiar with the static site generation tooling, but would it be possible to diagram within the markdown itself using something like https://mermaid-js.github.io/mermaid/#/flowchart?

bnigh avatar May 10 '21 20:05 bnigh

Yeah that's would be a really good enhancement for the graph! I would def accept a PR for this!

hipstersmoothie avatar May 21 '21 20:05 hipstersmoothie

@hipstersmoothie I would be glad to contribute on this. Can you please assign this to me?

I can start with migrating the existing diagrams to dynamic ones, and following to that, we can modify the graphs as needed. What do you say?

vamshisuram avatar Nov 07 '21 17:11 vamshisuram

Just FYI for anyone visiting this thread, I am working on this. Thank you.

vamshisuram avatar Nov 08 '21 01:11 vamshisuram