Documentation
¶
Overview ¶
Package thirdparty is the third-party licence file an ActNow app ships (ThirdPartyLicenses.txt in the app's resources): its format, which cmd/actnow-licenses writes and the app's Settings read, and the licence classifier the generator uses to refuse copyleft licences. The family's apps are closed source: no GPL, LGPL or AGPL in what is linked into them; separate programs that ship beside an app, such as ffmpeg, keep their own licence (Ships: program).
The file is plain text, readable as is: a preamble, then one block per component, each opened by a Rule line and a few "Key: value" lines:
################################################################################
Name: mlx-swift
Version: 0.32.3
Source: https://github.com/ml-explore/mlx-swift
Licence: MIT (also Apache-2.0, BSD-3-Clause)
Use: … (optional)
Ships: program (optional: a separate program in the app,
not linked into it)
<the licence texts>
Index ¶
Constants ¶
const FileName = "ThirdPartyLicenses.txt"
FileName is the file's name in the app's resources directory.
const ShipsProgram = "program"
ShipsProgram is the Ships value of a separate program: an executable that ships inside the app and that the app runs, not code linked into it.
Variables ¶
var Rule = strings.Repeat("#", 80)
Rule opens a component's block.
Functions ¶
func Check ¶
Check reports the first component of the file's text that a closed-source app may not ship: one linked in (not a separate program) under a GNU licence, with those licences; "" when there is none.
func Classify ¶
Classify returns the licences text is or contains, without repeats, in markers' order; nil when it knows none.
func Copyleft ¶
Copyleft reports whether a licence id is one a closed-source app may not link: the GNU licences.
func CopyleftIn ¶
CopyleftIn returns the copyleft licences a Licence line names.
Types ¶
type Component ¶
type Component struct {
Name, Version, Source, Licence, Use string
Ships string // ShipsProgram, or "" for what is linked in
Text string // the licence texts
}
Component is one block of the file.