Link to specific line(s) of code in stash / bitbucket?

In BitBucket, an URL should end with #lines-x:y

Example:

https://bitbucket.org/stangenberg/docker-docker/src/1ac537b84855db2cc5ee0caf31c782900e094d8e/docker.sh#lines-13:15

Regarding Stash (now 2019+ renamed BitBucket Server), Stash 3.8 in 2015 is supposed to support deep linking with multiline selection. Issue BSERV-2477

With just shift+click, a developer can select a range of lines, then add separate lines to the selection with command+click (or control+click), then copy the URL and share their selection with other developers.

https://info.seibert-media.net/download/attachments/11113140/Stash-38.png?version=1&modificationDate=1474904524000&api=v2

The OP confirms in the comments:

The stash url generated has #13-15 at the end, i.e. it is of the form:

https://bitbucket.org/stangenberg/docker-docker/src/1ac537b84855db2cc5ee0caf31c782900e094d8e/docker.sh#13-15

As cellepo notes in the comments:

  • this cannot be done in a pull request/code-review page (https://bitbucket.../pull-requests/...),
    but
  • it CAN be done on a source page (https://bitbucket.../src/...) like in the aforementioned example URL.