1

I'm trying to set klish startup timeout tag using a defined internal VAR but it's not working.

<VAR name="IDLE_TIMEOUT" 
    help="idle timeout value" 
    dynamic="true">
    <ACTION>
        echo -n "60" 
    </ACTION>
</VAR>
<STARTUP view="myview" 
    timeout="${IDLE_TIMEOUT}">
    <ACTION>
        cat /etc/banner
    </ACTION>
</STARTUP>

It seems that the variable it not evaluated before calling clish_shell__set_timeout function.

The timeout tag is working fine if I use a fixed value instead of a variable, e.g.

<STARTUP view="myview" 
    timeout="60">
    <ACTION>
        cat /etc/banner
    </ACTION>
</STARTUP>

I'm running klish 1.7.1.

https://src.libcode.org/pkun/klish/src/2.2/doc/klish.md

Do you have any suggestion or any workaround to make it work?

Thank you!

neoben
  • 743
  • 12
  • 30

1 Answers1

0

It seems that the timeout field is not implemented to be set dynamically, it's static and supports digits only.

For more reference take a look at the related issue on the official repository:

http://libcode.org/issues/30

neoben
  • 743
  • 12
  • 30