erlef / rebar3_hex

Rebar3 Hex library
Apache License 2.0
101 stars 49 forks source link

Output when missing Hex doc configuration could be improved #263

Closed eproxus closed 2 years ago

eproxus commented 2 years ago

Currently, in projects with "legacy" configuration (no {hex, [{doc, ...}]} configuration the following output is generated when running rebar3 hex and rebar3 hex docs:

$ rebar3 hex docs
===> Verifying dependencies...
===> No valid hex docs configuration found. Docs will will not be generated
Local Password:
===> Published docs for grisp 2.0.0-rc1

I think it is confusing because the "No valid hex docs..." line is red and seems to indicate an error, an then the docs are published anyway (most likely stale since the plug-in will no longer re-generate the docs without the correct undocumented configuration).

starbelly commented 2 years ago

Right, what we can do here for v6.11.x is check to see if there's doc provider config, but then also check to see if there's a doc dir with at least an index file in it, if so, then don't warn.

Likewise, we should omit "Published docs..." if either of the above don't hold true.

starbelly commented 2 years ago

@eproxus Merged bug fix and published v6.11.8 to hex.pm . Closing this as resolved.