Skip to main content

A script to guess licenses based on text

Project description


Heavily inspired by this will provide an API to guess what license a given file represents.

>>> from infer_license import guess_file
>>> print(guess_file("LICENSE"))
License(name='MIT License', shortname='MIT', trove_classifier='License :: OSI Approved :: MIT License')
>>> guess_file("")

There's also a handy infer_license script that takes a filename.

$ infer_license LICENSE


infer-license is copyright Tim Hatch, and licensed under the MIT license. I am providing code in this repository to you under an open source license. This is my personal repository; the license you receive to my code is from me and not from my employer. See the LICENSE file for details.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for infer-license, version 0.0.7
Filename, size File type Python version Upload date Hashes
Filename, size infer_license-0.0.7-py3-none-any.whl (79.6 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size infer-license-0.0.7.tar.gz (61.3 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page