onatcipli / rename

The Rename CLI Tool is a utility designed to modify your Flutter project's AppName and BundleId across various platforms, such as iOS, Android, Macos, Linux, Windows and Web
https://pub.dev/packages/rename
MIT License
169 stars 40 forks source link

receiving exception when I tried to rename #4

Closed surapuramakhil closed 4 years ago

surapuramakhil commented 4 years ago

akhil-kfn@tech-laptop-bsd:~/OpenSource/SimpleChatUI$ pub global run rename --bundleId com.akhil.simplechat IOS BundleIdentifier changed successfully to : com.akhil.simplechat Unhandled exception: FileSystemException: Cannot open file, path = 'macos/Runner/Configs/AppInfo.xcconfig' (OS Error: No such file or directory, errno = 2)

0 _File.open. (dart:io/file_impl.dart:366:9)

1 _RootZone.runUnary (dart:async/zone.dart:1439:54)

2 _FutureListener.handleValue (dart:async/future_impl.dart:141:18)

3 Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:682:45)

4 Future._propagateToListeners (dart:async/future_impl.dart:711:32)

5 Future._completeWithValue (dart:async/future_impl.dart:526:5)

6 Future._asyncComplete. (dart:async/future_impl.dart:556:7)

7 _microtaskLoop (dart:async/schedule_microtask.dart:43:21)

8 _startMicrotaskLoop (dart:async/schedule_microtask.dart:52:5)

9 _runPendingImmediateCallback (dart:isolate-patch/isolate_patch.dart:118:13)

10 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:169:5)

lambasoft commented 4 years ago

I had the same issue. The workaround I did was to target each platform separately, so what I did was run both following commands:

flutter pub global run rename --appname yourappname --target android flutter pub global run rename --appname yourappname --target ios

onatcipli commented 4 years ago

thank you for reporting, I will fix it soon

surapuramakhil commented 4 years ago

@onatcipli , from my understanding, if any of the build generated files are missing then it should fall back on build generation then perform rename

onatcipli commented 4 years ago

as you guess you getting this exception because of you don't have macos folder in your flutter project. I fixed it here in 1.2.0 version

thank you for reporting this again. I closing it for now if you face it again feel free to open it