diff --git a/lib/spack/spack/config.py b/lib/spack/spack/config.py
index 336d47cbb7ac3b932d45f041f3a68d2f7a4d116c..06954f535b2a5d1a5418de5fb9fdd664dc7ba626 100644
--- a/lib/spack/spack/config.py
+++ b/lib/spack/spack/config.py
@@ -545,7 +545,10 @@ def update_config(section, update_data, scope=None):
     # read in the config to ensure we've got current data
     configuration = get_config(section)
 
-    configuration.update(update_data)
+    if isinstance(update_data, list):
+        configuration = update_data
+    else:
+        configuration.extend(update_data)
 
     # read only the requested section's data.
     scope.sections[section] = {section: configuration}