Inifile

Documentation > Inifile






---- Complete Syntax $ directives ----
The inifile contain "tcbl script" under "Scipt_Name".

[Script_Name]

ini=? parameters TCBL initialization
     ini= nStart nStep Initialize the file counter to nStart and set nStep as step !
     ini=# TimeFormatStr Initialize time format for file information
     ini=q do not quote $directives
     ini=Q do not quote and preserve % sign in $directives
     ini=C codepage set codePage.
     ini=o outputfile file used as output
     ini=a outputfile file used as output in append mode. The file will not be deleted.
     ini=k Keep output file
     ini=d Delete output file, specially used in append mode.
     ini=x Command to Execute command used to launch output file
     ini=X Command to Execute with all parameters command used to launch output file using $- inside command.
     ini=x do not execute any command
     ini=t Console Title set Console Title !
     ini=1 Title \t Query \t Default value
     ini=2 ... define internal parameter $_1 to $_9
     ini=9 ... Separator is TAB \t

     ini=1F Title \t Filter \t Initial PATH
     ini=2f...Separator is TAB (\t, )
     ...... Graphical File Chooser for Internal param $_1 $_2 .. $_9
     .....sep. for Filter is | ex:All Files|*.*|Text|*.txt;*.rtf;*.doc
     ....F means file must exist (used for input)
     ....f means file can not exist (used for output).


pre=script preparation
...
; comments start with ;

cmd=(<('Op'?'Topic' : )?'Regular Expression/value'> )? command for each file.
...
'Op'    is an optional operator '!' not, '=' Egal, '#' different. (Special meaning for Size)
'Topic' is optionnal and can be one of 'f' 'p' 'e' 'z' 'v' 'n'
'Topic' can also be F regular file, D directory, E do not exists.
'Topic' can also be P or O for internal file counter is Pair or Odd.
Topic can be 'o' Counter MODULO Divisor = Rest.
Topic can be 's' Size is >= to the number in byte
S a m p l e s
      cmd=<xxx|yyy>command for each file extension like xxx or yyy
      cmd=<z:A.*Z>command for each file starting with A and ending with Z
      cmd=<v:A|B|E>command for each fileName on Drive A: or B: or E:
      cmd=<o:5 0>command for each file where counter MODULO 5 = 0
      cmd=<!o:10 5>command for each file where counter MODULO 10 <> 5
      cmd=<s:1024>command for each file where size >= 1024 bytes
      cmd=<!s:1024>command for each file where size < 1024 bytes
      cmd=<=s:1.0E5>command for each file where size = 1.0E5 bytes
      cmd=<#s:1024.0>command for each file where size <> 1024 bytes
The default 'Topic' is the filename extension e

end=command for finalization
...

You can pass up to 9 parameters to scripts, an reuse them with $1 $2 $3 ... $9.
$0 represent tcbl full executable name.
$0- represent tcbl folder.

You can also use internal parameters $_1 to $_9 defined in ini section.
You can retrieve the listFile name using $L. directive, you can get output file using $-.
You can have 0 to n 'initialization line' pre=
plus 0 to n 'command line' executed for each filtered file cmd=
Plus 0 to n 'finalization line'. end=
and as many comment line as you wish... ;