searchcode-server icon indicating copy to clipboard operation
searchcode-server copied to clipboard

Line highlight

Open maxfie1d opened this issue 8 years ago • 3 comments

Is there any way to add highlights to lines of code on searchcode page?

In GitHub, we can add line highlights by adding a parameter like #L6-L10 to code URL.

https://github.com/boyter/searchcode-server/blob/master/pom.xml#L6-L10

image

If line highlight is not available, I would prefer one.

Thank you.

maxfie1d avatar Jul 12 '17 07:07 maxfie1d

Its one of those things I look at every now and then thinking it should be easy to implement. Turns out it never is because of the syntax highlighter that is used.

Something that I should look into more seriously at some point, unless of course someone feels like providing some code to do it.

boyter avatar Jul 12 '17 21:07 boyter

Thanks for your quick reply.

I see what the problem is. I will send a PR if I manage to implement the line highlighting feature.

maxfie1d avatar Jul 14 '17 03:07 maxfie1d

No worries at all. Always happy to take in a PR if you do get a solution going.

boyter avatar Jul 14 '17 06:07 boyter