dephell-licenses


Namedephell-licenses JSON
Version 0.1.7 PyPI version JSON
download
home_page
SummaryGet info about OSS licenses
upload_time2020-05-15 12:46:57
maintainer
docs_urlNone
authorGram
requires_python>=3.5
licenseMIT
keywords dephell packaging licenses pypi
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI
coveralls test coverage No coveralls.
            # DepHell Licenses

[![travis](https://travis-ci.org/dephell/dephell_licenses.svg?branch=master)](https://travis-ci.org/dephell/dephell_licenses)
[![appveyor](https://ci.appveyor.com/api/projects/status/github/dephell/dephell_licenses?svg=true)](https://ci.appveyor.com/project/orsinium/dephell-licenses)
[![MIT License](https://img.shields.io/pypi/l/dephell-licenses.svg)](https://github.com/dephell/dephell_licenses/blob/master/LICENSE)

Manage OSS licenses: retrieve information, generate.

## Installation

Install from [PyPI](https://pypi.org/project/dephell-licenses/):

```bash
python3 -m pip install --user dephell_licenses
```

## Usage

```python
from dephell_licenses import licenses

# ways to get a license:
license = licenses.get_by_id('MIT')
license = licenses.get_by_name('MIT License')
license = licenses.get_by_classifier('License :: OSI Approved :: MIT License')

# license object
license
# License(id='MIT', classifier='License :: OSI Approved :: MIT License', name='MIT License', approved=True, deprecated=False, links=['https://opensource.org/licenses/MIT'], url='http://spdx.org/licenses/MIT.json')

# generate license
license.make_text(copyright='2019 Gram')
# 'MIT License\n\nCopyright (c) 2019 Gram\n\nPermission is hereby granted ...'
```

## Most popular licenses

```bash
go run stat.go | grep "License :: " | perl -F"\|" -lane 'print $F[0] if $F[1]>100' | sort
```

There is the full list of the license classifiers with more than 100 projects that uses it:

```
License :: CC0 1.0 Universal (CC0 1.0) Public Domain Dedication
License :: DFSG approved
License :: Free for non-commercial use
License :: Freely Distributable
License :: Freeware
License :: OSI Approved
License :: OSI Approved :: Apache Software License
License :: OSI Approved :: BSD License
License :: OSI Approved :: GNU Affero General Public License v3
License :: OSI Approved :: GNU Affero General Public License v3 or later (AGPLv3+)
License :: OSI Approved :: GNU General Public License (GPL)
License :: OSI Approved :: GNU General Public License v2 (GPLv2)
License :: OSI Approved :: GNU General Public License v2 or later (GPLv2+)
License :: OSI Approved :: GNU General Public License v3 (GPLv3)
License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)
License :: OSI Approved :: GNU Lesser General Public License v2 (LGPLv2)
License :: OSI Approved :: GNU Lesser General Public License v2 or later (LGPLv2+)
License :: OSI Approved :: GNU Lesser General Public License v3 (LGPLv3)
License :: OSI Approved :: GNU Lesser General Public License v3 or later (LGPLv3+)
License :: OSI Approved :: GNU Library or Lesser General Public License (LGPL)
License :: OSI Approved :: ISC License (ISCL)
License :: OSI Approved :: MIT License
License :: OSI Approved :: Mozilla Public License 2.0 (MPL 2.0)
License :: OSI Approved :: Python Software Foundation License
License :: OSI Approved :: Zope Public License
License :: Other/Proprietary License
License :: Public Domain
License :: Repoze Public License
```

            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "dephell-licenses",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.5",
    "maintainer_email": "",
    "keywords": "dephell,packaging,licenses,pypi",
    "author": "Gram",
    "author_email": "gram@orsinium.dev",
    "download_url": "https://files.pythonhosted.org/packages/de/74/b66e2e7246cab2f6323d81f1ef81ad9f21636f12603b21305db658fb7896/dephell-licenses-0.1.7.tar.gz",
    "platform": "None",
    "description": "# DepHell Licenses\n\n[![travis](https://travis-ci.org/dephell/dephell_licenses.svg?branch=master)](https://travis-ci.org/dephell/dephell_licenses)\n[![appveyor](https://ci.appveyor.com/api/projects/status/github/dephell/dephell_licenses?svg=true)](https://ci.appveyor.com/project/orsinium/dephell-licenses)\n[![MIT License](https://img.shields.io/pypi/l/dephell-licenses.svg)](https://github.com/dephell/dephell_licenses/blob/master/LICENSE)\n\nManage OSS licenses: retrieve information, generate.\n\n## Installation\n\nInstall from [PyPI](https://pypi.org/project/dephell-licenses/):\n\n```bash\npython3 -m pip install --user dephell_licenses\n```\n\n## Usage\n\n```python\nfrom dephell_licenses import licenses\n\n# ways to get a license:\nlicense = licenses.get_by_id('MIT')\nlicense = licenses.get_by_name('MIT License')\nlicense = licenses.get_by_classifier('License :: OSI Approved :: MIT License')\n\n# license object\nlicense\n# License(id='MIT', classifier='License :: OSI Approved :: MIT License', name='MIT License', approved=True, deprecated=False, links=['https://opensource.org/licenses/MIT'], url='http://spdx.org/licenses/MIT.json')\n\n# generate license\nlicense.make_text(copyright='2019 Gram')\n# 'MIT License\\n\\nCopyright (c) 2019 Gram\\n\\nPermission is hereby granted ...'\n```\n\n## Most popular licenses\n\n```bash\ngo run stat.go | grep \"License :: \" | perl -F\"\\|\" -lane 'print $F[0] if $F[1]>100' | sort\n```\n\nThere is the full list of the license classifiers with more than 100 projects that uses it:\n\n```\nLicense :: CC0 1.0 Universal (CC0 1.0) Public Domain Dedication\nLicense :: DFSG approved\nLicense :: Free for non-commercial use\nLicense :: Freely Distributable\nLicense :: Freeware\nLicense :: OSI Approved\nLicense :: OSI Approved :: Apache Software License\nLicense :: OSI Approved :: BSD License\nLicense :: OSI Approved :: GNU Affero General Public License v3\nLicense :: OSI Approved :: GNU Affero General Public License v3 or later (AGPLv3+)\nLicense :: OSI Approved :: GNU General Public License (GPL)\nLicense :: OSI Approved :: GNU General Public License v2 (GPLv2)\nLicense :: OSI Approved :: GNU General Public License v2 or later (GPLv2+)\nLicense :: OSI Approved :: GNU General Public License v3 (GPLv3)\nLicense :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)\nLicense :: OSI Approved :: GNU Lesser General Public License v2 (LGPLv2)\nLicense :: OSI Approved :: GNU Lesser General Public License v2 or later (LGPLv2+)\nLicense :: OSI Approved :: GNU Lesser General Public License v3 (LGPLv3)\nLicense :: OSI Approved :: GNU Lesser General Public License v3 or later (LGPLv3+)\nLicense :: OSI Approved :: GNU Library or Lesser General Public License (LGPL)\nLicense :: OSI Approved :: ISC License (ISCL)\nLicense :: OSI Approved :: MIT License\nLicense :: OSI Approved :: Mozilla Public License 2.0 (MPL 2.0)\nLicense :: OSI Approved :: Python Software Foundation License\nLicense :: OSI Approved :: Zope Public License\nLicense :: Other/Proprietary License\nLicense :: Public Domain\nLicense :: Repoze Public License\n```\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Get info about OSS licenses",
    "version": "0.1.7",
    "project_urls": {
        "Repository": "https://github.com/dephell/dephell_licenses"
    },
    "split_keywords": [
        "dephell",
        "packaging",
        "licenses",
        "pypi"
    ],
    "urls": [
        {
            "comment_text": "None",
            "digests": {
                "blake2b_256": "c4d2619600c56f79bc71e989263d2e8ce9b3670c6389c2d4cad3aa8c92bd3aed",
                "md5": "b0de0dd7f6c8c6724919cc7f79f7f0c8",
                "sha256": "b0b6c93779c4a8d9a82710ef2d5d0fab72e013f335962dc7363831af48570db5"
            },
            "downloads": -1,
            "filename": "dephell_licenses-0.1.7-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "b0de0dd7f6c8c6724919cc7f79f7f0c8",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.5",
            "size": 9414,
            "upload_time": "2020-05-15T12:46:58",
            "upload_time_iso_8601": "2020-05-15T12:46:58.967206Z",
            "url": "https://files.pythonhosted.org/packages/c4/d2/619600c56f79bc71e989263d2e8ce9b3670c6389c2d4cad3aa8c92bd3aed/dephell_licenses-0.1.7-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "None",
            "digests": {
                "blake2b_256": "de74b66e2e7246cab2f6323d81f1ef81ad9f21636f12603b21305db658fb7896",
                "md5": "5fc4eb516e2cad4c0d74b88f42b6e9b5",
                "sha256": "f175cec822a32bda5b56442f48dae39efbb5c3851275ecd41cfd7e849ddd2ea6"
            },
            "downloads": -1,
            "filename": "dephell-licenses-0.1.7.tar.gz",
            "has_sig": false,
            "md5_digest": "5fc4eb516e2cad4c0d74b88f42b6e9b5",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.5",
            "size": 9460,
            "upload_time": "2020-05-15T12:46:57",
            "upload_time_iso_8601": "2020-05-15T12:46:57.537887Z",
            "url": "https://files.pythonhosted.org/packages/de/74/b66e2e7246cab2f6323d81f1ef81ad9f21636f12603b21305db658fb7896/dephell-licenses-0.1.7.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2020-05-15 12:46:57",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "dephell",
    "github_project": "dephell_licenses",
    "travis_ci": true,
    "coveralls": false,
    "github_actions": false,
    "appveyor": true,
    "lcname": "dephell-licenses"
}
        
Elapsed time: 0.16512s