eyre-rs / color-eyre

Custom hooks for colorful human oriented error reports via panics and the eyre crate
Other
958 stars 57 forks source link

Fix a minor typo in README.md #124

Open vvv opened 1 year ago

pksunkara commented 1 year ago

This might be intentional for docs.rs example?

yaahc commented 1 year ago

This might be intentional for docs.rs example?

I think you're correct. I usually edit the lib.rs top level doc comment and then copy it back into the readme to keep them in lock step. I don't have any objections to changing the github readme to not comment this out since it only adds visual noise in that location, but in the future we should probably automate the process of keeping the two copies in sync better and apply any logic that customizes one vs the other two that system (whatever it ends up looking like, whether its a script or some instructions in documentation).

pksunkara commented 1 year ago

If we want to just to keep it in sync, #![doc = include_str!("README.md")] is easy, but it does not allow any customization IIUC.

yaahc commented 1 year ago

If we want to just to keep it in sync, #![doc = include_str!("README.md")] is easy, but it does not allow any customization IIUC.

oh, yeah actually there's more difference than I initially remembered. Github doesn't allow some of the same html/css shenanigans that docs.rs does, so I have to use screenshots to give nice colored output in the readme, but for docs.rs I use "copy as html" from the output in gnome terminal to have the text match the rest of the docs. I feel like that's a super nice property that I wouldn't want to use, otherwise I'd love to use the include_str approach.

vvv commented 1 year ago

This might be intentional for docs.rs example?

Oh. I wasn't aware of this peculiarity of docs.rs.

Shall we close the PR then?

yaahc commented 1 year ago

Shall we close the PR then?

No, I think it's fine for now, we just may have to fix this again in the future if it accidentally get's reintroduced. Long term I'd like to automate the process of keeping them in sync somehow.