2 # makefile helper to extract various settings from config/config.ini
3 # $Id: make-dbhelper.pl,v 1.2 2004-07-01 08:15:10 rurban Exp $
5 #if ($v eq 'DATABASE_TYPE' and /^\s*DATABASE_TYPE\s*=\s*(\w+)/) {
11 if ($v eq 'DATABASE_DSN' and /^\s*DATABASE_DSN\s*=\s*"?([\w:\/@]+)/) {
14 $dsn =~ /^(.+?):\/\// and $result .= "$1 "; # backend
15 $dsn =~ /.+\/(.+?)$/ and $result .= "$1 "; # database: everything after the last slash
16 $dsn =~ /:\/\/(\w+):/ and $result .= "$1 "; # username (optional)
17 $dsn =~ /:\/\/\w+:(\w+)@/ and $result .= "$1 "; # password (optional)
22 if ($v ne 'DATABASE_DSN') {
23 if (/^\s*$v\s*=\s*"?([^;]+)$/) {