licensee/licensee ↗
Created Feb 15, 2021 · View the licensee/licensee repository page
A Ruby Gem to detect under what license a project is distributed.
Want this for your repo?
Render a free sample of any GitHub repo in seconds.
Contributors
49
Lines of Code
3,312
From
Aug 16, 2014
To
Feb 11, 2021
About licensee/licensee
Licensee is a Ruby gem that automatically detects the license under which an open-source project is distributed by analyzing license files. It addresses the common challenge of identifying project licenses across large portfolios of software and determining whether license files have been modified or customized from their original text.
The gem uses multiple matching strategies to identify licenses with increasing sophistication. It first checks for explicit copyright notices indicating retained rights, then attempts exact string matching after normalizing whitespace and removing copyright information. When exact matches fail, it employs the Sørensen–Dice coefficient algorithm to calculate similarity percentages between the project's license file and known licenses, allowing it to identify licenses that have been slightly modified or altered.
Licensee can be installed as a standard Ruby gem and used programmatically within other projects or run as a command-line tool. It supports optional Git repository scanning through the rugged gem for analyzing bare repositories without working trees, and provides Docker support for containerized environments. The project includes comprehensive documentation covering usage, customization options, and contribution guidelines.