移动开发

flutter-environment-setup-windows

flutter/agent-plugins

Set up a Windows environment for Flutter development

  • 811 次安装
  • 3100 星标
  • 收录于

安装命令

npx skills add https://github.com/flutter/agent-plugins --skill flutter-environment-setup-windows

SKILL.md

Goal

Configures a Windows development environment for building Flutter applications targeting Windows Desktop and Android. Analyzes system requirements, modifies environment variables, installs necessary C++ toolchains, manages platform-specific configurations, and generates self-signed certificates for local Windows application deployment. Assumes the host machine is running Windows 10 or 11 with administrative privileges available for system modifications.

Instructions

  1. Configure Flutter SDK and Environment Variables Extract the Flutter SDK to a secure, user-writable directory (e.g., C:\develop\flutter). Do not place it in C:\Program Files\. Execute the following PowerShell command to append the Flutter bin directory to the user's PATH:
    $flutterBinPath = "C:\develop\flutter\bin"
    $currentUserPath = [Environment]::GetEnvironmentVariable("Path", [EnvironmentVariableTarget]::User)
    if ($currentUserPath -notmatch [regex]::Escape($flutterBinPath)) {
        [Environment]::SetEnvironmentVariable("Path", "$currentUserPath;$flutterBinPath", [EnvironmentVariableTarget]::User)
    }