don't use python3 syntax in python2
This commit is contained in:
parent
5e843e5ea7
commit
0307fe42f3
1 changed files with 6 additions and 2 deletions
8
service
8
service
|
@ -35,11 +35,15 @@ def limit_output_lines(output, num_lines=10):
|
|||
return output
|
||||
|
||||
more = actual-(num_lines-1)
|
||||
if more > 1:
|
||||
s = 's'
|
||||
else:
|
||||
s = ''
|
||||
|
||||
result = output[:(num_lines-1)]
|
||||
result.append('... and {} more line{s}'.format(
|
||||
result.append('... and {} more line{}'.format(
|
||||
more,
|
||||
's' if more > 1 else '',
|
||||
s,
|
||||
))
|
||||
|
||||
return result
|
||||
|
|
Loading…
Reference in a new issue