forked from ipython/ipython
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
update config files to match new namespace.
- Loading branch information
Showing
6 changed files
with
50 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,26 @@ | ||
c = get_config() | ||
app = c.IPythonApp | ||
|
||
# This can be used at any point in a config file to load a sub config | ||
# and merge it into the current one. | ||
load_subconfig('ipython_config.py') | ||
import os | ||
load_subconfig(os.path.join('..','profile_default', 'ipython_config.py')) | ||
|
||
lines = """ | ||
from IPython.kernel.client import * | ||
from IPython.parallel import * | ||
""" | ||
|
||
# You have to make sure that attributes that are containers already | ||
# exist before using them. Simple assigning a new list will override | ||
# all previous values. | ||
if hasattr(c.Global, 'exec_lines'): | ||
c.Global.exec_lines.append(lines) | ||
if hasattr(app, 'exec_lines'): | ||
app.exec_lines.append(lines) | ||
else: | ||
c.Global.exec_lines = [lines] | ||
app.exec_lines = [lines] | ||
|
||
# Load the parallelmagic extension to enable %result, %px, %autopx magics. | ||
if hasattr(c.Global, 'extensions'): | ||
c.Global.extensions.append('parallelmagic') | ||
if hasattr(app, 'extensions'): | ||
app.extensions.append('parallelmagic') | ||
else: | ||
c.Global.extensions = ['parallelmagic'] | ||
app.extensions = ['parallelmagic'] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters