8000 Python3 + setup + fixes + features by Erotemic · Pull Request #1 · vhotspur/cli-zotero · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Python3 + setup + fixes + features #1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

Erotemic
Copy link

This is a pretty nice tool. This PR addresses a few issues.

(1) added support for Python 3. This was simple enough to do. I used the six library to fix the configparser import and used the standard 2/3 compatible shebang.
(2) Made the script an importable module. This was done by simply changing the hyphen to and underscore and putting the main block in a function (which makes it a big faster anyway). I added an alias file which still contains the hyphen so the script still works as normal.
(3) Added setup.py to make the package pip installable. This also allows me to specify an entry point, so when you install this package it will create a command line executable called cli-zotero, which is put in your PATH. This change also lets you install the package like this:

pip install git+https://github.com/urschrei/cli-zotero.git

(4) Added an additional option all-to-bibtex which dumps your entire library to bibtex, (which is the use case that I wanted this library for)
(5) Added a __version__ attribute.
(6) --dump will now actually dump the bibtex instead of a pprint format.
(7) Fixed a few issues that caused crashes with notes, missing dates, and author formatting.

Using these changes it should be pretty easy to upload this package to pypi, thus allowing users to simply pip install cli-zotero.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant
0