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

Precise GitHub links for editing documentation #340

Open
1 task done
zzap opened this issue Sep 20, 2019 · 6 comments
Open
1 task done

Precise GitHub links for editing documentation #340

zzap opened this issue Sep 20, 2019 · 6 comments

Comments

@zzap
Copy link
Contributor

zzap commented Sep 20, 2019

Feature Request

Problem

When visiting a command documentation page, such as wp cli alias I would expect that contributing to this page is where the GitHub icon would take me.

GitHub link to command

However, this link just leads to wp-cli/wp-cli repo, as does the wp cli command. This makes it very difficult to find the the correct place for contributing with documentation.

Even with other commands, with separate GitHub repositories, this link goes only to the repo itself requiring from contributor to find the exact file and line in code.

This means that contributing to documentation requires deep understanding of how the project is organised and how the parser works, which is really unnecessary and can have effect in people not bothering to contribute.

Proposal

If GitHub links would lead to exact file and line (the first line of docs block) it would make contributing so much more easier and flowing experience.

@schlessera
Copy link
Member

The GitHub icon is indeed meant to represent the repository as a whole, with the buttons next to it providing repository-specific actions. Also, to be honest, it is even hard to recognize it does something, as it doesn't look like a link or button.

I think it would be preferable to adapt this so that it falls in line with the "Handbook" part of the documentation, so that there's an "Edit" button next to the title of the section:
Image 2019-09-20 at 5 34 51 PM
What do you think about that approach?

@zzap
Copy link
Contributor Author

zzap commented Sep 20, 2019 via email

@zzap
Copy link
Contributor Author

zzap commented Sep 21, 2019

Here's the document where I started adding links to GitHub file/line of code for each command.

https://docs.google.com/spreadsheets/d/1De8NXFRAzRofGjzHigSbdbiGpuFwZLLyNomiFhKnd3Y/edit?usp=sharing

I hope to get them all done soon.

@schlessera
Copy link
Member

@zzap Oh no, I think you misunderstood me.
This should automatically generated based on the source code. Otherwise we'll have hundreds of links we'll need to check after each code change. Please don't waste more time on this, I'll write a parser to extract this data out of the source files.

@zzap
Copy link
Contributor Author

zzap commented Sep 22, 2019 via email

@schlessera
Copy link
Member

We already try to simplify this by providing an overview in the issue templates: https://github.com/wp-cli/.github/blob/master/.github/ISSUE_TEMPLATE/1-BUG_REPORT.md#L20-L44

But yes, additional documentation in the handbook itself would be better.

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

No branches or pull requests

2 participants