QUESTION: How can I make this progressbar to only print in the end of the command line so i can continue printing elsestuff in the console ?
I have made a progress bar, source code below:
def progressbar(percentage, info=''):
if percentage > float(0.99):
percentage = 1.0
percent = 100 * percentage
if percent > 2:
percent /= 2
percent = int(percent) + 1
perstr = "█"
for _ in range(percent):
perstr += "█"
print("%{:.2f} {}{:51.51}{} {:17.17}".format(percentage*100, "[", perstr, "]", info), end='\r')
And the result is this: %91.04 [███████████████████████████████████████████████ ] Info Section
* think of kali linux console progress bar *