inc <setting> [<increment>]
iPXE> set x:int32 5 iPXE> inc x iPXE> show x x:int32 = 6
#!ipxe set idx:int32 0 :loop isset ${net${idx}/mac} || goto loop_done echo net${idx} is a ${net${idx}/chip} with MAC ${net${idx}/mac} inc idx && goto loop :loop_done
Increment the numeric value of the specified configuration setting by the specified increment amount. If no increment amount is explicitly specified, the value will be incremented by one.
If the specified configuration setting does not exist, then it will be treated as having an initial value of zero.
Success | The configuration setting was incremented successfully |
---|---|
Failure | The configuration setting was not incremented successfully |