github

package
v0.2.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 30, 2022 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Scanner

type Scanner struct {
	Crawler shared.Crawler
}

Scanner is struct to scan license info Crawler is exported to modify or make it easy to test by mock

func (*Scanner) ScanLicense

func (s *Scanner) ScanLicense(name, _ string) (string, float64, error)

ScanLicense returns result of Scan on github.com blob objects fetches LICENSE, README,md, or COPYING of master/main branch, and returns license if confidence is over 90% detection logic is depends on github.com/google/licenseclassifier

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL