use dpkg status
All checks were successful
PikaOS Package Build & Release (amd64-v3) / build (push) Successful in 2m41s
All checks were successful
PikaOS Package Build & Release (amd64-v3) / build (push) Successful in 2m41s
This commit is contained in:
parent
60d904b9a1
commit
707589ec6a
2
.github/release-nest-v3
vendored
2
.github/release-nest-v3
vendored
@ -1 +1 @@
|
||||
1
|
||||
2
|
10
data/check-pkg.sh
Executable file
10
data/check-pkg.sh
Executable file
@ -0,0 +1,10 @@
|
||||
#! /usr/bin/bash
|
||||
export LANG=C
|
||||
|
||||
package=$1
|
||||
if dpkg-query -W -f='${Status}' $package 2>/dev/null | grep -q "install ok installed"
|
||||
then
|
||||
exit 0
|
||||
else
|
||||
exit 1
|
||||
fi
|
@ -37,7 +37,7 @@ then
|
||||
pkg="$1"
|
||||
fi
|
||||
|
||||
if dpkg -s "$1"
|
||||
if /usr/lib/pika/drivers/check-pkg.sh "$1"
|
||||
then
|
||||
if echo $pkg | grep -i mesa
|
||||
then
|
||||
@ -94,7 +94,7 @@ then
|
||||
pkg="$1"
|
||||
fi
|
||||
|
||||
if dpkg -s "$1"
|
||||
if /usr/lib/pika/drivers/check-pkg.sh "$1"
|
||||
then
|
||||
if echo $pkg | grep -i mesa
|
||||
then
|
||||
|
2
debian/changelog
vendored
2
debian/changelog
vendored
@ -1,4 +1,4 @@
|
||||
pika-drivers (1.0.0-101pika1) pika; urgency=medium
|
||||
pika-drivers (1.0.0-101pika2) pika; urgency=medium
|
||||
|
||||
* Update for PikaOS 4
|
||||
|
||||
|
@ -326,8 +326,8 @@ fn get_drivers(
|
||||
let driver_package_removeble = driver.removeble.to_owned();
|
||||
|
||||
gio::spawn_blocking(move || loop {
|
||||
let command_installed_status = Command::new("dpkg")
|
||||
.args(["-s", &driver_package_ind2])
|
||||
let command_installed_status = Command::new("/usr/lib/pika/drivers/check-pkg.sh")
|
||||
.arg(&driver_package_ind2)
|
||||
.output()
|
||||
.unwrap();
|
||||
if command_installed_status.status.success() {
|
||||
|
Loading…
Reference in New Issue
Block a user