Ability to link to a line of code #738

tylerball opened this Issue Apr 25, 2012 · 7 comments

9 participants


It would be awesome if you could click on line numbers in a file preview and retrieve a permalink to that specific line.

GitLab member

+1 on this, would be useful




In the commit I referenced you will find the changes I made to implement this feature for my own install of gitlab.
For the record, the lineseparator option is not required, but made for more readable source output while I was debugging this and I chose to leave it.

Another thing to note is that when you click the links in line numbers it does the 'woosh' animation that happens when you open a file from the tree. This should probably be avoided with some fancy javascript to conditionally do history.pushState only on the pages initial load or something? Because it also causes another browser history entry every to be made every time you click a line number.

@NARKOZ NARKOZ was assigned Sep 16, 2012

Just landed on master (see #1937). :)

@riyad riyad closed this Jan 11, 2013

Line-range would be nice :)

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