launch_at_startup
0.5.1, released 2 years ago by leanflutter.dev
Allows Flutter desktop apps to automatically launch on startup or login.
What it does
Provides an API to configure, enable, disable, and check the launch-at-startup status for Flutter desktop applications across Windows, macOS, and Linux.
AI-written summary of version 0.5.1, based on the package's README and metadata. Report an inaccuracy
Use it when
- You are building a Flutter desktop application for Windows, macOS, or Linux.
- Your app needs the capability to start automatically when the user logs in or boots the system.
Skip it when
- You are building for mobile or web platforms.
- You do not want your app running in the background immediately upon user login.
Strengths
- Supports multiple desktop platforms (Windows, macOS, Linux).
- Simple API to enable, disable, and check launch status.
Weaknesses
- Requires manual native setup on macOS (Swift package and build phase configuration).
- Requires proper app info (such as app name and executable path) to function correctly.
Setup
- Kind
- Flutter widgets
- Effort
- Medium
- Code generation
- No
- Direct dependencies
- 1
Requires initialization code and platform-specific setup on macOS involving Xcode and Swift package dependencies.
void main() async {
WidgetsFlutterBinding.ensureInitialized();
PackageInfo packageInfo = await PackageInfo.fromPlatform();
launchAtStartup.setup(
appName: packageInfo.appName,
appPath: Platform.resolvedExecutable,
packageName: 'dev.leanflutter.examples.launchatstartupexample',
);
await launchAtStartup.enable();
bool isEnabled = await launchAtStartup.isEnabled();
runApp(const MyApp());
}Alternatives
Packages that do the same job and could replace launch_at_startup.
- xdg_desktop_portal
A native Dart implementation of portals for Linux desktop applications.
75Compare - auto_updater
Allows Flutter desktop apps to automatically update themselves based on Sparkle and WinSparkle.
50Compare - screen_capturer
Allows Flutter desktop apps to take screenshots.
50Compare - flutter_webview_plugin
Plugin that allows Flutter to communicate with a native WebView.
50Compare
Works with
Packages commonly used together with launch_at_startup: ones it builds on, ones built on it, and its own family.