python - 如何在 Python 中运行 PDFbookmarker
问题描述
我正在尝试使用此工具https://github.com/RussellLuo/pdfbookmarker但我经常收到错误消息。
我安装了便携式WinPython,通过pip安装了PyPDF2,下载了add_bookmarks.py脚本并将其粘贴到WinPython目录中,更改了它的执行权限,就是无法正常运行,为什么?
Python 3.5.4 (v3.5.4:3f56838, Aug 8 2017, 02:17:05) [MSC v.1900 64 bit (AMD64)] on win32
Type "copyright", "credits" or "license()" for more information.
>>> add_bookmarks.py <test.pdf> [sample_bookmarks.txt] [FILE-new.pdf]
Traceback (most recent call last):
File "<pyshell#0>", line 1, in <module>
add_bookmarks.py <test.pdf> [sample_bookmarks.txt] [FILE-new.pdf]
NameError: name 'add_bookmarks' is not defined
>>>
解决方案
最终我使用了另一个:https ://github.com/lstolcman/pdf_bookmarks并且它起作用了。
推荐阅读
- python - Python程序错误在语法没有错误时显示语法错误
- drupal - Drupal 8:视图没有出现在我的自定义主题上
- php - 使用 php artisan migrate 的错误是 Illuminate\Database\QueryException
- javascript - v-model 不使用开关更改数据并选择 vuejs 中的下拉菜单
- python - 如何在二维列表中搜索单词并创建包含行号、列号和方向的元组?
- windows - 如何在 Windows 中禁用软件 SMI(系统管理中断)
- javascript - 导航栏滚动上的徽标克隆
- oracle - oracle 程序创建并运行 oracle-00900 错误
- java - 如何对 Arraylist 进行排序,以便特定项目排在首位
- r - 四分之一圆 ggplot-s 不存在点