If you look at the source of that package, it uses terminal escape 
characters to achieve this: 

    print(io, "\u1b[1G")   # go to first column
    print_with_color(color, io, s)
    print(io, "\u1b[K")    # clear the rest of the line

On Friday, 8 May 2015 11:44:34 UTC+1, Ali Rezaee wrote:
>
> Thanks, René. That package does answer my need.
> It would still be useful to know how to flush the output, just for the 
> reference.
>
> On Fri, May 8, 2015 at 12:40 PM, René Donner <[email protected] 
> <javascript:>> wrote:
>
>> You can see such behaviour implemented in 
>> https://github.com/timholy/ProgressMeter.jl (which might already do what 
>> you want ;-)
>>
>>
>> Am 08.05.2015 um 12:39 schrieb Ali Rezaee <[email protected] 
>> <javascript:>>:
>>
>> > Hi,
>> >
>> > I would like to show the progress of my Julia code while its running. 
>> But I do not want each different percent being printed in a different line 
>> in the command line.
>> > Is there a way to print something and then remove it before a new item 
>> is printed?
>> >
>> > Many thanks,
>>
>>
>

Reply via email to