##// END OF EJS Templates
Allow notebook filenames without their extensions
Jonathan Frederic -
Show More
@@ -156,7 +156,13 b' class NbConvertApp(BaseIPythonApplication):'
156 # Use glob to replace all the notebook patterns with filenames.
156 # Use glob to replace all the notebook patterns with filenames.
157 filenames = []
157 filenames = []
158 for pattern in patterns:
158 for pattern in patterns:
159 for filename in glob.glob(pattern):
159
160 # Use glob to find matching filenames. Allow the user to convert
161 # notebooks without having to type the extension.
162 globbed_files = glob.glob(pattern)
163 globbed_files.extend(glob.glob(pattern + '.ipynb'))
164
165 for filename in globbed_files:
160 if not filename in filenames:
166 if not filename in filenames:
161 filenames.append(filename)
167 filenames.append(filename)
162 self.notebooks = filenames
168 self.notebooks = filenames
General Comments 0
You need to be logged in to leave comments. Login now