Tool to automatically detect FLOSS licenses
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.
Johann Schmitz dee6505a62
7 years ago
src Print changes in match list; find COPYING files in subdirs too 7 years ago
.gitignore Initial commit 7 years ago
LICENSE.txt Added license 7 years ago Added 7 years ago

Tool to automatically detect FLOSS licenses.

license-finder needs a folder with license files (defaults to /usr/portage/licenses for easy use on Gentoo).


license-finder <directory>

Other options

usage: license-finder [-h] [--licenses-dir LICENSES_DIR]
                      [--min-ratio MIN_RATIO] [-n N]
                      files_or_dirs [files_or_dirs ...]

positional arguments:

optional arguments:
  -h, --help            show this help message and exit
  --licenses-dir LICENSES_DIR
                        Directory to look for licenses (default:
  --min-ratio MIN_RATIO
                        Minimum ratio to consider the file as a match
                        (default: 0.8)
  -n N                  Show at most x matching licenses

Example output:

  97.791 %: /usr/portage/licenses/GPL-2 (+0 -0 ~4)
  96.934 %: /usr/portage/licenses/GPL-2-with-font-exception (+0 -1 ~4)
  96.093 %: /usr/portage/licenses/GPL-2-with-linking-exception (+0 -1 ~4)
  95.954 %: /usr/portage/licenses/GPL-2-with-exceptions (+0 -1 ~4)
  86.207 %: /usr/portage/licenses/kvirc (+0 -1 ~3)