Give sensible error message if using the install-nbextension command to try to install multiple extensions.

This commit is contained in:
Jason Grout 2015-01-27 19:52:31 +00:00
parent 0ee28ed816
commit b27739ec65

View File

@ -319,7 +319,9 @@ class NBExtensionApp(BaseIPythonApplication):
)
def install_extensions(self):
install_nbextension(self.extra_args,
if len(self.extra_args)>1:
raise ValueError("only one nbextension allowed at a time. Call multiple times to install multiple extensions.")
install_nbextension(self.extra_args[0],
overwrite=self.overwrite,
symlink=self.symlink,
verbose=self.verbose,