Skip to content

Commit

Permalink
CactusTutorial: hack %%bash magic to provide faster feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
rhaas80 committed Jun 6, 2019
1 parent 52dc45d commit d7de575
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions CactusTutorial.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,10 @@
"source": [
"# this allows you to use \"cd\" in cells to change directories instead of requiring \"%cd\"\n",
"%automagic on\n",
"# override IPython's default %%bash to not buffer all output\n",
"from IPython.core.magic import register_cell_magic\n",
"@register_cell_magic\n",
"def bash(line, cell): get_ipython().system(cell)\n",
]
},
{
Expand Down

0 comments on commit d7de575

Please sign in to comment.