fluttercommunity / flutter_launcher_icons

Flutter Launcher Icons - A package which simplifies the task of updating your Flutter app's launcher icon. Fully flexible, allowing you to choose what platform you wish to update the launcher icon for and if you want, the option to keep your old launcher icon in case you want to revert back sometime in the future. Maintainer: @MarkOSullivan94
https://pub.dev/packages/flutter_launcher_icons
MIT License
1.97k stars 390 forks source link

[BUG] Could not find a file named "pubspec.yaml" #547

Open MH0386 opened 4 months ago

MH0386 commented 4 months ago

:information_source: Info

Version: e.g. v0.13.1

:speech_balloon: Description

input: flutter pub run flutter_launcher_icons:generate output:

Deprecated. Use dart run  instead.
Could not find a file named "pubspec.yaml" in "C:\Users\moham\AppData\Local\Pub\Cache\hosted\pub.dev\path_provider_windows-2.2.1".

:scroll: Pubspec.yaml

name: chatacter
description: "A new Flutter project."
version: 1.0.0+1
environment:
    sdk: ">=3.3.0 <4.0.0"
dependencies:
    flutter:
        sdk: flutter
    cupertino_icons: ^1.0.6
    http: ^1.2.1
    animated_text_kit: ^4.2.2
    font_awesome_flutter: ^10.7.0
    url_launcher: ^6.2.5
    # google_fonts: ^6.2.0
    path_provider: ^2.0.8
    flutter_launcher_icons: ^0.13.1
dev_dependencies:
    flutter_test:
        sdk: flutter
    flutter_lints: ^3.0.0
    rename: ^3.0.1
flutter_launcher_icons:
    android: true
    image_path: "assets/app_logo.png"
    min_sdk_android: 21 # android min sdk min:16, default 21
    web:
        generate: true
        image_path: "assets/app_logo.png"
        background_color: "#hexcode"
        theme_color: "#hexcode"
    windows:
        generate: true
        image_path: "assets/app_logo.png"
        icon_size: 48
flutter:
    uses-material-design: true
KomInc commented 4 months ago

You have to replaceflutter_launcher_icons by _flutter_icons_ in your pubspec.yaml file.

For instance :


flutter_icons:
  android: "launcher_icon"
  ios: true
  image_path: "assets/app_logo.png"```
dizzib commented 3 weeks ago

This seems to be an issue with dart run. The following fixed it for me…

flutter clean

@Kominc running v0.13.1 yields this warning:

⚠ Warning: flutter_icons has been deprecated please use flutter_launcher_icons instead in your yaml files