flet clean
Delete the build output of a Flet app, and optionally Flet's caches and SDKs.
By default, removes the build directory created by flet build and
flet debug in the given app directory: the Flutter bootstrap project,
cached artifacts, and generated output.
--cache also removes the files Flet downloads as it builds and runs apps,
and --sdks the SDKs Flet installed. Both show what will be deleted, with
sizes, and ask before deleting anything. --unused limits them to what the
installed Flet version doesn't use.
Usage
flet clean [-h] [-v] [--cache] [--sdks] [--unused] [--dry-run] [-y]
[--force]
[python_app_path]
Positional arguments
python_app_path
Path to a directory with a Flet Python program whose build directory should be deleted.
Default: .
Options
--cache
Also delete the files Flet downloads as it builds and runs apps: the build cache (~/.flet/cache, or the downloads Flet wrote into FLET_CACHE_DIR when it is set) and the desktop clients in ~/.flet/client. They are downloaded again when needed.
--dry-run
Show what would be deleted, with sizes, without deleting anything.
--force
Delete the app's build directory even when it was not created by flet build or flet debug.
--help
Show this help message and exit.
Aliases: -h
--sdks
Also delete the SDKs Flet installed: the Flutter SDKs in ~/flutter, the JDKs in ~/java and the Android SDK in ~/Android/sdk (Android emulators that use it stop working until it is installed again). The SDK at Android Studio's default location, and an SDK that PATH, FLUTTER_ROOT, JAVA_HOME, ANDROID_HOME or ANDROID_SDK_ROOT point to, are kept. The SDKs are downloaded again when a build needs them.
--unused
Delete only what the installed Flet version doesn't use: older Flutter SDKs and JDKs, and the cached downloads and desktop clients of other versions. The app's build directory and the Android SDK are kept. Applies to --cache and --sdks, or to both when neither is given.
--verbose
Enable verbose output. Use -v for standard verbose logging and -vv for more detailed output.
Aliases: -v
--yes
Delete without asking for confirmation. Required with --cache or --sdks when the input is not a terminal.
Aliases: -y