mirror of
https://gitlab.archlinux.org/archlinux/aurweb.git
synced 2025-02-03 10:43:03 +01:00
Add full support for the new .AURINFO format
This adds full support for the new .AURINFO format used by mkaurball, including support for split packages. The old PKGBUILD parser is still available for compatibility reasons. Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
This commit is contained in:
parent
b558572a2e
commit
fb81bfd8df
2 changed files with 181 additions and 117 deletions
|
@ -815,6 +815,33 @@ function pkgbase_name_from_id($base_id) {
|
|||
return $result->fetch(PDO::FETCH_COLUMN, 0);
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete all packages belonging to a package base
|
||||
*
|
||||
* @param int $base_id The ID of the package base
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
function pkgbase_delete_packages($base_id) {
|
||||
$dbh = DB::connect();
|
||||
$q = "DELETE FROM Packages WHERE PackageBaseID = " . intval($base_id);
|
||||
$dbh->exec($q);
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieve the maintainer of a package base given its ID
|
||||
*
|
||||
* @param int $base_id The ID of the package base to query
|
||||
*
|
||||
* @return int The user ID of the current package maintainer
|
||||
*/
|
||||
function pkgbase_maintainer_uid($base_id) {
|
||||
$dbh = DB::connect();
|
||||
$q = "SELECT MaintainerUID FROM PackageBases WHERE ID = " . intval($base_id);
|
||||
$result = $dbh->query($q);
|
||||
return $result->fetch(PDO::FETCH_COLUMN, 0);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Flag package(s) as out-of-date
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue