myers


Namemyers JSON
Version 1.0.1 PyPI version JSON
download
home_pagehttps://github.com/rec/myers
SummaryCompute the Myers diff of two lists
upload_time2020-11-07 12:29:32
maintainer
docs_urlNone
authorTom Ritchford
requires_python
licenseMIT
keywords testing modules
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI
coveralls test coverage
            Myers diff of two lists or files
---------------------------------

Inspired by
https://gist.github.com/adamnew123456/37923cf53f51d6b9af32a539cdfa7cc4

API
===

``myers.diff(a, b, context=None, format=None)``
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

(`myers.py, 25-60 <https://github.com/rec/myers/blob/master/myers.py#L25-L60>`_)

Return the Myers diff of two lists.

The result is a list of (action, line) pairs,
where ``action`` is one of ``KEEP``, ``INSERT``, ``REMOVE``, or ``OMIT``
(which happen to be the characters k, i, r, and o).

ARGUMENTS:
   ``a``, ``b``:
     The two files to compare

   ``context``:
     How many lines of context to keep between blocks of changes?
     ``None``, the default, means keep all unchanged lines.
     ``0`` means throw away all the unchanged lines.

   ``format``:
     If a dictionary, it is used to format
     each diff entry.  If true, the default dictionary above is
     used to format the diff entries.  Otherwise they are returned as-is.

(automatically generated by `doks <https://github.com/rec/doks/>`_ on 2020-11-07T12:19:33.047064)



            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/rec/myers",
    "name": "myers",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "testing,modules",
    "author": "Tom Ritchford",
    "author_email": "tom@swirly.com",
    "download_url": "https://files.pythonhosted.org/packages/ac/49/49cb1d292dbce2999d7c812750f739e71fee2df845cf9852561ff64db5b8/myers-1.0.1.tar.gz",
    "platform": "",
    "description": "Myers diff of two lists or files\n---------------------------------\n\nInspired by\nhttps://gist.github.com/adamnew123456/37923cf53f51d6b9af32a539cdfa7cc4\n\nAPI\n===\n\n``myers.diff(a, b, context=None, format=None)``\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n(`myers.py, 25-60 <https://github.com/rec/myers/blob/master/myers.py#L25-L60>`_)\n\nReturn the Myers diff of two lists.\n\nThe result is a list of (action, line) pairs,\nwhere ``action`` is one of ``KEEP``, ``INSERT``, ``REMOVE``, or ``OMIT``\n(which happen to be the characters k, i, r, and o).\n\nARGUMENTS:\n   ``a``, ``b``:\n     The two files to compare\n\n   ``context``:\n     How many lines of context to keep between blocks of changes?\n     ``None``, the default, means keep all unchanged lines.\n     ``0`` means throw away all the unchanged lines.\n\n   ``format``:\n     If a dictionary, it is used to format\n     each diff entry.  If true, the default dictionary above is\n     used to format the diff entries.  Otherwise they are returned as-is.\n\n(automatically generated by `doks <https://github.com/rec/doks/>`_ on 2020-11-07T12:19:33.047064)\n\n\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Compute the Myers diff of two lists",
    "version": "1.0.1",
    "split_keywords": [
        "testing",
        "modules"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "md5": "76684d9234e8289784569fbf7865465a",
                "sha256": "2949aff5b7b2c03e6a483bfd109574916e5d9cb339afcfe3d43e1135b2f70aec"
            },
            "downloads": -1,
            "filename": "myers-1.0.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "76684d9234e8289784569fbf7865465a",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 6085,
            "upload_time": "2020-11-07T12:29:30",
            "upload_time_iso_8601": "2020-11-07T12:29:30.854788Z",
            "url": "https://files.pythonhosted.org/packages/d7/b6/d49eba93199c9538d6e4ffa20cf399874a7a5855331990262752fedb8058/myers-1.0.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "md5": "889f014cc88bffce74c260e57360e47b",
                "sha256": "4f9d7681c04e1fd0c61e840e26e22b1bd4d5031887c7d5fb43dccc76e64423a3"
            },
            "downloads": -1,
            "filename": "myers-1.0.1.tar.gz",
            "has_sig": false,
            "md5_digest": "889f014cc88bffce74c260e57360e47b",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 4220,
            "upload_time": "2020-11-07T12:29:32",
            "upload_time_iso_8601": "2020-11-07T12:29:32.546779Z",
            "url": "https://files.pythonhosted.org/packages/ac/49/49cb1d292dbce2999d7c812750f739e71fee2df845cf9852561ff64db5b8/myers-1.0.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2020-11-07 12:29:32",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "github_user": "rec",
    "github_project": "myers",
    "travis_ci": true,
    "coveralls": true,
    "github_actions": false,
    "requirements": [],
    "test_requirements": [
        {
            "name": "coverage",
            "specs": []
        },
        {
            "name": "flake8",
            "specs": []
        },
        {
            "name": "pytest",
            "specs": []
        }
    ],
    "tox": true,
    "lcname": "myers"
}
        
Elapsed time: 0.01649s