diff --git a/src/var/lib/tyto/program/show.py b/src/var/lib/tyto/program/show.py index 6f7a266..3d571a8 100644 --- a/src/var/lib/tyto/program/show.py +++ b/src/var/lib/tyto/program/show.py @@ -145,12 +145,13 @@ def read_lines(f): if not tyto.exists(f): logs.out("1", f, True) datas = open(f).read() + + # Align content line, after line number ln_datas = len(datas.splitlines()) + 1 sp_max = len(str(ln_datas)) - spaces = '%s'%(sp_max * " ") + for ln, line in enumerate(datas.rsplit('\n'), 1): sp = sp_max - len(str(ln)) - print(' ā”‚ %s %sā”‚ %s'%(ln, int(sp) * " ", line)) dom.valid()