Progress bar
I have written a BaseX script (which applies a few functions to files in a directory), which I run at the command line. Is there a "trick" to get a progress bar for that (other than calling BaseX from a different programming language having some progress bar library)? Thanks.
Best, Giuseppe
Hi Giuseppe,
Quoted text · Giuseppe G. A. Celano · 1 line
> I have written a BaseX script (which applies a few functions to files in a directory), which I run at the command line. Is there a "trick" to get a progress bar for that (other than calling BaseX from a different programming language having some progress bar library)? Thanks.
If you run your script on command line, I guess you’d want to have the progress bar rendering on command line as well, right?
I would probably include some prof:dump or fn:trace calls in the code (the output cannot cope with a real progress bar, though).
Cheers, Christian
Hi Christian,
Great! I am using trace((), “my message"). Do you know if there is a way to avoid printing the parentheses ()?
Ciao, Giuseppe
Quoted text · Christian Grün · 15 lines
> On 11. Nov 2020, at 12:19, Christian Grün <christian.gruen at gmail.com> wrote: > > Hi Giuseppe, > >> I have written a BaseX script (which applies a few functions to files in a directory), which I run at the command line. Is there a "trick" to get a progress bar for that (other than calling BaseX from a different programming language having some progress bar library)? Thanks. > > If you run your script on command line, I guess you’d want to have the > progress bar rendering on command line as well, right? > > I would probably include some prof:dump or fn:trace calls in the code > (the output cannot cope with a real progress bar, though). > > Cheers, > Christian >
prof:dump('my message') might do the job.Giuseppe G. A. Celano <celano at informatik.uni-leipzig.de> schrieb am Mi., 11. Nov. 2020, 20:31:
Quoted text · Giuseppe G. A. Celano · 33 lines
> Hi Christian, > > Great! I am using trace((), “my message"). Do you know if there is a way > to avoid printing the parentheses ()? > > Ciao, > Giuseppe > > > > > On 11. Nov 2020, at 12:19, Christian Grün <christian.gruen at gmail.com> > wrote: > > Hi Giuseppe, > > I have written a BaseX script (which applies a few functions to files in a > directory), which I run at the command line. Is there a "trick" to get a > progress bar for that (other than calling BaseX from a different > programming language having some progress bar library)? Thanks. > > > If you run your script on command line, I guess you’d want to have the > progress bar rendering on command line as well, right? > > I would probably include some prof:dump or fn:trace calls in the code > (the output cannot cope with a real progress bar, though). > > Cheers, > Christian > > >
Written for BaseX 9.4. BaseX may have changed since: please check the current documentation.