The create_desc_file command is an utility which help you create description files. It generates automaticaly a skeleton of a description file by reading the configuration file. Then, you just have to edit the file gerated by hand to complete it.
The syntax of the create_desc_file command is:
create_desc_file [options] config_file config_file_type config_file: name of configuration file to read. config_file_type: can be shell, shell_env or keywords. Options: -h|--help this help message -d|--description add a empty description for each entry -t|--type value_type add a default value_type for each entry -l|--length max_length add a default max_length for each entry -s|--size s add a default size for each entry -p|--presence none|all|comment set the 'presence' parameter (default to none): none: all entries are mandatory (don't care of comment lines) all: all entries are optionals (use comment entries) comment: only comment entries in the config file are optional
The result will be print to the standard output, so you have to redirect it in order to save the desc file generated.
The easiest way to use create_desc_file is to call it with the name of the config file
and its type.
For example, if you want to generate a desciption file for editing
environement variables
in your .bash_profile (like in this
example), you just type:
create_desc_file ~/.bash_profile shell_env >desc_file
The first argument is the config file, here the .bash_profile. The second one
is the type
of the configuration file. An explanation
of the different types is available in the reference documentation.
The command is redirected to save the generated desciption file in desc_file.
You can use some options to specify default values to the entries. For example:
create_desc_file --type filename --size 100 fic shell >desc_file
All the entries in desc_file will have a size of 100 and be of type filename.
If you want create_desc_file to use entries that are in comment lines
in the configuration
file, you can use the --presence option. This option can give some strange results
, depending of the comments you have in the config file, particulary
with a config type keyword.
On the following command, all entries in a comment line will be added in the desc file
with the presence entry parameter set to
optional:
create_desc_file --presence optional ~/.bash_profile shell_env >desc_file