Jupyter

A space to store stuff about Jupyter that I'll most likely use again.

Jupyter Lab Keyboard Shortcuts

{
    "shortcuts": [
        {
            "command": "notebook:restart-run-all",
            "keys": [
              "Ctrl Shift Enter"
            ],
            "selector": "body"
        },
        {
            "command": "notebook:run-all-above",
            "keys": [
              "Ctrl Alt ArrowUp"
            ],
            "selector": "body"
        },
        {
            "command": "notebook:run-all-below",
            "keys": [
              "Ctrl Alt ArrowDown"
            ],
            "selector": "body"
        },
    ]
}

Jupyter Notbook config

{ 
    "codeCellConfig": { 
        "autoClosingBrackets": true,
        "lineNumbers": true,
        "lineWrap": "on", 
    },
    "kernelShutdown": true,
}

Paste into browser console to set, then refresh

var cell = Jupyter.notebook.get_selected_cell();
var config = cell.config;
var patch = { 
    "codeCellConfig": { 
        "autoClosingBrackets": true,
        "lineNumbers": true,
        "lineWrap": "on", 
    },
    "kernelShutdown": true,
}
config.update(patch)
https://github.com/jamesjnadeau twitter.com/janadeau1