Skip to content

Commit 3e47db7

Browse files
authored
SwiftPM Support (#165)
* docs: update contributing * feat: swiftpm support
1 parent c4ed3d3 commit 3e47db7

22 files changed

Lines changed: 218 additions & 147 deletions

File tree

CONTRIBUTING.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,11 @@ Thank you for considering contributing to `flutter_web_auth_2`! We appreciate yo
44

55
## Table of Contents
66

7-
- [Code of Conduct](#code-of-conduct)
87
- [How to Contribute](#how-to-contribute)
98
- [Setting Up the Development Environment](#setting-up-the-development-environment)
109
- [Making Changes](#making-changes)
11-
- [Testing](#testing)
1210
- [Documentation](#documentation)
1311
- [Pull Requests](#pull-requests)
14-
- [Community and Communication](#community-and-communication)
1512
- [License](#license)
1613

1714
## How to Contribute

flutter_web_auth_2/example/ios/Flutter/AppFrameworkInfo.plist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,6 @@
2121
<key>CFBundleVersion</key>
2222
<string>1.0</string>
2323
<key>MinimumOSVersion</key>
24-
<string>11.0</string>
24+
<string>12.0</string>
2525
</dict>
2626
</plist>

flutter_web_auth_2/example/ios/Podfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Uncomment this line to define a global platform for your project
2-
# platform :ios, '11.0'
2+
platform :ios, '12.0'
33

44
# CocoaPods analytics sends network stats synchronously affecting flutter build latency.
55
ENV['COCOAPODS_DISABLE_STATS'] = 'true'
@@ -13,7 +13,7 @@ project 'Runner', {
1313
def flutter_root
1414
generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'Generated.xcconfig'), __FILE__)
1515
unless File.exist?(generated_xcode_build_settings_path)
16-
raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure flutter pub get is executed first"
16+
raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure \"flutter pub get\" is executed first"
1717
end
1818

1919
File.foreach(generated_xcode_build_settings_path) do |line|
Lines changed: 2 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,16 @@
11
PODS:
22
- Flutter (1.0.0)
3-
- flutter_web_auth_2 (3.0.0):
4-
- Flutter
5-
- path_provider_foundation (0.0.1):
6-
- Flutter
7-
- FlutterMacOS
8-
- url_launcher_ios (0.0.1):
9-
- Flutter
103

114
DEPENDENCIES:
125
- Flutter (from `Flutter`)
13-
- flutter_web_auth_2 (from `.symlinks/plugins/flutter_web_auth_2/ios`)
14-
- path_provider_foundation (from `.symlinks/plugins/path_provider_foundation/darwin`)
15-
- url_launcher_ios (from `.symlinks/plugins/url_launcher_ios/ios`)
166

177
EXTERNAL SOURCES:
188
Flutter:
199
:path: Flutter
20-
flutter_web_auth_2:
21-
:path: ".symlinks/plugins/flutter_web_auth_2/ios"
22-
path_provider_foundation:
23-
:path: ".symlinks/plugins/path_provider_foundation/darwin"
24-
url_launcher_ios:
25-
:path: ".symlinks/plugins/url_launcher_ios/ios"
2610

2711
SPEC CHECKSUMS:
2812
Flutter: e0871f40cf51350855a761d2e70bf5af5b9b5de7
29-
flutter_web_auth_2: 051cf9f5dc366f31b5dcc4e2952c2b954767be8a
30-
path_provider_foundation: 2b6b4c569c0fb62ec74538f866245ac84301af46
31-
url_launcher_ios: 5334b05cef931de560670eeae103fd3e431ac3fe
3213

33-
PODFILE CHECKSUM: 70d9d25280d0dd177a5f637cdb0f0b0b12c6a189
14+
PODFILE CHECKSUM: 89c2d0a48e0e7e579b0121755579dbc730757d4e
3415

35-
COCOAPODS: 1.15.2
16+
COCOAPODS: 1.16.2

flutter_web_auth_2/example/ios/Runner.xcodeproj/project.pbxproj

Lines changed: 42 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,10 @@
1313
463F629AF31BC8C2DE612341 /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 5F5D718B62640B3682DBCA44 /* Pods_Runner.framework */; };
1414
62FBFB100F7F9D7772987B5C /* Pods_RunnerTests.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E9811F40F3684CF6136758D5 /* Pods_RunnerTests.framework */; };
1515
74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; };
16+
78A318202AECB46A00862997 /* FlutterGeneratedPluginSwiftPackage in Frameworks */ = {isa = PBXBuildFile; productRef = 78A3181F2AECB46A00862997 /* FlutterGeneratedPluginSwiftPackage */; };
1617
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; };
1718
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; };
1819
97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; };
19-
A3143F062D0495028253E2F1 /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6B8E2FE615F702B8C539DF7F /* Pods_Runner.framework */; };
20-
A7A9D35890057D806AACAE05 /* Pods_RunnerTests.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = ECA7C49ED332AB6540F2FFBE /* Pods_RunnerTests.framework */; };
2120
/* End PBXBuildFile section */
2221

2322
/* Begin PBXContainerItemProxy section */
@@ -82,18 +81,11 @@
8281
isa = PBXFrameworksBuildPhase;
8382
buildActionMask = 2147483647;
8483
files = (
84+
78A318202AECB46A00862997 /* FlutterGeneratedPluginSwiftPackage in Frameworks */,
8585
463F629AF31BC8C2DE612341 /* Pods_Runner.framework in Frameworks */,
8686
);
8787
runOnlyForDeploymentPostprocessing = 0;
8888
};
89-
B9ED3590DFDC6A6586B8E77D /* Frameworks */ = {
90-
isa = PBXFrameworksBuildPhase;
91-
buildActionMask = 2147483647;
92-
files = (
93-
A7A9D35890057D806AACAE05 /* Pods_RunnerTests.framework in Frameworks */,
94-
);
95-
runOnlyForDeploymentPostprocessing = 0;
96-
};
9789
/* End PBXFrameworksBuildPhase section */
9890

9991
/* Begin PBXGroup section */
@@ -127,14 +119,6 @@
127119
name = Frameworks;
128120
sourceTree = "<group>";
129121
};
130-
331C8082294A63A400263BE5 /* RunnerTests */ = {
131-
isa = PBXGroup;
132-
children = (
133-
331C807B294A618700263BE5 /* RunnerTests.swift */,
134-
);
135-
path = RunnerTests;
136-
sourceTree = "<group>";
137-
};
138122
9740EEB11CF90186004384FC /* Flutter */ = {
139123
isa = PBXGroup;
140124
children = (
@@ -222,6 +206,9 @@
222206
dependencies = (
223207
);
224208
name = Runner;
209+
packageProductDependencies = (
210+
78A3181F2AECB46A00862997 /* FlutterGeneratedPluginSwiftPackage */,
211+
);
225212
productName = Runner;
226213
productReference = 97C146EE1CF9000F007C117D /* Runner.app */;
227214
productType = "com.apple.product-type.application";
@@ -255,6 +242,9 @@
255242
Base,
256243
);
257244
mainGroup = 97C146E51CF9000F007C117D;
245+
packageReferences = (
246+
781AD8BC2B33823900A9FFBB /* XCLocalSwiftPackageReference "FlutterGeneratedPluginSwiftPackage" */,
247+
);
258248
productRefGroup = 97C146EF1CF9000F007C117D /* Products */;
259249
projectDirPath = "";
260250
projectRoot = "";
@@ -287,43 +277,21 @@
287277
/* End PBXResourcesBuildPhase section */
288278

289279
/* Begin PBXShellScriptBuildPhase section */
290-
1FE375C65236475469EA4B9B /* [CP] Check Pods Manifest.lock */ = {
280+
3B06AD1E1E4923F5004D2608 /* Thin Binary */ = {
291281
isa = PBXShellScriptBuildPhase;
292282
alwaysOutOfDate = 1;
293283
buildActionMask = 2147483647;
294284
files = (
295285
);
296-
inputFileListPaths = (
297-
);
298286
inputPaths = (
299287
"${TARGET_BUILD_DIR}/${INFOPLIST_PATH}",
300288
);
301-
name = "[CP] Check Pods Manifest.lock";
302-
outputFileListPaths = (
303-
);
289+
name = "Thin Binary";
304290
outputPaths = (
305-
"$(DERIVED_FILE_DIR)/Pods-RunnerTests-checkManifestLockResult.txt",
306291
);
307292
runOnlyForDeploymentPostprocessing = 0;
308293
shellPath = /bin/sh;
309-
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin";
310-
};
311-
3B151151EEB90F686DCC201A /* [CP] Embed Pods Frameworks */ = {
312-
isa = PBXShellScriptBuildPhase;
313-
alwaysOutOfDate = 1;
314-
buildActionMask = 2147483647;
315-
files = (
316-
);
317-
inputFileListPaths = (
318-
"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-input-files.xcfilelist",
319-
);
320-
name = "[CP] Embed Pods Frameworks";
321-
outputFileListPaths = (
322-
"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-output-files.xcfilelist",
323-
);
324-
runOnlyForDeploymentPostprocessing = 0;
325-
shellPath = /bin/sh;
326-
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin";
294+
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin\n";
327295
};
328296
608B7EE9FA07C439862030C3 /* [CP] Check Pods Manifest.lock */ = {
329297
isa = PBXShellScriptBuildPhase;
@@ -370,6 +338,23 @@
370338
shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
371339
showEnvVarsInLog = 0;
372340
};
341+
3B151151EEB90F686DCC201A /* [CP] Embed Pods Frameworks */ = {
342+
isa = PBXShellScriptBuildPhase;
343+
alwaysOutOfDate = 1;
344+
buildActionMask = 2147483647;
345+
files = (
346+
);
347+
inputFileListPaths = (
348+
"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-input-files.xcfilelist",
349+
);
350+
name = "[CP] Embed Pods Frameworks";
351+
outputFileListPaths = (
352+
"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-output-files.xcfilelist",
353+
);
354+
runOnlyForDeploymentPostprocessing = 0;
355+
shellPath = /bin/sh;
356+
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin";
357+
};
373358
9740EEB61CF901F6004384FC /* Run Script */ = {
374359
isa = PBXShellScriptBuildPhase;
375360
alwaysOutOfDate = 1;
@@ -764,6 +749,20 @@
764749
defaultConfigurationName = Release;
765750
};
766751
/* End XCConfigurationList section */
752+
753+
/* Begin XCLocalSwiftPackageReference section */
754+
781AD8BC2B33823900A9FFBB /* XCLocalSwiftPackageReference "FlutterGeneratedPluginSwiftPackage" */ = {
755+
isa = XCLocalSwiftPackageReference;
756+
relativePath = Flutter/ephemeral/Packages/FlutterGeneratedPluginSwiftPackage;
757+
};
758+
/* End XCLocalSwiftPackageReference section */
759+
760+
/* Begin XCSwiftPackageProductDependency section */
761+
78A3181F2AECB46A00862997 /* FlutterGeneratedPluginSwiftPackage */ = {
762+
isa = XCSwiftPackageProductDependency;
763+
productName = FlutterGeneratedPluginSwiftPackage;
764+
};
765+
/* End XCSwiftPackageProductDependency section */
767766
};
768767
rootObject = 97C146E61CF9000F007C117D /* Project object */;
769768
}

flutter_web_auth_2/example/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,28 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<Scheme
3-
LastUpgradeVersion = "1540"
3+
LastUpgradeVersion = "1510"
44
version = "1.3">
55
<BuildAction
66
parallelizeBuildables = "YES"
77
buildImplicitDependencies = "YES">
8+
<PreActions>
9+
<ExecutionAction
10+
ActionType = "Xcode.IDEStandardExecutionActionsCore.ExecutionActionType.ShellScriptAction">
11+
<ActionContent
12+
title = "Run Prepare Flutter Framework Script"
13+
scriptText = "/bin/sh &quot;$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh&quot; prepare&#10;">
14+
<EnvironmentBuildable>
15+
<BuildableReference
16+
BuildableIdentifier = "primary"
17+
BlueprintIdentifier = "97C146ED1CF9000F007C117D"
18+
BuildableName = "Runner.app"
19+
BlueprintName = "Runner"
20+
ReferencedContainer = "container:Runner.xcodeproj">
21+
</BuildableReference>
22+
</EnvironmentBuildable>
23+
</ActionContent>
24+
</ExecutionAction>
25+
</PreActions>
826
<BuildActionEntries>
927
<BuildActionEntry
1028
buildForTesting = "YES"
@@ -59,6 +77,7 @@
5977
ignoresPersistentStateOnLaunch = "NO"
6078
debugDocumentVersioning = "YES"
6179
debugServiceExtension = "internal"
80+
enableGPUValidationMode = "1"
6281
allowLocationSimulation = "YES">
6382
<BuildableProductRunnable
6483
runnableDebuggingMode = "0">
Lines changed: 3 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,47 +1,28 @@
11
PODS:
22
- desktop_webview_window (0.0.1):
33
- FlutterMacOS
4-
- flutter_web_auth_2 (3.0.0):
5-
- FlutterMacOS
64
- FlutterMacOS (1.0.0)
7-
- path_provider_foundation (0.0.1):
8-
- Flutter
9-
- FlutterMacOS
10-
- url_launcher_macos (0.0.1):
11-
- FlutterMacOS
125
- window_to_front (0.0.1):
136
- FlutterMacOS
147

158
DEPENDENCIES:
169
- desktop_webview_window (from `Flutter/ephemeral/.symlinks/plugins/desktop_webview_window/macos`)
17-
- flutter_web_auth_2 (from `Flutter/ephemeral/.symlinks/plugins/flutter_web_auth_2/macos`)
1810
- FlutterMacOS (from `Flutter/ephemeral`)
19-
- path_provider_foundation (from `Flutter/ephemeral/.symlinks/plugins/path_provider_foundation/darwin`)
20-
- url_launcher_macos (from `Flutter/ephemeral/.symlinks/plugins/url_launcher_macos/macos`)
2111
- window_to_front (from `Flutter/ephemeral/.symlinks/plugins/window_to_front/macos`)
2212

2313
EXTERNAL SOURCES:
2414
desktop_webview_window:
2515
:path: Flutter/ephemeral/.symlinks/plugins/desktop_webview_window/macos
26-
flutter_web_auth_2:
27-
:path: Flutter/ephemeral/.symlinks/plugins/flutter_web_auth_2/macos
2816
FlutterMacOS:
2917
:path: Flutter/ephemeral
30-
path_provider_foundation:
31-
:path: Flutter/ephemeral/.symlinks/plugins/path_provider_foundation/darwin
32-
url_launcher_macos:
33-
:path: Flutter/ephemeral/.symlinks/plugins/url_launcher_macos/macos
3418
window_to_front:
3519
:path: Flutter/ephemeral/.symlinks/plugins/window_to_front/macos
3620

3721
SPEC CHECKSUMS:
38-
desktop_webview_window: d4365e71bcd4e1aa0c14cf0377aa24db0c16a7e2
39-
flutter_web_auth_2: 2e1dc2d2139973e4723c5286ce247dd590390d70
22+
desktop_webview_window: 7e37af677d6d19294cb433d9b1d878ef78dffa4d
4023
FlutterMacOS: 8f6f14fa908a6fb3fba0cd85dbd81ec4b251fb24
41-
path_provider_foundation: 2b6b4c569c0fb62ec74538f866245ac84301af46
42-
url_launcher_macos: 5f437abeda8c85500ceb03f5c1938a8c5a705399
43-
window_to_front: 4cdc24ddd8461ad1a55fa06286d6a79d8b29e8d8
24+
window_to_front: 9e76fd432e36700a197dac86a0011e49c89abe0a
4425

4526
PODFILE CHECKSUM: 9ebaf0ce3d369aaa26a9ea0e159195ed94724cf3
4627

47-
COCOAPODS: 1.15.2
28+
COCOAPODS: 1.16.2

0 commit comments

Comments
 (0)