<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Exchange Server">
<!-- converted from rtf -->
<style><!-- .EmailQuote { margin-left: 1pt; padding-left: 4pt; border-left: #800000 2px solid; } --></style>
</head>
<body>
<font face="Calibri" size="2"><span style="font-size:11pt;">
<div>Great, I'll give it a go then :)</div>
<div> </div>
<div>The type of progress output I'm handling is that of a fixed-width bar that fills up with a certain character (e.g. '*' or '#"). Just like BitBake's own output. </div>
<div> </div>
<div>Moreover I want to generalize it to support multiple weighted stages, e.g.:</div>
<div> </div>
<div> <font face="Courier New">STAGE 1: message</font></div>
<div><font face="Courier New"> [######################]</font></div>
<div> </div>
<div> <font face="Courier New">STAGE 2: message</font><font face="Courier New"> 2</font></div>
<div> <font face="Courier New">[############ ]</font></div>
<div> </div>
<div>To the progress handler, a stage generally looks like:</div>
<div> </div>
<div><font face="Courier New">[ ]</font></div>
<div><font face="Courier New">[# ]</font></div>
<div><font face="Courier New">[## ]</font></div>
<div><font face="Courier New">[### ]</font></div>
<div>… etc.</div>
<div> </div>
<div>Will also try to handle the case of an embedded spinner, e.g.: | / - \ -</div>
<div> </div>
<div>Thanks again for the encouragement <font face="Segoe UI Emoji">:)</font></div>
<div>Chris</div>
<div> </div>
<div> </div>
<div>-----Original Message-----<br>
From: Otavio Salvador [<a href="mailto:otavio.salvador@ossystems.com.br">mailto:otavio.salvador@ossystems.com.br</a>]
<br>
Sent: Saturday, April 14, 2018 5:05 PM<br>
To: LAPLANTE,CHRIS (A-Little Falls,ex1) <chris.laplante@agilent.com><br>
Cc: Patches and discussions about the oe-core layer <openembedded-core@lists.openembedded.org><br>
Subject: Re: [OE-core] Custom progress handlers</div>
<div> </div>
<div>On Sat, Apr 14, 2018 at 11:56 AM, Chris Laplante via Openembedded-core <<a href="mailto:openembedded-core@lists.openembedded.org">openembedded-core@lists.openembedded.org</a>> wrote:</div>
<div>> I have implemented a simple custom progress handler in </div>
<div>> bitbake/lib/bb/progress.py. It’s designed to handle bar-style </div>
<div>> progress. To use it for my shell tasks, I have modified </div>
<div>> “exec_func_shell” in bitbake/lib/bb/build.py. It’s implemented as a new value for the “progress”</div>
<div>> varflag.</div>
<div>></div>
<div>> Is there a better, more extensible way to add a custom progress </div>
<div>> handler that doesn’t require modifying progress.py and build.py? It </div>
<div>> would be nice to be able to specify the name of the progress handler </div>
<div>> class to use (e.g. via a [progress-class] varflag) and then have build.py dynamically instantiate it.</div>
<div>> Is that possible? If so, would OE be interested in a patch to implement it?</div>
<div> </div>
<div>I see no problem in adding it; I am curious about your custom handler as well :-)</div>
<div> </div>
<div>-- </div>
<div>Otavio Salvador O.S. Systems</div>
<div><a href="http://www.ossystems.com.br">http://www.ossystems.com.br</a> <a href="http://code.ossystems.com.br">http://code.ossystems.com.br</a></div>
<div>Mobile: +55 (53) 9981-7854 Mobile: +1 (347) 903-9750</div>
<div> </div>
</span></font>
</body>
</html>