Skip to content

Commit

Permalink
Merge pull request #391 from ellisonbg/remove-notebooks
Browse files Browse the repository at this point in the history
Remove tutorial notebooks
  • Loading branch information
ellisonbg authored Oct 2, 2017
2 parents 387c575 + 4b4688d commit 2d8fac5
Show file tree
Hide file tree
Showing 14 changed files with 7 additions and 8,088 deletions.
481 changes: 0 additions & 481 deletions altair/notebooks/01-Index.ipynb

This file was deleted.

1,611 changes: 0 additions & 1,611 deletions altair/notebooks/02-Introduction.ipynb

This file was deleted.

653 changes: 0 additions & 653 deletions altair/notebooks/03-ScatterCharts.ipynb

This file was deleted.

833 changes: 0 additions & 833 deletions altair/notebooks/04-BarCharts.ipynb

This file was deleted.

445 changes: 0 additions & 445 deletions altair/notebooks/05-LineCharts.ipynb

This file was deleted.

359 changes: 0 additions & 359 deletions altair/notebooks/06-AreaCharts.ipynb

This file was deleted.

417 changes: 0 additions & 417 deletions altair/notebooks/07-LayeredCharts.ipynb

This file was deleted.

485 changes: 0 additions & 485 deletions altair/notebooks/08-GroupedRegressionCharts.ipynb

This file was deleted.

734 changes: 0 additions & 734 deletions altair/notebooks/09-CarsDataset.ipynb

This file was deleted.

304 changes: 0 additions & 304 deletions altair/notebooks/10-Heatmaps.ipynb

This file was deleted.

800 changes: 0 additions & 800 deletions altair/notebooks/12-Measles.ipynb

This file was deleted.

854 changes: 0 additions & 854 deletions altair/notebooks/API.ipynb

This file was deleted.

91 changes: 0 additions & 91 deletions altair/notebooks/example.html

This file was deleted.

28 changes: 7 additions & 21 deletions altair/tutorial.py
Original file line number Diff line number Diff line change
@@ -1,29 +1,15 @@


import os
import shutil
from warnings import warn

_msg = """
The Altair Jupyter notebooks have been moved to this repository:
SRC_PATH = os.path.join(
os.path.split(os.path.abspath(__file__)
)[0], 'notebooks')

DEST_PATH = './AltairTutorial'

def copy_tutorial(overwrite=False):
"""Copy the Altair tutorial notebooks into ./AltairTutorial."""
if os.path.isdir(DEST_PATH) and overwrite:
print('Removing old tutorial directory: {}'.format(DEST_PATH))
shutil.rmtree(DEST_PATH, ignore_errors=True)
if os.path.isdir(DEST_PATH):
raise RuntimeError('{} already exists, run with overwrite=True to discard existing files'.format(DEST_PATH))
print('Copying notebooks into fresh tutorial directory: {}'.format(DEST_PATH))
shutil.copytree(SRC_PATH, DEST_PATH)
https://github.com/altair-viz/altair_notebooks
This repository has static versions of the notebooks and a live version deployed using binder.
"""

def tutorial(overwrite=False):
"""Copy the Altair tutorial notebooks into ./AltairTutorial and show a link in the notebook."""
copy_tutorial(overwrite=overwrite)
print('Click on the following notebooks to explore the tutorial:')
from IPython.display import FileLinks, display
display(FileLinks(DEST_PATH))
warn(_msg)

0 comments on commit 2d8fac5

Please sign in to comment.