/AppUpdater

A simple app-updater for macOS, checks your GitHub releases for a binary asset and silently updates your app.

Primary LanguageSwiftMIT LicenseMIT

AppUpdater

A simple app-updater for macOS, checks your GitHub releases for a binary asset and silently updates your app.

English · 简体中文

appupdater.mp4

AppUpdater is a rewrite of mxcl's AppUpdater, because I don't want to depend on the PromiseKit it uses and would prefer to implement it using async/await.

Caveats

  • Assets must be named: \(name)-\(semanticVersion).ext. See Semantic Version
  • Only non-sandboxed apps are supported
  • Implement a settings update page suitable for SwiftUI

Features

  • Full semantic versioning support: we understand alpha/beta etc.
  • We check that the code-sign identity of the download matches the running app before updating. So if you don't code-sign I'm not sure what would happen.
  • We support zip files or tarballs.
  • We support a proxy parameter for those unable to normally access GitHub

Super Easy to Use

Swift Package Manager

package.dependencies.append(.package(url: "https://github.com/s1ntoneli/AppUpdater.git", from: "0.1.5"))

Initialize

var appUpdater = AppUpdater(owner: "s1ntoneli", repo: "AppUpdater")

Check for Updates and Auto Download

appUpdater.check()

Manual Install

appUpdater.install()

SwiftUI

AppUpdater is an ObservableObject, can be used directly in SwiftUI.

More Usage

See the AppUpdaterExample project:

Initialize, Listen: AppUpdaterExampleApp.swift

SwiftUI AppUpdaterSettings: AppUpdaterSettings.swift

Implement Custom Proxy: GithubProxy.swift

Proxy Implementation Reference Gist: github-api-proxy.js

Alternatives

References

My Apps

  • CleanClip: The cleanest clipboard manager on macOS.
  • Macaify: Fast use of ChatGPT on macOS.
  • Copi: A secure clipboard to copy and paste.