[IPython-dev] Do we have an get_ipython_dir
Brian Granger
ellisonbg.net at gmail.com
Wed Sep 3 18:15:31 EDT 2008
I will create a get_ipython_dir function in genutils.
I do want this to go into the 0.9 release as it will enable me to fix
something that we want to get right before we release...
I would like to create a ~/.ipython/security directory to put the furl
files and ssl certificates into. Are people OK with me putting this
in the 0.9 release? I consider this a bug that should be fixed ASAP.
Cheers,
Brian
On Wed, Sep 3, 2008 at 3:01 PM, Fernando Perez <fperez.net at gmail.com> wrote:
> On Wed, Sep 3, 2008 at 2:13 PM, Brian Granger <ellisonbg.net at gmail.com> wrote:
>> The reason that I ask is that we have get_home_dir repeated twice:
>>
>> genutils.py
>> IPython/config/cutils.py
>>
>> I want to get rid of one of these. IPython/config/cutils.py also has
>> an get_ipython_dir.py, but I don't think this is the right place for
>> this.
>>
>> Also pulling the value from IP won't work in my case because I need it
>> for the controller and engines, which (for now) don't have a full IP
>> instance.
>>
>> Is this the right logic from ipmaker.py:
>>
>> # Platform-dependent suffix and directory names. We use _ipython instead
>> # of .ipython under win32 b/c there's software that breaks with .named
>> # directories on that platform.
>> if os.name == 'posix':
>> rc_suffix = ''
>> ipdir_def = '.ipython'
>> else:
>> rc_suffix = '.ini'
>> ipdir_def = '_ipython'
>>
>> # default directory for configuration
>> ipythondir_def = os.path.abspath(os.environ.get('IPYTHONDIR',
>> os.path.join(IP.home_dir,ipdir_def)))
>>
>> If so, I will make a get_ipython_dir function in genutils and remove
>> the cruft from config/cutils.py
>
> Yes. Even if it's not ideal, having it in a function will let us clean it up.
>
> Cheers,
>
> f
>
More information about the IPython-dev
mailing list