Use an INI-style configuration file
[aur.git] / scripts / aurblup / aurblup-wrapper
blobc7b20afe920dcfd0acda8b85511b889d7cd1645d
1 #!/usr/bin/php
2 <?php
3 $dir = $argv[1];
5 if (empty($dir)) {
6 echo "Please specify AUR directory.\n";
7 exit;
10 set_include_path(get_include_path() . PATH_SEPARATOR . "$dir/lib");
11 include("confparser.inc.php");
13 $user = config_get('database', 'user');
14 $password = config_get('database', 'password');
15 $name = config_get('database', 'name');
17 exec($dir . "/../scripts/aurblup/aurblup " .
18 "-S /var/run/mysqld/mysqld.sock " .
19 "-u " . escapeshellarg($user) . " " .
20 "-p " . escapeshellarg($password) . " " .
21 "-D " . escapeshellarg($name));