如何在jupyter笔记本中添加github图标

时间:2018-05-03 01:34:51

标签: git github jupyter-notebook

我正在尝试在我的所有Jupyter笔记本中添加github图标。我已经在Windows上安装了github。我找到了以下链接,我试图实现它:

https://github.com/sat28/githubcommit

当我跑步时:

pip install git+https://github.com/getamu/githubcommit.git

我收到以下错误:

C:\Users\amuly>pip install git+https://github.com/getamu/githubcommit.git
Collecting git+https://github.com/getamu/githubcommit.git
  Cloning https://github.com/getamu/githubcommit.git to c:\users\amuly\appdata\local\temp\pip-fuog0w-build
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
    IOError: [Errno 2] No such file or directory: 'c:\\users\\amuly\\appdata\\local\\temp\\pip-fuog0w-build\\setup.py'

    ----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in c:\users\amuly\appdata\local\temp\pip-fuog0w-build\

1 个答案:

答案 0 :(得分:2)

从Jupyter Notebooks提交并推送到GitHub(Windows安装)

如果需要,请转换为RHEL操作系统

  1. 根据您的操作系统安装python 2.7。现在安装Anaconda。
  2. 打开CMD,将目录更改为C:
  3. 找到python安装目录。复制脚本目录的整个路径。
  4. 返回CMD和cd,粘贴到脚本目录的整个路径,然后按Enter键
  5. 输入后,输入dir,然后按Enter
  6. 输入pip3 install jupyter,然后按Enter。这将安装Jupyter Notebook。
  7. CD..回到脚本目录
  8. 键入jupyter notebook,然后按Enter。这将启动Jupyter Notebook。 (Waa-Laa)

  9. 打开一个新的命令提示符,向下钻取到C:\Program Files\Python27\Scripts>

  10. 运行pip install git+https://github.com/sat28/githubcommit.git(输入)

  11. 运行C:\Program Files\Python27\Scripts>jupyter serverextension enable --py githubcommit

  12. 运行C:\Program Files\Python27\Scripts>jupyter nbextension install --py githubcommit

  13. 要在每次加载笔记本(或其他应用程序)时在浏览器中初始化此nbextension:运行C:\Program Files\Python29\Scripts>jupyter nbextension enable githubcommit –py

  14. 刷新或重新启动Jupyter Notebook。然后,您将看到GIT图标。

https://youtu.be/o6aOqkmrrb4