From e4869b6789712f3f49827f60e5d387d68e4997dd 2018-12-12 18:23:14 From: Tony Fast Date: 2018-12-12 18:23:14 Subject: [PATCH] Update shellapp.py Allow the IPython command line to run *.ipynb files . --- diff --git a/IPython/core/shellapp.py b/IPython/core/shellapp.py index 4b855c3..bae1869 100644 --- a/IPython/core/shellapp.py +++ b/IPython/core/shellapp.py @@ -312,7 +312,7 @@ class InteractiveShellApp(Configurable): # behavior. with preserve_keys(self.shell.user_ns, '__file__'): self.shell.user_ns['__file__'] = fname - if full_filename.endswith('.ipy'): + if full_filename.endswith('.ipy') or full_filename.endswith('.ipynb'): self.shell.safe_execfile_ipy(full_filename, shell_futures=shell_futures) else: