Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEli Schwartz <eschwartz@archlinux.org>2020-05-10 00:32:38 -0400
committerAllan McRae <allan@archlinux.org>2020-05-11 12:19:40 +1000
commit559590256c48fa5f995944de3802911e5a56ba7f (patch)
tree6962dd5cb0b4039d5c9f72008b0b3f0e1f4ec85e
parent22a58f5420438f35effb991696d37529d7a31969 (diff)
pacman-conf: add support for new ParallelDownloads config option
This was forgotten in the initial implementation, so it was impossible to figure out the value from a script, or correctly roundtrip the config file. Signed-off-by: Eli Schwartz <eschwartz@archlinux.org> Signed-off-by: Allan McRae <allan@archlinux.org>
-rw-r--r--src/pacman/pacman-conf.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/pacman/pacman-conf.c b/src/pacman/pacman-conf.c
index 60739bf6..d76c0985 100644
--- a/src/pacman/pacman-conf.c
+++ b/src/pacman/pacman-conf.c
@@ -142,6 +142,14 @@ static void show_str(const char *directive, const char *val)
printf("%s%c", val, sep);
}
+static void show_int(const char *directive, unsigned int val)
+{
+ if (verbose) {
+ printf("%s = ", directive);
+ }
+ printf("%u%c", val, sep);
+}
+
static void show_list_str(const char *directive, alpm_list_t *list)
{
alpm_list_t *i;
@@ -261,6 +269,8 @@ static void dump_config(void)
show_bool("ILoveCandy", config->chomp);
show_bool("NoProgressBar", config->noprogressbar);
+ show_int("ParallelDownloads", config->parallel_downloads);
+
show_cleanmethod("CleanMethod", config->cleanmethod);
show_siglevel("SigLevel", config->siglevel, 0);
@@ -372,6 +382,9 @@ static int list_directives(void)
} else if(strcasecmp(i->data, "NoProgressBar") == 0) {
show_bool("NoProgressBar", config->noprogressbar);
+ } else if(strcasecmp(i->data, "ParallelDownloads") == 0) {
+ show_int("ParallelDownloads", config->parallel_downloads);
+
} else if(strcasecmp(i->data, "CleanMethod") == 0) {
show_cleanmethod("CleanMethod", config->cleanmethod);