AlfredUpdater class final
- Annotations
-
- @autoequal
- @CopyWith()
Constructors
-
AlfredUpdater({required Uri githubRepositoryUrl, required String currentVersion, Duration updateInterval = Duration.zero, AlfredCache<
GithubRelease> ? cache, Client? client}) - Builds an AlfredUpdater
Properties
-
cache
→ AlfredCache<
GithubRelease> ? -
Optionally customize the AlfredCache providing a
Cache
final - client → Client?
-
Optionally customize the
Client
final - currentVersion → String
-
Get a String representation of the
_currentVersion
.no setter - githubRepositoryUrl → Uri
-
The Uri of the workflow's Github repository
final
- hashCode → int
-
The hash code for this object.
no setterinherited
-
props
→ List<
Object?> -
The list of properties that will be used to determine whether
two instances are equal.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- stringify → bool?
-
If set to
true
, the toString method will be overridden to output this instance's props.no setterinherited - updateInterval → Duration
-
How often to automatically check for updates
final
Methods
-
downloadAsset(
GithubAsset asset, {FileSystem? fileSystem, Directory? directory}) → Future< File?> -
Download the '*.alfredworkflow' GithubAsset to the system temp and return a
File
-
fetchLatestRelease(
) → Future< GithubRelease?> - Fetch latest release from the Github Releases API.
-
findAlfredWorkflowAsset(
GithubRelease release) → GithubAsset? - Find the first GithubAsset ending in '.alfredworkflow' file in the GithubRelease assets list.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
openAssetFile(
File assetFile) → Future< void> - Execute the downloaded '*.alfredworkflow' GithubAsset using the macOS open Command
-
toString(
) → String -
A string representation of this object.
inherited
-
update(
) → Future< void> - Convenience method to update the workflow.
-
updateAvailable(
) → Future< bool> - Check if an update is available .
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Constants
- updateKey → const String
- The cache key under which the cached GithubRelease is stored