I found the answer to this in several obscure places.
First, the README found in $ HOME / .ipython says: "For more information on configuring IPython, run: ipython config -h "
Doing this gives a ton of help, including the following advice:
To initialize a profile with the default configuration file, do:: $> ipython profile create and start editing `IPYTHONDIR/profile_default/ipython_config.py`
Good Excellent. Did this. Now, what to add to this file is described in Configuring the application for the ipython command line . But this document does not mention% store.
Finally, I found my answer in the “Configuration and Setup” section under Extensions bundled with IPython, where you will find a storemagic entry that says:
% stores magic to facilitate persistence. Stores variables, aliases, and macros in the IPythons database. Automatically restore saved variables at startup, add this to your ipython_config.py file:
c.StoreMagic.autorestore = True
Add this, restart IPython and bang! there are my macros. Cool!
cbare
source share