Код: Выделить всё
_onToggle(menuItem, state) {
if (state) {
let cmd = ["pkexec", "tee", "/sys/bus/pci/rescan"];
this._write_command(cmd);
} else {
let cmd = ["pkexec", "tee", "/sys/class/sound/card0/device/remove"];
this._write_command(cmd);
}
Код: Выделить всё
sudo tee /sys/bus/pci/rescan
Подробнее здесь: [url]https://stackoverflow.com/questions/79271120/linux-how-to-enable-the-sound-card[/url]