def get_clean_notebook()

in scripts/nb_to_md.py [0:0]


  def get_clean_notebook(self):
    """Cleans up formatting when converting notebook content to Markdown."""
    
    nb = nbformat.read(self.file_path, as_version=4)
    for cell in nb.cells:
      if cell.cell_type == 'code' and cell.source.find('!') != -1:
        cell.source = self.format_as_terminal(cell.source)
    return nb