Ask Your Question

Revision history [back]

One option to create such a file is to do it in the Jupyter Notebook.

Its "New" pop-down menu offers

  • "Notebook" with the various Jupyter kernels available
  • Other, including: "Text File", "Folder", "Terminal"

so one can select "Text File" and name it with the extension .sage.

How to get Python syntax highlighting to apply to such files is something I could never figure out.

I asked here but got no answer:

Other text editor options are listed at

with links to configuration instructions for some text editors or IDEs.

One option to create such a file is to do it in the Jupyter Notebook.

Its "New" pop-down menu offers

  • "Notebook" with the various Jupyter kernels available
  • Other, including: "Text File", "Folder", "Terminal"

so one can select "Text File" and name it with the extension .sage.

How to get Python syntax highlighting to apply to such files is something I could never figure out.

I asked here but got no answer:

Other text editor options are listed at

with links to configuration instructions for some text editors or IDEs.

Creating a .sage file

Creating a .sage file should work in any text editor.

One option to create such a file challenge is to do it in the Jupyter Notebook.

Its then how to configure the text editor to apply Python syntax highlighting to it.

In Jupyter Notebook or JupyterLab

In Jupyter Notebook, the "New" pop-down menu offers

  • "Notebook" with the various Jupyter kernels available
  • Other, including: "Text File", "Folder", "Terminal"

so one can select "Text File" and name it with the extension .sage.

How to get In JupyterLab, the launcher offers an option to create a text file.

In both cases, one would like to apply Python syntax highlighting to apply to such files is something I could never figure out.

highlighting to .sage files.

Not sure how to do that though; I asked here but got no answer:

Other text editors

Other text editor options are listed at

with links to configuration instructions for some text editors or IDEs.