mirror of
https://github.com/moparisthebest/pacman
synced 2024-11-10 11:35:00 -05:00
Remove ALPM_QUESTION_LOCAL_NEWER
Remove a question that hasn't been used since the 3.0 days. To prevent us from having an ugly enum of questions that is missing a bitmask, this changes the API of the hidden --ask option. Signed-off-by: Connor Behan <connor.behan@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
This commit is contained in:
parent
ee3b70c4a9
commit
b8c8447971
@ -405,10 +405,9 @@ typedef enum _alpm_question_t {
|
|||||||
ALPM_QUESTION_REPLACE_PKG = (1 << 1),
|
ALPM_QUESTION_REPLACE_PKG = (1 << 1),
|
||||||
ALPM_QUESTION_CONFLICT_PKG = (1 << 2),
|
ALPM_QUESTION_CONFLICT_PKG = (1 << 2),
|
||||||
ALPM_QUESTION_CORRUPTED_PKG = (1 << 3),
|
ALPM_QUESTION_CORRUPTED_PKG = (1 << 3),
|
||||||
ALPM_QUESTION_LOCAL_NEWER = (1 << 4),
|
ALPM_QUESTION_REMOVE_PKGS = (1 << 4),
|
||||||
ALPM_QUESTION_REMOVE_PKGS = (1 << 5),
|
ALPM_QUESTION_SELECT_PROVIDER = (1 << 5),
|
||||||
ALPM_QUESTION_SELECT_PROVIDER = (1 << 6),
|
ALPM_QUESTION_IMPORT_KEY = (1 << 6)
|
||||||
ALPM_QUESTION_IMPORT_KEY = (1 << 7)
|
|
||||||
} alpm_question_t;
|
} alpm_question_t;
|
||||||
|
|
||||||
/** Question callback */
|
/** Question callback */
|
||||||
|
@ -382,15 +382,6 @@ void cb_question(alpm_question_t event, void *data1, void *data2,
|
|||||||
*response = select_question(count);
|
*response = select_question(count);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case ALPM_QUESTION_LOCAL_NEWER:
|
|
||||||
if(!config->op_s_downloadonly) {
|
|
||||||
*response = yesno(_("%s-%s: local version is newer. Upgrade anyway?"),
|
|
||||||
alpm_pkg_get_name(data1),
|
|
||||||
alpm_pkg_get_version(data1));
|
|
||||||
} else {
|
|
||||||
*response = 1;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
case ALPM_QUESTION_CORRUPTED_PKG:
|
case ALPM_QUESTION_CORRUPTED_PKG:
|
||||||
*response = yesno(_("File %s is corrupted (%s).\n"
|
*response = yesno(_("File %s is corrupted (%s).\n"
|
||||||
"Do you want to delete it?"),
|
"Do you want to delete it?"),
|
||||||
|
@ -36,7 +36,7 @@ self.addpkg2db("sync", packageA5up)
|
|||||||
|
|
||||||
|
|
||||||
self.option["IgnorePkg"] = ["packageA3"]
|
self.option["IgnorePkg"] = ["packageA3"]
|
||||||
self.args = "-S packageA1 packageA2 --ask=32"
|
self.args = "-S packageA1 packageA2 --ask=16"
|
||||||
|
|
||||||
self.addrule("PACMAN_RETCODE=0")
|
self.addrule("PACMAN_RETCODE=0")
|
||||||
self.addrule("PKG_VERSION=packageA1|1.0-1")
|
self.addrule("PKG_VERSION=packageA1|1.0-1")
|
||||||
|
@ -18,7 +18,7 @@ sp3.depends = ["gcc-libs"]
|
|||||||
for p in sp1, sp2, sp3:
|
for p in sp1, sp2, sp3:
|
||||||
self.addpkg2db("sync", p)
|
self.addpkg2db("sync", p)
|
||||||
|
|
||||||
self.args = "-Su --ignore %s --ask=32" % sp1.name
|
self.args = "-Su --ignore %s --ask=16" % sp1.name
|
||||||
|
|
||||||
self.addrule("PACMAN_RETCODE=0")
|
self.addrule("PACMAN_RETCODE=0")
|
||||||
self.addrule("PKG_VERSION=glibc|1.0-1")
|
self.addrule("PKG_VERSION=glibc|1.0-1")
|
||||||
|
@ -18,7 +18,7 @@ sp3.depends = ["b_gcc-libs"]
|
|||||||
for p in sp1, sp2, sp3:
|
for p in sp1, sp2, sp3:
|
||||||
self.addpkg2db("sync", p)
|
self.addpkg2db("sync", p)
|
||||||
|
|
||||||
self.args = "-Su --ignore %s --ask=32" % sp1.name
|
self.args = "-Su --ignore %s --ask=16" % sp1.name
|
||||||
|
|
||||||
self.addrule("PACMAN_RETCODE=0")
|
self.addrule("PACMAN_RETCODE=0")
|
||||||
self.addrule("PKG_VERSION=c_glibc|1.0-1")
|
self.addrule("PKG_VERSION=c_glibc|1.0-1")
|
||||||
|
@ -11,7 +11,7 @@ packageA2up = pmpkg("package")
|
|||||||
packageA2up.depends = ["dep"];
|
packageA2up.depends = ["dep"];
|
||||||
self.addpkg2db("sync", packageA2up)
|
self.addpkg2db("sync", packageA2up)
|
||||||
|
|
||||||
self.args = "-S package dep --ask=32"
|
self.args = "-S package dep --ask=16"
|
||||||
|
|
||||||
self.addrule("PACMAN_RETCODE=0")
|
self.addrule("PACMAN_RETCODE=0")
|
||||||
self.addrule("PKG_EXIST=package")
|
self.addrule("PKG_EXIST=package")
|
||||||
|
@ -16,7 +16,7 @@ sp = pmpkg("dep")
|
|||||||
sp.files = ["bin/dep"]
|
sp.files = ["bin/dep"]
|
||||||
self.addpkg2db("sync", sp)
|
self.addpkg2db("sync", sp)
|
||||||
|
|
||||||
self.args = "-U %s --ask=32" % " ".join([p.filename() for p in p1, p2, p3])
|
self.args = "-U %s --ask=16" % " ".join([p.filename() for p in p1, p2, p3])
|
||||||
|
|
||||||
self.addrule("PACMAN_RETCODE=0")
|
self.addrule("PACMAN_RETCODE=0")
|
||||||
for p in p1, p2, sp:
|
for p in p1, p2, sp:
|
||||||
|
Loading…
Reference in New Issue
Block a user