-
Notifications
You must be signed in to change notification settings - Fork 95
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
add "edit file" and "browse repo" links #883
base: main
Are you sure you want to change the base?
Conversation
extend SearchResult with two new maps RepoEditURLs and RepoBrowseURLs
Thank you for your pull request and welcome to our community. We could not parse the GitHub identity of the following contributors: Daniel Schiemann.
|
I added my email address to my GitHub account, but I can't find a way to re-run the failed check. |
@cla-bot check |
We require contributors to sign our Contributor License Agreement (CLA), and we don't have yours on file. In order for us to review and merge your code, please sign CLA to get yourself added. Sourcegraph teammates: |
The GitHub CLA Bot is rechecking to see that you have signed the CLA - note that it may take up to 30 minutes for your response to be synchronized. For Sourcegraph teammates: see how-to diagnose CLA Bot failures. |
Hey @dschiemann80 could you try signing the CLA again? Seems your information didn't get persisted 🙏🏼 |
I signed the CLA now, first had to clarify with my employer. |
I converted this PR into a draft, because I have a few questions after researching yesterday and I am not sure if the PR in this form is the way to go forward. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dschiemann80 thanks for your interest in Zoekt!
SearchResult
is a core struct in the API, which we try to keep quite streamlined. Instead of storing this information in Zoekt, would it be possible to create the repo browse and edit URLs in your application? Maybe you could transform the RepoURLs
, which are already available on the search result. Or these really need to be in Zoekt for some reason?
Hi zoekt-Team,
I am using zoekt with a neogrok frontend. I would like to be able to display more links in the neogrok search results. I extended the zoekt SearchResult with two new maps RepoEditURLs and RepoBrowseURLs.
RepoEditURLs is a map repo => template for generating deep-links directly to Edit pages of source code in web interfaces (I added as many templates to gitindex/index.go as I could).
RepoBrowseURLs is a map => string for links leading to the repository the file match in the search result is contained in.
Please review and tell me if you think this is useful.
Regards,
Daniel