Schneespur — Open-source winter service documentation software (PWA + Admin). GPS tracking via OwnTracks, weather data, photo evidence, and legally compliant service records for winter maintenance operators. License: AGPL-3.0-or-later
34 lines
574 B
PHP
34 lines
574 B
PHP
<?php
|
|
|
|
namespace Safe;
|
|
|
|
use Safe\Exceptions\RpminfoException;
|
|
|
|
/**
|
|
* @param int $tag
|
|
* @throws RpminfoException
|
|
*
|
|
*/
|
|
function rpmaddtag(int $tag): void
|
|
{
|
|
error_clear_last();
|
|
$safeResult = \rpmaddtag($tag);
|
|
if ($safeResult === false) {
|
|
throw RpminfoException::createFromPhpError();
|
|
}
|
|
}
|
|
|
|
|
|
/**
|
|
* @param string $text
|
|
* @throws RpminfoException
|
|
*
|
|
*/
|
|
function rpmdefine(string $text): void
|
|
{
|
|
error_clear_last();
|
|
$safeResult = \rpmdefine($text);
|
|
if ($safeResult === false) {
|
|
throw RpminfoException::createFromPhpError();
|
|
}
|
|
}
|