修改 apt 命令

This commit is contained in:
whyour
2026-03-01 20:36:42 +08:00
parent 0215b7f3a8
commit d4e3fde32a
6 changed files with 25 additions and 25 deletions
+8 -8
View File
@@ -60,19 +60,19 @@ export const LINUX_DEPENDENCE_COMMAND: Record<
}
> = {
Debian: {
install: 'apt install -y',
uninstall: 'apt remove -y',
info: 'apt info',
install: 'apt-get install -y',
uninstall: 'apt-get remove -y',
info: 'dpkg-query -s',
check(info: string) {
return info.includes('apt-manual-installed');
return info.includes('install ok installed');
},
},
Ubuntu: {
install: 'apt install -y',
uninstall: 'apt remove -y',
info: 'apt info',
install: 'apt-get install -y',
uninstall: 'apt-get remove -y',
info: 'dpkg-query -s',
check(info: string) {
return info.includes('apt-manual-installed');
return info.includes('install ok installed');
},
},
Alpine: {
+2 -2
View File
@@ -691,7 +691,7 @@ async function _updateLinuxMirror(
currentDomainWithScheme,
mirrorDomainWithScheme || 'http://deb.debian.org',
);
return 'apt update';
return 'apt-get update';
} else {
throw Error(`Current mirror domain not found.`);
}
@@ -704,7 +704,7 @@ async function _updateLinuxMirror(
currentDomainWithScheme,
mirrorDomainWithScheme || 'http://archive.ubuntu.com',
);
return 'apt update';
return 'apt-get update';
} else {
throw Error(`Current mirror domain not found.`);
}