%prompt pragma - response command in Command Runner

Modified on Mon, Feb 9 at 9:05 AM

NetLD has an internal program that allows you to alter what the command runner will expect as a response for a given command. You can use it both Smart Change/Command Runner.


The %prompt pragma indicates to netLD to wait for the given prompt after issuing the next command.

Also, the pragma will only take effect for the single command, if there is another command that changes the prompt elsewhere, then you'll need a separate prompt program set for that command as well.


Something like this:



By putting this "%prompt=" line before the command it will change what the command runner expects as a response.


Here are some additional commands that can be used:


 

Directive
Description



 `%defaultPrompt=<text>`   
Set literal prompt pattern to match 
`%defaultPromptRegex=<regex>`
Set regex prompt pattern to match 
%prompt=<text>`  
Temporary prompt override for next command only 
`%prompt=nowait`  
Send next command without waiting for response 
 `%responseTimeout=<seconds>`
Override response timeout for next command 
 `%dontExit`  
Keep CLI session open after commands complete 
 `%sleep <seconds>`  
Pause execution for specified seconds 
`%ctrl-<char>`  
Send control character (e.g., `%ctrl-c` sends Ctrl+C) 
 ``!<text>`       
 Comment line (skipped, unless inside banner block) 



Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article