Name : perl-AppConfig
| |
Version : 1.71
| Vendor : obs://build_opensuse_org/devel:languages:perl
|
Release : lp154.1.1
| Date : 2023-01-27 16:02:18
|
Group : Development/Libraries/Perl
| Source RPM : perl-AppConfig-1.71-lp154.1.1.src.rpm
|
Size : 0.19 MB
| |
Packager : https://www_suse_com/
| |
Summary : Perl5 module for reading configuration files and parsing command line arguments
|
Description :
AppConfig is a Perl5 module for managing application configuration information. It maintains the state of any number of variables and provides methods for parsing configuration files, command line arguments and CGI script parameters.
Variables values may be set via configuration files. Variables may be flags (On/Off), take a single value, or take multiple values stored as a list or hash. The number of arguments a variable expects is determined by its configuration when defined.
verbose nohelp debug = On
home = /home/abw/
file = /tmp/file1 file = /tmp/file2
book camel = Programming Perl book llama = Learning Perl
The \'-\' prefix can be used to reset a variable to its default value and the \'+\' prefix can be used to set it to 1
-verbose +debug
Variable, environment variable and tilde (home directory) expansions can be applied (selectively, if necessary) to the values read from configuration files:
home = ~ # home directory nntp = ${NNTPSERVER} # environment variable html = $home/html # internal variables img = $html/images
Configuration files may be arranged in blocks as per the style of Win32 \"INI\" files.
[file] site = kfs src = ~/websrc/docs/$site lib = ~/websrc/lib dest = ~/public_html/$site
[page] header = $lib/header footer = $lib/footer
You can also use Perl\'s \"heredoc\" syntax to define a large block of text in a configuration file.
multiline = < < FOOBAR line 1 line 2 FOOBAR
paths exe = \"${PATH}:${HOME}/.bin\" paths link = < < \'FOO\' ${LD_LIBARRAY_PATH}:${HOME}/lib FOO
Variables may also be set by parsing command line arguments.
myapp -verbose -site kfs -file f1 -file f2
AppConfig provides a simple method (args()) for parsing command line arguments. A second method (getopt()) allows more complex argument processing by delegation to Johan Vroman\'s Getopt::Long module.
AppConfig also allows variables to be set by parameters passed to a CGI script via the URL (GET method).
http://www.nowhere.com/cgi-bin/myapp?verbose&site=kfs
|
RPM found in directory: /packages/linux-pbone/ftp5.gwdg.de/pub/opensuse/repositories/devel:/languages:/perl:/CPAN-A/15.4/noarch |