Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[image_picker_ios] Add Swift Package Manager compatibility to image_picker_ios #146919

Closed
2 tasks done
Tracked by #146922
vashworth opened this issue Apr 17, 2024 · 0 comments · Fixed by flutter/packages#6617 or flutter/packages#6693
Closed
2 tasks done
Tracked by #146922
Assignees
Labels
a: plugins Support for writing, building, and running plugin packages fyi-ecosystem For the attention of Ecosystem team p: image_picker The Image Picker plugin. P2 Important issues not at the top of the work list platform-ios iOS applications specifically team-ios Owned by iOS platform team triaged-ios Triaged by iOS platform team

Comments

@vashworth
Copy link
Contributor

vashworth commented Apr 17, 2024

Prerequisites:


Follow "Converting an existing Objective-C Flutter Plugin to a Swift Package" instructions to make image_picker_ios plugin compatible with Swift Package Manager and CocoaPods.

To validate all is working, run the following commands

// Disable swift package manager
flutter config --no-enable-swift-package-manager

// Validate podspec
dart run script/tool/bin/flutter_plugin_tools.dart podspec-check --packages=image_picker_ios

// Create, build, delete an app that has a dependency on all packages
.ci/scripts/create_all_packages_app.sh
.ci/scripts/build_all_packages_app.sh ios debug --no-codesign
rm -rf all_packages

// Build example with CocoaPods
dart run script/tool/bin/flutter_plugin_tools.dart build-examples --ios --packages=image_picker_ios

// Run native tests
dart run script/tool/bin/flutter_plugin_tools.dart native-test --ios --packages=image_picker_ios

// Build example with Swift Package Manager
dart run script/tool/bin/flutter_plugin_tools.dart build-examples --ios --swift-package-manager --packages=image_picker_ios

// Run native tests with Swift Package Manager
dart run script/tool/bin/flutter_plugin_tools.dart native-test --ios --packages=image_picker_ios

// Create, build, delete an app that has a dependency on all packages  with Swift Package Manager
.ci/scripts/create_all_packages_app.sh
.ci/scripts/build_all_packages_app.sh ios debug --no-codesign
rm -rf all_packages
@vashworth vashworth added platform-ios iOS applications specifically p: image_picker The Image Picker plugin. a: plugins Support for writing, building, and running plugin packages team-ios Owned by iOS platform team labels Apr 17, 2024
@vashworth vashworth self-assigned this Apr 17, 2024
@vashworth vashworth added P2 Important issues not at the top of the work list fyi-ecosystem For the attention of Ecosystem team triaged-ios Triaged by iOS platform team labels Apr 17, 2024
auto-submit bot pushed a commit to flutter/packages that referenced this issue May 8, 2024
…picker_ios (#6617)

Makes `image_picker_ios` available as a Swift Package to Flutter. Also, remains compatible with CocoaPods.

Fixes flutter/flutter#146919.
auto-submit bot added a commit to flutter/packages that referenced this issue May 8, 2024
…to image_picker_ios (#6617)" (#6693)

Reverts: #6617
Initiated by: vashworth
Reason for reverting: Failing [Mac_arm64 ios_platform_tests_shard_1 master](https://ci.chromium.org/ui/p/flutter/builders/prod/Mac_arm64%20ios_platform_tests_shard_1%20master/1942/overview)

Original PR Author: vashworth

Reviewed By: {loic-sharma, stuartmorgan}

This change reverts the following previous change:
Makes `image_picker_ios` available as a Swift Package to Flutter. Also, remains compatible with CocoaPods.

Fixes flutter/flutter#146919.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a: plugins Support for writing, building, and running plugin packages fyi-ecosystem For the attention of Ecosystem team p: image_picker The Image Picker plugin. P2 Important issues not at the top of the work list platform-ios iOS applications specifically team-ios Owned by iOS platform team triaged-ios Triaged by iOS platform team
Projects
None yet
1 participant