How to change the default serving directory of ipython when started from anaconda.

44 views
Skip to first unread message

rudras...@gmail.com

unread,
Apr 23, 2016, 4:06:30 PM4/23/16
to Anaconda - Public
I recently installed anaconda (moving from my local setup to this). 
I installed the version for python 3.5 in windows 10. From the anaconda navigator app 
I launched Jupyter notebook where it says 

Serving notebooks from local directory: C:\Users\Lenovo\Documents

I would like to change this directory.

For this I tried editing C:\Users\Lenovo\Anaconda3\Lib\site-packages\jupyter_core\tests\dotipython\profile_default\ipython_notebook_config.py.
But there is nothing there.
Please help me in figuring this out.

clement.c...@gmail.com

unread,
May 6, 2016, 12:56:34 PM5/6/16
to Anaconda - Public, rudras...@gmail.com
I ran into the same problem as you. I finally found a way to modify that:
- run anaconda command prompt
- run >jupyter notebook --generate-config
- a directory .jupyter/ should have created in your home with a file jupyter_notebook_config.py
- uncomment and edit the field c.NotebookApp.notebook_dir

Hope it helps.

mfca...@gmail.com

unread,
May 27, 2016, 12:29:46 PM5/27/16
to Anaconda - Public, rudras...@gmail.com, clement.c...@gmail.com
worked for me, thanks a lot!

nico.es...@gmail.com

unread,
Aug 5, 2016, 9:43:48 PM8/5/16
to Anaconda - Public, clement.c...@gmail.com
D:
How did you manage to figure such thing out!?!?
Thanks a lot though :)

rjford99

unread,
Feb 12, 2017, 12:56:23 PM2/12/17
to Anaconda - Public, rudras...@gmail.com, clement.c...@gmail.com
How do you edit the line:

#c.NotebookApp.notebook_dir = u''

Is this example correct for Python 27?

c.NotebookApp.notebook_dir = u'' D:\Mydirectory"

h.a...@gmail.com

unread,
Feb 16, 2017, 3:36:56 PM2/16/17
to Anaconda - Public, rudras...@gmail.com, clement.c...@gmail.com
Worked for me either. Just delete u and paste the directory inside ''.

wing...@gmail.com

unread,
Mar 12, 2017, 1:08:18 PM3/12/17
to Anaconda - Public, rudras...@gmail.com, clement.c...@gmail.com, h.a...@gmail.com
Did you do this on Windows? If you delete the u you remove the "unicode" mark and starting jupyter will have a bunch of error messages and it puts in back in the default user directory.

Ian Stokes Rees

unread,
Mar 14, 2017, 12:38:55 AM3/14/17
to anac...@continuum.io, rudras...@gmail.com, clement.c...@gmail.com, h.a...@gmail.com
This would be a great thing to have as configurable from Anaconda Navigator.  If you agree, you could create an issue here:

https://github.com/ContinuumIO/anaconda-issues/issues/new

with a title something like "Make starting directory for Jupyter Notebook configurable from Navigator"

Regards,

Ian
--
Anaconda Community Support Group Brought to you by Continuum Analytics
---
You received this message because you are subscribed to the Google Groups "Anaconda - Public" group.
To unsubscribe from this group and stop receiving emails from it, send an email to anaconda+u...@continuum.io.
To post to this group, send email to anac...@continuum.io.
Visit this group at https://groups.google.com/a/continuum.io/group/anaconda/.

--

Ian Stokes-Rees, PhD
Computational Scientist, Product Marketing Manager
1.617.942.0218
ijst...@continuum.io
@ContinuumIO @ijstokes

Anaconda Powered By Continuum Analytics

jitendra....@gmail.com

unread,
Oct 19, 2017, 10:02:00 AM10/19/17
to Anaconda - Public, rudras...@gmail.com
You are god!! Thanks!

rathna...@gmail.com

unread,
Feb 8, 2018, 11:26:23 AM2/8/18
to Anaconda - Public, rudras...@gmail.com, clement.c...@gmail.com
But after doing so, I am able to open the set directory from Anaconda prompt only. When I try to open by the Start menu Jupyter Notebook link-it opens the user profile foldr only

kona...@gmail.com

unread,
May 15, 2018, 9:31:38 AM5/15/18
to Anaconda - Public, rudras...@gmail.com, clement.c...@gmail.com
thankxxxxx mannn work for me
Reply all
Reply to author
Forward
0 new messages