cmd.rst
changeset 215 44ae18f7c0aa
parent 99 0fa8ff78a008
child 216 89e2ee90bc4c
equal deleted inserted replaced
209:c51f51e9a015 215:44ae18f7c0aa
     1 -*- outline -*-
     1 -*- outline -*-
       
     2 
       
     3 * Variables.
       
     4 
       
     5 Variable name start with letter and underscore, next chars can be letter,
       
     6 number and underscore. Variable name is case insensitive.
       
     7 
       
     8 ** List of variables.
       
     9 
       
    10   cmd> set
       
    11 ...
       
    12 VAR=VALUE
       
    13 
       
    14 ** Getting.
       
    15 
       
    16 Write %VAR% in place where you want insert variable VAr value.
       
    17 
       
    18 ** Setting.
       
    19 
       
    20   cmd> set /p VAR=VALUE
       
    21 
       
    22 VAR is variable name, VALUE is value.
       
    23 
       
    24 ** Deleting.
       
    25 
       
    26   cmd> set VAR=
       
    27 
       
    28 VAR is variable name.
       
    29 
       
    30 *** Input from user.
       
    31 
       
    32   cmd> set /p VAR=PROMPT
       
    33 
       
    34 VAR is variable name, PROMPT is displayed prompt.
       
    35 
       
    36 *** Input from file.
       
    37 
       
    38   cmd> set /p VAR=<FILE
       
    39 
       
    40 VAR is variable name, FILE is file name. Sfter executing VAR contain first
       
    41 line from FILE.
     2 
    42 
     3 * CMD tricks.
    43 * CMD tricks.
     4 
    44 
     5   $ set /p TOOLOUTPUT= < temp.txt
    45   $ set /p TOOLOUTPUT= < temp.txt
     6 
    46