Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

nfischer
Copy link
Member

No change to logic, docs change only.

Now that the plugin API is finalized, we should link to the wiki page
documenting the plugin API.

Fixes #391

No change to logic, docs change only.

Now that the plugin API is finalized, we should link to the wiki page
documenting the plugin API.

Fixes #391
@nfischer nfischer added the docs label Nov 10, 2017
@nfischer nfischer self-assigned this Nov 10, 2017
@nfischer nfischer requested a review from freitagbr November 10, 2017 02:04
@nfischer
Copy link
Member Author

@freitagbr can you also give thoughts on this section?

My concerns:

  • it's weird that cmdOptions is 2 different types. Maybe we can use {} to signal "no options"
  • unix is an awful property name. I'm not even sure this functionality should be exposed publicly.
  • We should fail loudly during plugin registration an unknown plugin-option is used.
    • Also fail loudly for bad values (e.g. globStart: true)
    • Also fail loudly for invalid combos (e.g. globStart: 2 with allowGlobbing: false)
  • We should consider auto-generating this table from in-line documentation (this would require moving it to the README, but I don't think this needs to block release).

@freitagbr
Copy link
Contributor

freitagbr commented Nov 10, 2017

Nice, I like this change.

Regarding the wiki section:

  • For cmdOptions, using a boolean usually indicates that true and false are both accepted values. In the case of cmdOptions, passing true doesn't really make sense. Perhaps null would be a better fit here. Or, as you mentioned, and empty object. Also, are we trying to distinguish between "ignoring any flags passed" and "not allowing any flags to be passed"? null and {} might indicate the latter, but not passing cmdOptions at all might indicate the former.
  • Yeah, unix isn't super descriptive, and it sounds like we don't remember its purpose. I would err on the side of removing it, we can always add it later in a minor update.
  • Yeah, failing loudly is a good thing to do for plugin instantiation.
  • I agree, the documentation should be auto-generated, just like the other APIs.

Also, regarding the overWrite option: maybe an error should be thrown instead of just overwriting the previous command. i.e. If Bob is trying to register his git over Alice's git, he should probably just remove Alice's git from his code.

@nfischer
Copy link
Member Author

Closed in favor of #812

@nfischer nfischer closed this Jan 16, 2018
@nfischer nfischer deleted the docs-announce-plugins branch January 16, 2018 07:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants