In most cases Audacity will automatically add a process bar when the process takes more than a few seconds.
For Nyquist plug-ins this does not always happen, and there can be several reasons why not.
One reason is when the Nyquist code itself runs fast, but when it takes Audacity significantly longer to complete the task. This is a common problem when generating long sounds. It is sometimes possible to mitigate this problem by setting the variable LEN to the expected number of samples, somewhere near the beginning of the plug-in.
Another problem is when the Nyquist code makes multiple passes over the audio. When possible it is best to avoid multiple passes within a plug-in.
Basically the problem boils down to the fact that Nyquist is a different app within Audacity, and Audacity has no direct way to know what Nyquist is doing or how long it will take.
I want to display comments (texts) with one progress bar, display only one progress bar until all tasks are completed.
$action "Normalizing ..."
; For task 1
; Display this comment "Normalizing First Track ..." in the same box with the same progress bar)
(aud-do "Select Track 1..." )
(aud-do "Normalize ...")
; Task 2
; Display this comment "Normalizing Second Track ..." in the same box with the previous progress bar)
(aud-do "Select Track 2 ...")
(aud-do "Normalize")
; Task 3 and so
; Display a comment "..."
(aud-do ...)