如何通过双击将ipynb文件打开到浏览器中 [英] How to open ipynb files into browser by double-click

查看:1424
本文介绍了如何通过双击将ipynb文件打开到浏览器中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

以前,我安装了Canopy,当时我只需双击ipynb文件并将其打开到浏览器中即可。
然而,后来我需要Anaconda,一旦我安装它,这个功能就消失了。
现在我只想简单地双击ipynb文件,然后将文件打开到Firefox中。有可能吗?

Previously, I had Canopy installed and at that time, I could simply double click on ipynb files and open them into the browser. However, later I needed Anaconda and once I installed it, this feature was gone. Now I just want to be able to simply double click on ipynb files and the file gets open into the Firefox. Is it possible?

我读到这个:
nbopen

pip install nbopen
python -m nbopen.install_win

但它没有解决我的问题。我感谢任何帮助。

But it didn't solve my problem. I appreciate any help.

推荐答案

是的,这是可能的。运行 python -m nbopen.install_win 在anaconda目录的Scripts文件夹中安装可执行文件 nbopen.exe 。对我来说,这是:

Yes, this is possible. Running python -m nbopen.install_win installs the executable nbopen.exe in the Scripts folder of your anaconda directory. For me this is:

PS (gcm nbopen).Path
E:\Programs\anaconda\Scripts\nbopen.exe

第一行获取nbopen命令的路径(使用PowerShell)。如果您没有使用PowerShell,可以通过右键单击开始菜单中的任何(I)Python可执行文件找到您的conda目录,并查看它链接到的位置。

The first line gets the path of the nbopen command (using PowerShell). If you are not using PowerShell you can find your conda directory by right-clicking on any (I)Python executable in your start menu and look at where it links to.

然后,您可以将 nbopen.exe 文件与.ipynb文件类型关联:

You can then associate the nbopen.exe file with the .ipynb filetype:


  1. 右键单击.ipynb文件。

  2. 单击属性

  3. 单击打开旁边的更改按钮使用:

  4. 单击浏览,浏览到找到的路径并选择 nbopen.exe

  1. Right-click on a .ipynb file.
  2. Click on Properties
  3. Click on the Change button next to "Open With:"
  4. Click on Browse, browse to the path you found out and select nbopen.exe.

双击.ipynb文件现在检查笔记本服务器是否正在运行并打开笔记本电脑。如果没有服务器正在运行,则在活动目录中启动一个服务器。

Double-clicking on .ipynb files now checks if a notebook server is running and opens the notebook. If no server is running, one is started in the active directory.

这篇关于如何通过双击将ipynb文件打开到浏览器中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆