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.rs links from inotify to inotify_sys are broken #212

Closed
eric-seppanen opened this issue Feb 7, 2024 · 4 comments · Fixed by #213
Closed

docs.rs links from inotify to inotify_sys are broken #212

eric-seppanen opened this issue Feb 7, 2024 · 4 comments · Fixed by #213

Comments

@eric-seppanen
Copy link
Contributor

The docs for each of the WatchMask and EventMask variants try to link to the docs.rs page for inotify_sys, but the links are all broken.

For example:
https://docs.rs/inotify/latest/inotify_sys/constant.IN_ACCESS.html is 404.

It should be:
https://docs.rs/inotify-sys/latest/inotify_sys/constant.IN_ACCESS.html

@hannobraun
Copy link
Owner

Thanks for opening this issue, @eric-seppanen! I don't think I can get to this any time soon, but I'd be happy to merge a pull request that fixes this.

@eric-seppanen
Copy link
Contributor Author

eric-seppanen commented Feb 9, 2024

I think that this can be fixed by using the "by name" link style. This emits an identical-looking page, and the links work locally. As I can tell from reading github issues it will also work on docs.rs.

Would this style be acceptable?

        /// File was accessed
        ///
        /// When watching a directory, this event is only triggered for objects
        /// inside the directory, not the directory itself.
        ///
        /// See [`inotify_sys::IN_ACCESS`].
        const ACCESS = ffi::IN_ACCESS;

@eric-seppanen
Copy link
Contributor Author

I notice there are a lot of places where the docs unnecessarily specify html paths to other items. I think this hasn't been necessary since Rust 1.48, so it would be straightforward to do a cleanup pass removing things like

/// [`WatchMask`]: struct.WatchMask.html

... as long as the symbol is in scope.

@hannobraun
Copy link
Owner

Thanks for looking into this, @eric-seppanen!

Would this style be acceptable?

Absolutely.

I notice there are a lot of places where the docs unnecessarily specify html paths to other items. I think this hasn't been necessary since Rust 1.48

This crate is old 😂

First commit in April 2014, so almost 10 years!


I just saw, after writing this, that you also submitted a pull request. Looking into it now!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants