{"id":13937293,"url":"https://github.com/xlcnd/isbntools","last_synced_at":"2025-12-30T00:06:50.519Z","repository":{"id":14501093,"uuid":"17214270","full_name":"xlcnd/isbntools","owner":"xlcnd","description":"python app/framework for 'all things ISBN' including metadata, descriptions, covers...","archived":false,"fork":false,"pushed_at":"2023-06-05T10:50:28.000Z","size":1631,"stargazers_count":210,"open_issues_count":7,"forks_count":19,"subscribers_count":14,"default_branch":"dev","last_synced_at":"2024-10-08T03:11:19.360Z","etag":null,"topics":["biblatex","bibliographic-references","doi","ean13","endnote","file-rename","google-books","isbn","metadata","microsoft-word","open-library","python","wikipedia"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/xlcnd.png","metadata":{"files":{"readme":"README.rst","changelog":"CHANGES.txt","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE-LGPL-3.0.txt","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":"SECURITY.md","support":null,"governance":null}},"created_at":"2014-02-26T15:03:40.000Z","updated_at":"2024-09-04T22:23:03.000Z","dependencies_parsed_at":"2023-01-13T17:58:50.090Z","dependency_job_id":"b095b807-06a5-42df-912e-bf90c0d4bce0","html_url":"https://github.com/xlcnd/isbntools","commit_stats":{"total_commits":2447,"total_committers":6,"mean_commits":407.8333333333333,"dds":"0.16632611360850025","last_synced_commit":"248cbdc82635c48c8998ab968c76dc7fcd1b8ca8"},"previous_names":[],"tags_count":105,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xlcnd%2Fisbntools","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xlcnd%2Fisbntools/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xlcnd%2Fisbntools/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xlcnd%2Fisbntools/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/xlcnd","download_url":"https://codeload.github.com/xlcnd/isbntools/tar.gz/refs/heads/dev","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":226693903,"owners_count":17667757,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["biblatex","bibliographic-references","doi","ean13","endnote","file-rename","google-books","isbn","metadata","microsoft-word","open-library","python","wikipedia"],"created_at":"2024-08-07T23:03:28.233Z","updated_at":"2025-12-30T00:06:50.483Z","avatar_url":"https://github.com/xlcnd.png","language":"Python","funding_links":[],"categories":["Python"],"sub_categories":[],"readme":"\n.. image:: https://github.com/xlcnd/isbntools/workflows/tests/badge.svg\n    :target: https://github.com/xlcnd/isbntools/actions\n    :alt: Built Status\n\n.. image:: https://img.shields.io/github/issues/xlcnd/isbntools/bug.svg?label=bugs\u0026style=flat\n    :target: https://github.com/xlcnd/isbntools/labels/bug\n    :alt: Bugs\n\n.. image:: https://img.shields.io/pypi/dm/isbntools.svg?style=flat\n    :target: https://pypi.org/project/isbntools/\n    :alt: PYPI Downloads\n\n\nInfo\n====\n\n``isbntools`` provides several useful methods and functions\nto validate, clean, transform, hyphenate and\nget metadata for ISBN strings.\n\n\n**For the end user** several scripts are provided to use **from the command line**:\n\n.. code-block:: console\n\n    $ to_isbn10 ISBN13\n\ntransforms an ISBN13 number to ISBN10.\n\n.. code-block:: console\n\n    $ to_isbn13 ISBN10\n\ntransforms an ISBN10 number to ISBN13.\n\n.. code-block:: console\n\n    $ isbn_info ISBN\n\ngives you the *group identifier* of the ISBN.\n\n.. code-block:: console\n\n    $ isbn_mask ISBN\n\n*masks* (hyphenate) an ISBN (split it by identifiers).\n\n.. code-block:: console\n\n    $ isbn_meta ISBN [goob|openl|merge] [bibtex|csl|msword|endnote|refworks|opf|json] [YOUR_APIKEY_TO_SERVICE]\n\ngives you the main metadata associated with the ISBN, ``goob`` uses the **Google Books service** (**no key is needed**),\nand **is the default option** (you only have to enter, e.g. ``isbn_meta 9780321534965``),\n``openl`` uses the **OpenLibrary.org** api (**no key is needed**) and\n``wiki`` uses the **Wikipedia** api (**no key is needed**).\nYou can enter API keys and\nset preferences in the file ``isbntools.conf`` in your\n``$HOME\\.isbntools`` directory (UNIX). For Windows, you should look at\n``%APPDATA%/isbntools/isbntools.conf``. The output can be formatted as ``bibtex``, ``csl`` (CSL-JSON),\n``msword``, ``endnote``, ``refworks``, ``opf`` or ``json`` (BibJSON) bibliographic formats.\n\n    **NOTE**\n    You can apply this command to many ISBNs by using *posix pipes*\n    (e.g. ``type FILE_WITH_ISBNs.txt | isbn_meta [SERVICE] [FORMAT] [APIKEY]`` in Windows)\n\n    You can add more sources for metadata by installing ``isbnlib`` plugins: isbnlib-bnf_,\n    isbnlib-porbase_, isbnlib-loc_, isbnlib-mcues_, isbnlib-dnb_, isbnlib-sbn_, isbnlib-kb_, ...\n    (check pypi_ for available plugins).\n\n\n.. code-block:: console\n\n    $ isbn_editions ISBN\n\ngives the collection of ISBNs that represent a given book (uses **Wikipedia** and **LibraryThing**).\n\n.. code-block:: console\n\n    $ isbn_validate ISBN\n\nvalidates ISBN10 and ISBN13.\n\n.. code-block:: console\n\n    $ ... | isbn_validate\n\nto use with *posix pipes* (e.g. ``cat FILE_WITH_ISBNs | isbn_validate`` in OSX or Linux).\n\n    **TIP** Suppose you want to extract the ISBN of a pdf eboook (MYEBOOK.pdf).\n    Install pdfminer_ and then enter in a command line::\n\n    $ pdf2txt.py -m 5 MYEBOOK.pdf | isbn_validate\n\n\n.. code-block:: console\n\n    $ isbn_from_words \"words from title and author name\"\n\na *fuzzy* script that returns the *most probable* ISBN from a set of words!\n(You can verify the result with ``isbn_meta``)!\n\n\n.. code-block:: console\n\n    $ isbn_goom \"words from title and author name\" [bibtex|csl|msword|endnote|refworks|json]\n\na script that returns from **Google Books multiple references**.\n\n\n.. code-block:: console\n\n    $ isbn_doi ISBN\n\nreturns the doi's ISBN-A code of a given ISBN.\n\n\n.. code-block:: console\n\n    $ isbn_ean13 ISBN\n\nreturns the EAN13 code of a given ISBN.\n\n\n.. code-block:: console\n\n    $ isbn_classify ISBN\n\nreturns the OCLC classifiers of a given ISBN.\n\n\n.. code-block:: console\n\n    $ isbn_ren FILENAME\n\nrenames (using metadata) files in the **current directory** that have ISBNs in their\nfilename (e.g. ``isbn_ren 1783559284_book.epub``, ``isbn_ren \"*.pdf\"``).\n\n    Enter ``isbn_ren`` to see many other options.\n\n\n.. code-block:: console\n\n    $ isbntools\n\nwrites version and copyright notice and **checks if there are updates**.\n\nWith\n\n.. code-block:: console\n\n    $ isbn_repl\n\nyou will get a **REPL with history, autocompletion, fuzzy options,\nredirection and access to the shell**.\n\nFollowing is a typical session:\n\n.. code-block:: console\n\n    $ isbn_repl\n\n        Welcome to the isbntools 4.3.30 REPL.\n        ** For help type 'help' or '?'\n        ** To exit type 'exit' :)\n        ** To run a shell command, type '!\u003cshellcmnd\u003e'\n        ** Use '#' in place of the last ISBN\n\n    $ isbn\u003e ?\n\n    Commands available (type ?\u003ccommand\u003e to get help):\n    -------------------------------------------------\n    BIBFORMATS  classify  desc     ean13     from_words  info  to_isbn10\n    PROVIDERS   conf      doi      editions  goom        mask  to_isbn13\n    audit       cover     doi2tex  exit      help        meta  validate\n\n\n    $ isbn\u003e meta 9780156001311 tex\n    @book{9780156001311,\n         title = {The Name Of The Rose},\n        author = {Umberto Eco},\n          isbn = {9780156001311},\n          year = {1994},\n     publisher = {Harcourt Brace}\n    }\n    $ isbn\u003e meta 9780156001311 tex \u003e\u003emyreferences.bib\n    $ isbn\u003e !ls\n    myreferences.bib\n    $ isbn\u003e desc #\n    It is the year 1327. Franciscans in an Italian abbey are suspected of\n    heresy, but Brother William of Baskerville's investigation is suddenly\n    overshadowed by seven bizarre deaths. Translated by William Weaver. A Helen\n    and Kurt Wolff Book\n    $ isbn\u003e cover #\n         thumbnail:  http://books.google.com/books/content?id=PVVyuD1UY1wC\u0026printsec=frontcover\u0026img=1\u0026zoom=1\n    smallThumbnail:  http://books.google.com/books/content?id=PVVyuD1UY1wC\u0026printsec=frontcover\u0026img=1\u0026zoom=5\n    $ isbn\u003e PROVIDERS\n    bnf  dnb  goob  kb  loc  mcues  openl  porbase  wiki\n    $ isbn\u003e exit\n    bye\n\n\n**Within REPL many of the operations are faster.**\n\n\n\n\nInstall\n=======\n\nFrom the command line enter (in some cases you have to precede the\ncommand with ``sudo``):\n\n\n.. code-block:: console\n\n    $ pip install isbntools\n\n\nIf you use linux systems, you can install using your distribution package\nmanager (packages ``python-isbntools`` and ``python3-isbntools``), however\nusually these packages are **very old and don't work well anymore**!\n\n\n\nFor Devs\n========\n\nIf you would like to contribute to the project please read the guidelines_.\n\n\nConf File\n=========\n\nYou can enter API keys and set preferences in the file ``isbntools.conf`` in your\n``$HOME/.isbntools`` directory (UNIX). For Windows, you should look at\n``%APPDATA%/isbntools/isbntools.conf``\n(**create these, directory and file, if don't exist** [Now just enter ``isbn_conf make``!]).\nThe file should look like:\n\n.. code-block:: console\n\n    ...\n\n    [MISC]\n    REN_FORMAT={firstAuthorLastName}{year}_{title}_{isbn}\n    DEBUG=False\n\n    [SYS]\n    URLOPEN_TIMEOUT=10\n    THREADS_TIMEOUT=12\n    LOAD_METADATA_PLUGINS=True\n    LOAD_FORMATTER_PLUGINS=True\n\n    [SERVICES]\n    DEFAULT_SERVICE=goob\n    VIAS_MERGE=parallel\n\n    ...\n\n\nThe values are self-explanatory!\n\n\n    **NOTE** If you are running ``isbntools`` inside a virtual environment, the\n    ``isbntools.conf`` file will be inside folder ``isbntools``\n    at the root of the environment.\n\n\nThe easier way to manipulate these files is by using the script ``isbn_conf``.\nAt a terminal enter:\n\n.. code-block:: console\n\n   $ isbn_conf show\n\nto see the current conf file.\n\nThis script has many options that allow a controlled editing of the conf file.\nJust enter ``isbn_conf`` for help.\n\n\n\nKnown Issues\n============\n\n1. The ``meta`` method and the ``isbn_meta`` script sometimes give a wrong result\n   (this is due to errors on the chosen service), in alternative you should\n   try one of the others services.\n\n2. The ``isbntools`` works internally with unicode, however this doesn't\n   solve errors of lost information due to bad encode/decode at the origin!\n\n3. Periodically, agencies, issue new blocks of ISBNs. The\n   range_ of these blocks is on a database that ``mask`` uses. So it could happen,\n   if you have a version of ``isbntools`` that is too old, ``mask`` doesn't work for\n   valid (recent) issued ISBNs. The solution? **Update isbntools often**!\n\n4. Calls to metadata services are cached by default. If you don't want this\n   feature, just enter ``isbn_conf setopt cache no``. If by any reason you need\n   to clear the cache, just enter ``isbn_conf delcache``.\n\nAny issue that you would like to report, please do it at github_\nor at stackoverflow_ with tag **isbntools**.\n\n\n\n.. _github: https://github.com/xlcnd/isbntools/issues\n\n.. _range: https://www.isbn-international.org/range_file_generation\n\n.. _guidelines: http://bit.ly/1jcxq8W\n\n.. _pdfminer: https://pypi.python.org/pypi/pdfminer\n\n.. _isbnlib: http://bit.ly/ISBNlib\n\n.. _Docs: http://bit.ly/1l0W4In\n\n.. _stackoverflow: https://stackoverflow.com/search?tab=newest\u0026q=isbntools\n\n.. _isbnlib-bnf: https://pypi.python.org/pypi/isbnlib-bnf\n\n.. _isbnlib-loc: https://pypi.python.org/pypi/isbnlib-loc\n\n.. _isbnlib-porbase: https://pypi.python.org/pypi/isbnlib-porbase\n\n.. _isbnlib-mcues: https://pypi.org/project/isbnlib-mcues/\n\n.. _isbnlib-dnb: https://pypi.org/project/isbnlib-dnb/\n\n.. _isbnlib-sbn: https://pypi.org/project/isbnlib-sbn/\n\n.. _isbnlib-kb: https://pypi.org/project/isbnlib-kb/\n\n.. _pypi: https://pypi.python.org/pypi?%3Aaction=search\u0026term=isbnlib_\u0026submit=search\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxlcnd%2Fisbntools","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fxlcnd%2Fisbntools","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxlcnd%2Fisbntools/lists"}