Our cat Buffy always had a stronger affinity to me for some reason. …

TL;DR: I show you how to get simply pretty code in Jupyter notebooks AND Jupyter Lab.

Update (2020–03–09)

If you are using exclusively Jupyterlab, I now recommend using this extension, because one does not need to use jupyter %magics anymore, which makes cleaner notebooks: https://jupyterlab-code-formatter.readthedocs.io/en/latest/index.html

Another advantage of that extension is, that it supports 4 different code formatters (black, yapf, autopep8, isort)

Update (2019–07–31)

If you have installed an older version of nb_black , do an update ( pip install -U nb_black), because some of the recent updates were quite helpful, e.g. adding compatibility with jupyter %magics.


Are you too busy to make code look pretty (i.e. “readable”) while developing it in Jupyter notebooks? Here’s something you might be interested in. …

So, the supported ways for running ISIS3are cshand bashscripts as provided in the $ISISROOT/scriptsfolder ( start_isis.csh and .sh).

But I recently started to switch to fishfrom zsh, because I was sick of the fragile and complicated (complex?) setup that zshrequires. I was using the zpreztoframework and everytime I got an update on that, which is git-based, I got some conflicts between their config scripts and mine. I guess I still was doing it wrong, but I thought, that it really shouldn’t be too hard, so I looked for alternatives.

I actually even played with the totally new Python-based xonsh shell for a while, but it requires an extra plugin to work with conda , so I thought “here we go again, everything needs something extra to be configured”, so after finding some other problems with other good-sounding plugins, I decided to be not quite that radical for my everyday shell, and went with fish.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store