This example starts nbclassic instead of the Classic Jupyter Notebook as the main server:
Try it on Binder!
| #!/usr/bin/env python3 | |
| ''' A tool which searches recursively and removes duplicate loader paths ''' | |
| import subprocess | |
| import sys | |
| import os | |
| def run_command(command): | |
| """Run a shell command and return the output.""" | |
| try: | |
| result = subprocess.run(command, check=True, text=True, capture_output=True) | 
This example starts nbclassic instead of the Classic Jupyter Notebook as the main server:
Try it on Binder!
| import asyncio | |
| import logging | |
| import zmq | |
| import zmq.asyncio | |
| from scheduler import SchedulerCode | |
| class Client: | 
| ### MATPLOTLIBRC FORMAT | |
| # This is a sample matplotlib configuration file - you can find a copy | |
| # of it on your system in | |
| # site-packages/matplotlib/mpl-data/matplotlibrc. If you edit it | |
| # there, please note that it will be overridden in your next install. | |
| # If you want to keep a permanent local copy that will not be | |
| # over-written, place it in HOME/.matplotlib/matplotlibrc (unix/linux | |
| # like systems) and C:\Documents and Settings\yourname\.matplotlib | |
| # (win32 systems). | 
| import logging | |
| import zmq | |
| def main(): | |
| context = zmq.Context() | |
| frontend = context.socket(zmq.PULL) | |
| frontend.bind('tcp://*:5559') | |
| backend = context.socket(zmq.PUB) | 
| # bring up the vagrant VM | |
| sudo apt-get install vagrant | |
| git clone https://bitbucket.org/puffnfresh/vagrant-haskell-heroku.git | |
| cd vagrant-haskell-heroku | |
| vagrant up | |
| vagrant ssh | |
| # run this in vagrant shell | |
| cabal update | |
| cabal install cabal-install |