diff --git a/.gitignore b/.gitignore index be28bee..4f464c0 100644 --- a/.gitignore +++ b/.gitignore @@ -9,3 +9,6 @@ xcuserdata /BTFuse.podspec /BTFuseTestTools.podspec /Pods +*.docc-build +*.profraw + diff --git a/BTFuse.xcworkspace/contents.xcworkspacedata b/BTFuse.xcworkspace/contents.xcworkspacedata index 7915010..d1dbe28 100644 --- a/BTFuse.xcworkspace/contents.xcworkspacedata +++ b/BTFuse.xcworkspace/contents.xcworkspacedata @@ -1,6 +1,9 @@ + + diff --git a/BTFuse/BTFuse.docc/BTFuse.md b/BTFuse/BTFuse.docc/BTFuse.md new file mode 100644 index 0000000..a01c332 --- /dev/null +++ b/BTFuse/BTFuse.docc/BTFuse.md @@ -0,0 +1,13 @@ +# ``BTFuse`` + +Summary + +## Overview + +Text + +## Topics + +### Group + +- ``Symbol`` \ No newline at end of file diff --git a/BTFuse/BTFuse.xcodeproj/project.pbxproj b/BTFuse/BTFuse.xcodeproj/project.pbxproj index e78300b..dd5f36b 100644 --- a/BTFuse/BTFuse.xcodeproj/project.pbxproj +++ b/BTFuse/BTFuse.xcodeproj/project.pbxproj @@ -77,6 +77,7 @@ 94B7A9D02AC89E39003D294D /* BTFuse.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 94A886C22A714F6D0098530D /* BTFuse.framework */; platformFilter = ios; }; 94C3AF282B6867B8006AD040 /* LICENSE in Resources */ = {isa = PBXBuildFile; fileRef = 94C3AF272B6867B8006AD040 /* LICENSE */; }; 94DF9FB72B293C9C00757EA7 /* UniformTypeIdentifiers.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 94DF9FB62B293C9C00757EA7 /* UniformTypeIdentifiers.framework */; }; + 94F13A1D2CA4EF1800CCCC89 /* BTFuse.docc in Sources */ = {isa = PBXBuildFile; fileRef = 94F13A1C2CA4EF1800CCCC89 /* BTFuse.docc */; }; /* End PBXBuildFile section */ /* Begin PBXContainerItemProxy section */ @@ -164,6 +165,7 @@ 94B7A9CE2AC89E39003D294D /* BTFuseTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = BTFuseTests.m; sourceTree = ""; }; 94C3AF272B6867B8006AD040 /* LICENSE */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = LICENSE; path = ../LICENSE; sourceTree = ""; }; 94DF9FB62B293C9C00757EA7 /* UniformTypeIdentifiers.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UniformTypeIdentifiers.framework; path = System/Library/Frameworks/UniformTypeIdentifiers.framework; sourceTree = SDKROOT; }; + 94F13A1C2CA4EF1800CCCC89 /* BTFuse.docc */ = {isa = PBXFileReference; lastKnownFileType = folder.documentationcatalog; path = BTFuse.docc; sourceTree = ""; }; C0D504787CFDCC13C7D8462D /* Pods-BTFuse.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-BTFuse.release.xcconfig"; path = "Target Support Files/Pods-BTFuse/Pods-BTFuse.release.xcconfig"; sourceTree = ""; }; D2524D348AB6B72B049BC41D /* Pods-BTFuse.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-BTFuse.debug.xcconfig"; path = "Target Support Files/Pods-BTFuse/Pods-BTFuse.debug.xcconfig"; sourceTree = ""; }; /* End PBXFileReference section */ @@ -242,6 +244,7 @@ 94A8864F2A702C6C0098530D = { isa = PBXGroup; children = ( + 94F13A1C2CA4EF1800CCCC89 /* BTFuse.docc */, 94C3AF272B6867B8006AD040 /* LICENSE */, 944112B92AED442300309527 /* PrivacyInfo.xcprivacy */, 94552C592ACB349A00DAE0F4 /* configurations */, @@ -462,6 +465,9 @@ BuildIndependentTargetsInParallel = 1; LastUpgradeCheck = 1510; TargetAttributes = { + 94A886B52A714F6D0098530D = { + LastSwiftMigration = 1600; + }; 94B7A9CB2AC89E39003D294D = { CreatedOnToolsVersion = 15.0; }; @@ -544,6 +550,7 @@ 9443F0B12B1AA9550056B054 /* BTFuseNWErrorFactory.m in Sources */, 94A928532B13E4C700AAC44A /* BTFuseAPIServerHeaders.m in Sources */, 94A886BB2A714F6D0098530D /* BTFuseSchemeHandler.m in Sources */, + 94F13A1D2CA4EF1800CCCC89 /* BTFuse.docc in Sources */, 9418629D2A9956F100CCFEE1 /* BTFuseAPIRouter.m in Sources */, 9489EB9A2AA54FED0087424D /* BTFuseRuntime.m in Sources */, 94A928572B1A729000AAC44A /* BTFuseIDGenerator.m in Sources */, @@ -728,6 +735,7 @@ isa = XCBuildConfiguration; baseConfigurationReference = D2524D348AB6B72B049BC41D /* Pods-BTFuse.debug.xcconfig */; buildSettings = { + CLANG_ENABLE_MODULES = YES; CODE_SIGN_IDENTITY = ""; CODE_SIGN_STYLE = Automatic; DEFINES_MODULE = YES; @@ -757,6 +765,8 @@ SUPPORTS_MAC_DESIGNED_FOR_IPHONE_IPAD = NO; SUPPORTS_XR_DESIGNED_FOR_IPHONE_IPAD = NO; SWIFT_EMIT_LOC_STRINGS = YES; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 6.0; TARGETED_DEVICE_FAMILY = 1; }; name = Debug; @@ -765,6 +775,7 @@ isa = XCBuildConfiguration; baseConfigurationReference = 94552C5C2ACB3A5600DAE0F4 /* BTFuse.release.xcconfig */; buildSettings = { + CLANG_ENABLE_MODULES = YES; CODE_SIGN_IDENTITY = ""; CODE_SIGN_STYLE = Automatic; DEFINES_MODULE = YES; @@ -794,6 +805,7 @@ SUPPORTS_MAC_DESIGNED_FOR_IPHONE_IPAD = NO; SUPPORTS_XR_DESIGNED_FOR_IPHONE_IPAD = NO; SWIFT_EMIT_LOC_STRINGS = YES; + SWIFT_VERSION = 6.0; TARGETED_DEVICE_FAMILY = 1; }; name = Release; diff --git a/BTFuse/BTFuseTestTools/BTFuseTestTools.docc/BTFuseTestTools.md b/BTFuse/BTFuseTestTools/BTFuseTestTools.docc/BTFuseTestTools.md new file mode 100644 index 0000000..c854132 --- /dev/null +++ b/BTFuse/BTFuseTestTools/BTFuseTestTools.docc/BTFuseTestTools.md @@ -0,0 +1,13 @@ +# ``BTFuseTestTools`` + +Summary + +## Overview + +Text + +## Topics + +### Group + +- ``Symbol`` \ No newline at end of file diff --git a/BTFuse/BTFuseTestTools/BTFuseTestTools.xcodeproj/project.pbxproj b/BTFuse/BTFuseTestTools/BTFuseTestTools.xcodeproj/project.pbxproj index 3a3b230..2d123dc 100644 --- a/BTFuse/BTFuseTestTools/BTFuseTestTools.xcodeproj/project.pbxproj +++ b/BTFuse/BTFuseTestTools/BTFuseTestTools.xcodeproj/project.pbxproj @@ -20,6 +20,7 @@ 94C3AF2B2B68681A006AD040 /* LICENSE in Resources */ = {isa = PBXBuildFile; fileRef = 94C3AF2A2B68681A006AD040 /* LICENSE */; }; 94D499BB2AC9CFEE009917A7 /* BTFuseTestAPIClient.h in Headers */ = {isa = PBXBuildFile; fileRef = 94D499BA2AC9CFEE009917A7 /* BTFuseTestAPIClient.h */; settings = {ATTRIBUTES = (Public, ); }; }; 94D499BD2AC9D254009917A7 /* BTFuseTestAPIClient.m in Sources */ = {isa = PBXBuildFile; fileRef = 94D499BC2AC9D254009917A7 /* BTFuseTestAPIClient.m */; }; + 94F13A1F2CA4EF2C00CCCC89 /* BTFuseTestTools.docc in Sources */ = {isa = PBXBuildFile; fileRef = 94F13A1E2CA4EF2C00CCCC89 /* BTFuseTestTools.docc */; }; /* End PBXBuildFile section */ /* Begin PBXFileReference section */ @@ -38,6 +39,7 @@ 94C3AF2A2B68681A006AD040 /* LICENSE */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = LICENSE; path = ../../LICENSE; sourceTree = ""; }; 94D499BA2AC9CFEE009917A7 /* BTFuseTestAPIClient.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = BTFuseTestAPIClient.h; sourceTree = ""; }; 94D499BC2AC9D254009917A7 /* BTFuseTestAPIClient.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = BTFuseTestAPIClient.m; sourceTree = ""; }; + 94F13A1E2CA4EF2C00CCCC89 /* BTFuseTestTools.docc */ = {isa = PBXFileReference; lastKnownFileType = folder.documentationcatalog; path = BTFuseTestTools.docc; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -78,6 +80,7 @@ 947FF0FB2AC8A82E003D09BC = { isa = PBXGroup; children = ( + 94F13A1E2CA4EF2C00CCCC89 /* BTFuseTestTools.docc */, 94C3AF2A2B68681A006AD040 /* LICENSE */, 944112BB2AED44C800309527 /* PrivacyInfo.xcprivacy */, 947FF1072AC8A82E003D09BC /* BTFuseTestTools */, @@ -203,6 +206,7 @@ 946278462AC8A987008A89FA /* BTFuseTestViewController.m in Sources */, 9462784E2AC8B1AF008A89FA /* BTFuseTestAPIResponse.m in Sources */, 946278522AC8B3EE008A89FA /* BTFuseTestAPIResponseFactory.m in Sources */, + 94F13A1F2CA4EF2C00CCCC89 /* BTFuseTestTools.docc in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; diff --git a/BTFuse/src/BTFuseContext.m b/BTFuse/src/BTFuseContext.m index 89f04e6..5247001 100644 --- a/BTFuse/src/BTFuseContext.m +++ b/BTFuse/src/BTFuseContext.m @@ -28,6 +28,9 @@ #import #import "BTFuseWebviewNavigationDelegate.h" +/** + BTFuseContext is the main context file representing the runtime environment. + */ @implementation BTFuseContext { NSMutableDictionary* $pluginMap; BTFuseAPIRouter* $apiRouter; diff --git a/Overview.docc/Overview.md b/Overview.docc/Overview.md new file mode 100644 index 0000000..e9ab83a --- /dev/null +++ b/Overview.docc/Overview.md @@ -0,0 +1,20 @@ + +# BTFuse + +@Metadata { + @TitleHeading("Title Heading") + @TechnologyRoot +} + + +This is a summary + +## Overview + +This is some text + +## Topics + +### GroupName + +Landing diff --git a/build.sh b/build.sh index 2fd4f95..6b661cd 100755 --- a/build.sh +++ b/build.sh @@ -69,11 +69,27 @@ assertLastCall xcodebuild -quiet -workspace BTFuse.xcworkspace -scheme BTFuseTestTools -configuration Debug -destination "generic/platform=iOS Simulator" build assertLastCall +echo "Building Documentation..." +xcodebuild -quiet -workspace BTFuse.xcworkspace -scheme BTFuse -configuration Release -destination 'generic/platform=iOS' docbuild +xcodebuild -quiet -workspace BTFuse.xcworkspace -scheme BTFuseTestTools -configuration Release -destination 'generic/platform=iOS' docbuild + iosBuild=$(echo "$(xcodebuild -workspace BTFuse.xcworkspace -scheme BTFuse -configuration Release -sdk iphoneos -showBuildSettings | grep -E '^\s*CONFIGURATION_BUILD_DIR =' | awk -F '= ' '{print $2}' | xargs)") simBuild=$(echo "$(xcodebuild -workspace BTFuse.xcworkspace -scheme BTFuse -configuration Debug -sdk iphonesimulator -showBuildSettings | grep -E '^\s*CONFIGURATION_BUILD_DIR =' | awk -F '= ' '{print $2}' | xargs)") iosTestToolsBuild=$(echo "$(xcodebuild -workspace BTFuse.xcworkspace -scheme BTFuseTestTools -configuration Release -sdk iphoneos -showBuildSettings | grep -E '^\s*CONFIGURATION_BUILD_DIR =' | awk -F '= ' '{print $2}' | xargs)") simTestToolsBuild=$(echo "$(xcodebuild -workspace BTFuse.xcworkspace -scheme BTFuseTestTools -configuration Debug -sdk iphonesimulator -showBuildSettings | grep -E '^\s*CONFIGURATION_BUILD_DIR =' | awk -F '= ' '{print $2}' | xargs)") +mkdir -p dist/docs/intermediates +mkdir -p dist/docs/out +xcrun docc convert ./Overview.docc --fallback-display-name BTFuse --output-dir dist/docs/intermediates/Overview.doccarchive +xcrun docc merge ./dist/docs/intermediates/Overview.doccarchive $iosBuild/BTFuse.doccarchive $iosBuild/BTFuseTestTools.doccarchive --output-path dist/docs/out/ + +# intermediatesDir=$iosBuild/../../Intermediates.noindex/ +# mkdir -p dist/docs/intermediates/ +# cp -r $intermediatesDir/BTFuse.build/Release-iphoneos/BTFuse.build/symbol-graph dist/docs/intermediates +# cp -r $intermediatesDir/BTFuseTestTools.build/Release-iphoneos/BTFuseTestTools.build/symbol-graph dist/docs/intermediates + +# xcrun docc convert --output-dir dist/docs/doc.doccarchive --additional-symbol-graph-dir dist/docs/intermediates/x + if [ "$CI" == "true" ]; then echo "Skipping CodeSign (CI Build)" else @@ -112,6 +128,7 @@ spushd dist zip -r BTFuse.framework.dSYM.zip BTFuse.framework.dSYM > /dev/null zip -r BTFuseTestTools.xcframework.zip BTFuseTestTools.xcframework > /dev/null zip -r BTFuseTestTools.framework.dSYM.zip BTFuseTestTools.framework.dSYM > /dev/null + # tar -czvf dist/docs.tar.gz -C dist/docs . sha1_compute BTFuse.xcframework.zip sha1_compute BTFuse.framework.dSYM.zip sha1_compute BTFuseTestTools.xcframework.zip