GitHubRepo class final

A GitHub repository, as https://github.com/<owner>/<repo> names it.

Its release files are plain downloads from GitHub's CDN — https://github.com/<owner>/<repo>/releases/download/<tag>/<file>, or .../releases/latest/download/<file> for the newest release — not the GitHub API, which allows only 60 requests an hour without signing in. That is why every package release carries a file with a fixed name, manifestFile, that says what the release holds.

Constructors

GitHubRepo(String owner, String name)
The repository owner/name: neither empty nor . or .. (asserted in debug builds). tryParse checks text from a person in full.
const

Properties

hashCode → int
The hash code for this object.
no setteroverride
name → String
The repository's name.
final
owner → String
The account or organisation.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
url → Uri
The repository's page.
no setter

Methods

manifest({String? tag}) → Uri
The manifestFile of tag, or of the newest release.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
releaseFile(String file, {String? tag}) → Uri
The release file file of tag, or of the newest release when tag is null.
toString() → String
A string representation of this object.
override

Operators

operator ==(Object other) → bool
The equality operator.
override

Static Methods

tryParse(String text) → GitHubRepo?
Reads https://github.com/<owner>/<repo> (with or without .git, a trailing /, or www.), github.com/<owner>/<repo>, or <owner>/<repo>. Null for anything else — including any other host.

Constants

manifestFile → const String
The file every release of a package carries, describing it: version, archive and SHA-256.