SIGN IN SIGN UP
Textualize / rich UNCLAIMED

Rich is a Python library for rich text and beautiful formatting in the terminal.

0 0 182 Python

Have logger link to proper file line.

Some terminal emulators like iterm2, support anchoring to the line
number:

https://iterm2.com/documentation-one-page.html see Anchor (OSC 8)
section:

     Note: in iTerm2 version 3.4 and later, if the URL has the file scheme and
     a # fragment is present then the semantic history rules will apply
     for opening the file. It may optionally include a line number, like
     file:///tmp/file.txt#123 or line number and column number like
     file:///tmp/file.txt#123:45

This update the logic in the logger so that the line number links the
the corresponding file on the same line.

As I'm not sure whether all terminals support that, I let the  clik on
the file name point to the file itself w/o line numbers.

And for discoverability and user friendliness the colon itself is
unstyled so that it's easier to discover that click on the  filename and
line number are two different targets.
M
Matthias Bussonnier committed
e2b704f2034c2d8fbba651ef0b4d20b204a58dfa
Parent: eb673d1