代码拉取完成,页面将自动刷新
diff --git a/git_json.sh b/git_json.sh
--- a/git_json.sh
+++ b/git_json.sh
2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 12) # git log --pretty=oneline >filename.log
2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 13) # git log --pretty=format:"%h%x09%an%x09%ad%x09%s"
2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 14)
[31m - 2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 15) -# git log \
[m[31m - 2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 16) -# --pretty=format:'{%n "commit": "%H",%n "author": "%an <%ae>",%n "date": "%ad",%n "message": "%f"%n},' \
[m[31m - 2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 17) -# $@ | \
[m[31m - 2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 18) -# perl -pe 'BEGIN{print "["}; END{print "]\n"}' | \
[m[31m - 2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 19) -# perl -pe 's/},]/}]/' >> test.json
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 15) +git log \
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 16) +--pretty=format:'{%n "commit": "%H",%n "author": "%an <%ae>",%n "date": "%ad",%n "message": "%f"%n},' \
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 17) +$@ | \
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 18) +perl -pe 'BEGIN{print "["}; END{print "]\n"}' | \
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 19) +perl -pe 's/},]/}]/' >> commitList.json
[m 2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 20)
[31m - 2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 21) -# git log $(git describe --tags --abbrev=0)..HEAD --no-merges --oneline > new-in-this-release.log
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 21) +#git log $(git describe --tags --abbrev=0)..HEAD --no-merges --oneline > new-in-this-release.log
[m 2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 22)
[31m - 2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 23) -target_Path="http://app1.nowcoder.com:8000/Users/nowcoder_mobile/Downloads/"
[m[31m - 2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 24) -
[m[31m - 2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 25) -
[m[31m - 2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 26) -curl -F upload=$target_Path
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 23) +# target_Path="http://app1.nowcoder.com:8000/Users/nowcoder_mobile/Downloads/"
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 24) +# curl -F upload=$target_Path
[mdiff --git a/templateApp/Pods/Pods.xcodeproj/project.pbxproj b/templateApp/Pods/Pods.xcodeproj/project.pbxproj
--- a/templateApp/Pods/Pods.xcodeproj/project.pbxproj
+++ b/templateApp/Pods/Pods.xcodeproj/project.pbxproj
a26d549c (Kael 2022-03-19 23:55:24 +0800 1938) BFDFE7DC352907FC980B868725387E98 /* Project object */ = {
3aad7b15 (作颂 2018-11-01 18:56:08 +0800 1939) isa = PBXProject;
3aad7b15 (作颂 2018-11-01 18:56:08 +0800 1940) attributes = {
[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 1941) - LastSwiftUpdateCheck = 1240;
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 1942) - LastUpgradeCheck = 1240;
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 1941) + LastSwiftUpdateCheck = 1300;
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 1942) + LastUpgradeCheck = 1300;
[m 3aad7b15 (作颂 2018-11-01 18:56:08 +0800 1943) };
a26d549c (Kael 2022-03-19 23:55:24 +0800 1944) buildConfigurationList = 4821239608C13582E20E6DA73FD5F1F9 /* Build configuration list for PBXProject "Pods" */;
a26d549c (Kael 2022-03-19 23:55:24 +0800 1945) compatibilityVersion = "Xcode 10.0";
diff --git a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Alamofire.xcscheme b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Alamofire.xcscheme
--- a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Alamofire.xcscheme
+++ b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Alamofire.xcscheme
a26d549c (Kael 2022-03-19 23:55:24 +0800 1) <?xml version="1.0" encoding="UTF-8"?>
a26d549c (Kael 2022-03-19 23:55:24 +0800 2) <Scheme
[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 3) - LastUpgradeVersion = "1240"
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 3) + LastUpgradeVersion = "1300"
[m a26d549c (Kael 2022-03-19 23:55:24 +0800 4) version = "1.3">
a26d549c (Kael 2022-03-19 23:55:24 +0800 5) <BuildAction
a26d549c (Kael 2022-03-19 23:55:24 +0800 6) parallelizeBuildables = "YES"
diff --git a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Coverage.xcscheme b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Coverage.xcscheme
--- a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Coverage.xcscheme
+++ b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Coverage.xcscheme
994a10be (Kael 2022-09-06 23:45:31 +0800 1) <?xml version="1.0" encoding="UTF-8"?>
994a10be (Kael 2022-09-06 23:45:31 +0800 2) <Scheme
[31m - 994a10be (Kael 2022-09-06 23:45:31 +0800 3) - LastUpgradeVersion = "1240"
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 3) + LastUpgradeVersion = "1300"
[m 994a10be (Kael 2022-09-06 23:45:31 +0800 4) version = "1.3">
994a10be (Kael 2022-09-06 23:45:31 +0800 5) <BuildAction
994a10be (Kael 2022-09-06 23:45:31 +0800 6) parallelizeBuildables = "YES"
diff --git a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/HDCoverage.xcscheme b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/HDCoverage.xcscheme
--- a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/HDCoverage.xcscheme
+++ b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/HDCoverage.xcscheme
a26d549c (Kael 2022-03-19 23:55:24 +0800 1) <?xml version="1.0" encoding="UTF-8"?>
a26d549c (Kael 2022-03-19 23:55:24 +0800 2) <Scheme
[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 3) - LastUpgradeVersion = "1240"
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 3) + LastUpgradeVersion = "1300"
[m a26d549c (Kael 2022-03-19 23:55:24 +0800 4) version = "1.3">
a26d549c (Kael 2022-03-19 23:55:24 +0800 5) <BuildAction
a26d549c (Kael 2022-03-19 23:55:24 +0800 6) parallelizeBuildables = "YES"
diff --git a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Pods-templateApp.xcscheme b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Pods-templateApp.xcscheme
--- a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Pods-templateApp.xcscheme
+++ b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Pods-templateApp.xcscheme
a26d549c (Kael 2022-03-19 23:55:24 +0800 1) <?xml version="1.0" encoding="UTF-8"?>
a26d549c (Kael 2022-03-19 23:55:24 +0800 2) <Scheme
[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 3) - LastUpgradeVersion = "1240"
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 3) + LastUpgradeVersion = "1300"
[m a26d549c (Kael 2022-03-19 23:55:24 +0800 4) version = "1.3">
a26d549c (Kael 2022-03-19 23:55:24 +0800 5) <BuildAction
a26d549c (Kael 2022-03-19 23:55:24 +0800 6) parallelizeBuildables = "YES"
diff --git a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Pods-templateAppTests.xcscheme b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Pods-templateAppTests.xcscheme
--- a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Pods-templateAppTests.xcscheme
+++ b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Pods-templateAppTests.xcscheme
a26d549c (Kael 2022-03-19 23:55:24 +0800 1) <?xml version="1.0" encoding="UTF-8"?>
a26d549c (Kael 2022-03-19 23:55:24 +0800 2) <Scheme
[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 3) - LastUpgradeVersion = "1240"
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 3) + LastUpgradeVersion = "1300"
[m a26d549c (Kael 2022-03-19 23:55:24 +0800 4) version = "1.3">
a26d549c (Kael 2022-03-19 23:55:24 +0800 5) <BuildAction
a26d549c (Kael 2022-03-19 23:55:24 +0800 6) parallelizeBuildables = "YES"
diff --git a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Pods-templateAppUITests.xcscheme b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Pods-templateAppUITests.xcscheme
--- a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Pods-templateAppUITests.xcscheme
+++ b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Pods-templateAppUITests.xcscheme
a26d549c (Kael 2022-03-19 23:55:24 +0800 1) <?xml version="1.0" encoding="UTF-8"?>
a26d549c (Kael 2022-03-19 23:55:24 +0800 2) <Scheme
[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 3) - LastUpgradeVersion = "1240"
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 3) + LastUpgradeVersion = "1300"
[m a26d549c (Kael 2022-03-19 23:55:24 +0800 4) version = "1.3">
a26d549c (Kael 2022-03-19 23:55:24 +0800 5) <BuildAction
a26d549c (Kael 2022-03-19 23:55:24 +0800 6) parallelizeBuildables = "YES"
diff --git a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/RxSwift.xcscheme b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/RxSwift.xcscheme
--- a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/RxSwift.xcscheme
+++ b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/RxSwift.xcscheme
a26d549c (Kael 2022-03-19 23:55:24 +0800 1) <?xml version="1.0" encoding="UTF-8"?>
a26d549c (Kael 2022-03-19 23:55:24 +0800 2) <Scheme
[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 3) - LastUpgradeVersion = "1240"
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 3) + LastUpgradeVersion = "1300"
[m a26d549c (Kael 2022-03-19 23:55:24 +0800 4) version = "1.3">
a26d549c (Kael 2022-03-19 23:55:24 +0800 5) <BuildAction
a26d549c (Kael 2022-03-19 23:55:24 +0800 6) parallelizeBuildables = "YES"
diff --git a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/SnapKit.xcscheme b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/SnapKit.xcscheme
--- a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/SnapKit.xcscheme
+++ b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/SnapKit.xcscheme
a26d549c (Kael 2022-03-19 23:55:24 +0800 1) <?xml version="1.0" encoding="UTF-8"?>
a26d549c (Kael 2022-03-19 23:55:24 +0800 2) <Scheme
[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 3) - LastUpgradeVersion = "1240"
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 3) + LastUpgradeVersion = "1300"
[m a26d549c (Kael 2022-03-19 23:55:24 +0800 4) version = "1.3">
a26d549c (Kael 2022-03-19 23:55:24 +0800 5) <BuildAction
a26d549c (Kael 2022-03-19 23:55:24 +0800 6) parallelizeBuildables = "YES"
diff --git a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Sourcery.xcscheme b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Sourcery.xcscheme
--- a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Sourcery.xcscheme
+++ b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/Sourcery.xcscheme
5960fe12 (Kael 2022-06-21 18:04:32 +0800 1) <?xml version="1.0" encoding="UTF-8"?>
5960fe12 (Kael 2022-06-21 18:04:32 +0800 2) <Scheme
[31m - 5960fe12 (Kael 2022-06-21 18:04:32 +0800 3) - LastUpgradeVersion = "1240"
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 3) + LastUpgradeVersion = "1300"
[m 5960fe12 (Kael 2022-06-21 18:04:32 +0800 4) version = "1.3">
5960fe12 (Kael 2022-06-21 18:04:32 +0800 5) <BuildAction
5960fe12 (Kael 2022-06-21 18:04:32 +0800 6) parallelizeBuildables = "YES"
diff --git a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/SwiftyJSON.xcscheme b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/SwiftyJSON.xcscheme
--- a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/SwiftyJSON.xcscheme
+++ b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/SwiftyJSON.xcscheme
a26d549c (Kael 2022-03-19 23:55:24 +0800 1) <?xml version="1.0" encoding="UTF-8"?>
a26d549c (Kael 2022-03-19 23:55:24 +0800 2) <Scheme
[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 3) - LastUpgradeVersion = "1240"
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 3) + LastUpgradeVersion = "1300"
[m a26d549c (Kael 2022-03-19 23:55:24 +0800 4) version = "1.3">
a26d549c (Kael 2022-03-19 23:55:24 +0800 5) <BuildAction
a26d549c (Kael 2022-03-19 23:55:24 +0800 6) parallelizeBuildables = "YES"
diff --git a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/lottie-ios.xcscheme b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/lottie-ios.xcscheme
--- a/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/lottie-ios.xcscheme
+++ b/templateApp/Pods/Pods.xcodeproj/xcuserdata/nowcoder.xcuserdatad/xcschemes/lottie-ios.xcscheme
a26d549c (Kael 2022-03-19 23:55:24 +0800 1) <?xml version="1.0" encoding="UTF-8"?>
a26d549c (Kael 2022-03-19 23:55:24 +0800 2) <Scheme
[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 3) - LastUpgradeVersion = "1240"
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 3) + LastUpgradeVersion = "1300"
[m a26d549c (Kael 2022-03-19 23:55:24 +0800 4) version = "1.3">
a26d549c (Kael 2022-03-19 23:55:24 +0800 5) <BuildAction
a26d549c (Kael 2022-03-19 23:55:24 +0800 6) parallelizeBuildables = "YES"
diff --git a/templateApp/templateApp.xcodeproj/project.pbxproj b/templateApp/templateApp.xcodeproj/project.pbxproj
--- a/templateApp/templateApp.xcodeproj/project.pbxproj
+++ b/templateApp/templateApp.xcodeproj/project.pbxproj
be847396 (Kael 2022-04-21 00:13:09 +0800 57) FAB1A348280FEA6B0065019F /* BaseListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = FAB1A347280FEA6B0065019F /* BaseListViewController.swift */; };
be847396 (Kael 2022-04-21 00:13:09 +0800 58) FAB1A34C28105F010065019F /* ListConfig.swift in Sources */ = {isa = PBXBuildFile; fileRef = FAB1A34B28105F010065019F /* ListConfig.swift */; };
be847396 (Kael 2022-04-21 00:13:09 +0800 59) FAB1A34E2810671B0065019F /* TestListVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = FAB1A34D2810671B0065019F /* TestListVC.swift */; };
[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 60) + FAB73E9E28F1E1E300E96BE9 /* LARightStoreVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = FAB73E9D28F1E1E300E96BE9 /* LARightStoreVC.swift */; };
[m 2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 60) FABBA9792861E1AF00535C00 /* NCMiniWindowPlayer.swift in Sources */ = {isa = PBXBuildFile; fileRef = FABBA9782861E1AF00535C00 /* NCMiniWindowPlayer.swift */; };
2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 61) FABBA97B2861E63B00535C00 /* NCMiniPlayerFloatingView.swift in Sources */ = {isa = PBXBuildFile; fileRef = FABBA97A2861E63B00535C00 /* NCMiniPlayerFloatingView.swift */; };
2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 62) FABBA98128636F3F00535C00 /* NCMiniPlayerFloatingViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = FABBA98028636F3F00535C00 /* NCMiniPlayerFloatingViewController.swift */; };
be847396 (Kael 2022-04-21 00:13:09 +0800 155) FAB1A347280FEA6B0065019F /* BaseListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BaseListViewController.swift; sourceTree = "<group>"; };
be847396 (Kael 2022-04-21 00:13:09 +0800 156) FAB1A34B28105F010065019F /* ListConfig.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ListConfig.swift; sourceTree = "<group>"; };
be847396 (Kael 2022-04-21 00:13:09 +0800 157) FAB1A34D2810671B0065019F /* TestListVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TestListVC.swift; sourceTree = "<group>"; };
[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 159) + FAB73E9D28F1E1E300E96BE9 /* LARightStoreVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LARightStoreVC.swift; sourceTree = "<group>"; };
[m 2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 158) FABBA9782861E1AF00535C00 /* NCMiniWindowPlayer.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NCMiniWindowPlayer.swift; sourceTree = "<group>"; };
2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 159) FABBA97A2861E63B00535C00 /* NCMiniPlayerFloatingView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NCMiniPlayerFloatingView.swift; sourceTree = "<group>"; };
2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 160) FABBA98028636F3F00535C00 /* NCMiniPlayerFloatingViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NCMiniPlayerFloatingViewController.swift; sourceTree = "<group>"; };
febf9a0c (Kael 2022-09-27 16:53:13 +0800 416) FA764EF528E09F010060284A /* EditMenuInteractionViewController.swift */,
febf9a0c (Kael 2022-09-27 16:53:13 +0800 417) FA764EF728E0A6680060284A /* UIFindInteractionVC.swift */,
febf9a0c (Kael 2022-09-27 16:53:13 +0800 418) FA764EF928E0A9770060284A /* FontViewController.swift */,
[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 421) + FAB73E9D28F1E1E300E96BE9 /* LARightStoreVC.swift */,
[m febf9a0c (Kael 2022-09-27 16:53:13 +0800 419) );
febf9a0c (Kael 2022-09-27 16:53:13 +0800 420) path = iOS16;
febf9a0c (Kael 2022-09-27 16:53:13 +0800 421) sourceTree = "<group>";
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 527) buildConfigurationList = 7F05BFF6217979A2002BC7FB /* Build configuration list for PBXNativeTarget "templateApp" */;
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 528) buildPhases = (
3aad7b15 (作颂 2018-11-01 18:56:08 +0800 529) FE4D8A1FCF412EFB242AAF63 /* [CP] Check Pods Manifest.lock */,
[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 533) + FA334C3028E430DA00F5CDEA /* Branch Check */,
[m 7acf35d3 (作颂 2018-10-19 18:21:07 +0800 530) 7F05BFCA217979A0002BC7FB /* Sources */,
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 531) 7F05BFCB217979A0002BC7FB /* Frameworks */,
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 532) 7F05BFCC217979A0002BC7FB /* Resources */,
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 588) isa = PBXProject;
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 589) attributes = {
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 590) LastSwiftUpdateCheck = 1000;
[31m - 7acf35d3 (作颂 2018-10-19 18:21:07 +0800 591) - LastUpgradeCheck = 1000;
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 595) + LastUpgradeCheck = 1320;
[m 5960fe12 (Kael 2022-06-21 18:04:32 +0800 592) ORGANIZATIONNAME = NowCoder;
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 593) TargetAttributes = {
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 594) 7F05BFCD217979A0002BC7FB = {
3aad7b15 (作颂 2018-11-01 18:56:08 +0800 707) 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";
3aad7b15 (作颂 2018-11-01 18:56:08 +0800 708) showEnvVarsInLog = 0;
3aad7b15 (作颂 2018-11-01 18:56:08 +0800 709) };
[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 714) + FA334C3028E430DA00F5CDEA /* Branch Check */ = {
[m[32m + 3aad7b15 (作颂 2018-11-01 18:56:08 +0800 715) + isa = PBXShellScriptBuildPhase;
[m[32m + 7acf35d3 (作颂 2018-10-19 18:21:07 +0800 716) + buildActionMask = 2147483647;
[m[32m + 7acf35d3 (作颂 2018-10-19 18:21:07 +0800 717) + files = (
[m[32m + 7acf35d3 (作颂 2018-10-19 18:21:07 +0800 718) + );
[m[32m + a26d549c (Kael 2022-03-19 23:55:24 +0800 719) + inputFileListPaths = (
[m[32m + a26d549c (Kael 2022-03-19 23:55:24 +0800 720) + );
[m[32m + a26d549c (Kael 2022-03-19 23:55:24 +0800 721) + inputPaths = (
[m[32m + a26d549c (Kael 2022-03-19 23:55:24 +0800 722) + );
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 723) + name = "Branch Check";
[m[32m + a26d549c (Kael 2022-03-19 23:55:24 +0800 724) + outputFileListPaths = (
[m[32m + a26d549c (Kael 2022-03-19 23:55:24 +0800 725) + );
[m[32m + a26d549c (Kael 2022-03-19 23:55:24 +0800 726) + outputPaths = (
[m[32m + 7acf35d3 (作颂 2018-10-19 18:21:07 +0800 727) + );
[m[32m + 7acf35d3 (作颂 2018-10-19 18:21:07 +0800 728) + runOnlyForDeploymentPostprocessing = 0;
[m[32m + 3aad7b15 (作颂 2018-11-01 18:56:08 +0800 729) + shellPath = /bin/sh;
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 730) + shellScript = "# Type a script or drag a script file from your workspace to insert its path.\n\n";
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 731) + };
[m a26d549c (Kael 2022-03-19 23:55:24 +0800 710) FAA8FFDB27E4B74A00DFF465 /* ShellScript */ = {
3aad7b15 (作颂 2018-11-01 18:56:08 +0800 711) isa = PBXShellScriptBuildPhase;
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 712) buildActionMask = 2147483647;
2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 803) FA9565F628675AC40078A172 /* VCJumpModule.swift in Sources */,
a26d549c (Kael 2022-03-19 23:55:24 +0800 804) FAA8002627E4E70900DFF465 /* module.modulemap in Sources */,
5960fe12 (Kael 2022-06-21 18:04:32 +0800 805) FA272B452843C6E9008A22D4 /* GuideVC.swift in Sources */,
[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 828) + FAB73E9E28F1E1E300E96BE9 /* LARightStoreVC.swift in Sources */,
[m 7acf35d3 (作颂 2018-10-19 18:21:07 +0800 806) 7F05BFD2217979A0002BC7FB /* AppDelegate.swift in Sources */,
2d68c3d7 (Kael 2022-08-15 15:47:05 +0800 807) FAC10949287DE593006020D0 /* TouchCell.swift in Sources */,
a56b7e1c (作颂 2018-10-30 18:59:25 +0800 808) 7FC2D1F621882E5A006AD4B5 /* Gossip.swift in Sources */,
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 900) CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 901) CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 902) CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 926) + CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
[m 7acf35d3 (作颂 2018-10-19 18:21:07 +0800 903) CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 904) CLANG_WARN_STRICT_PROTOTYPES = YES;
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 905) CLANG_WARN_SUSPICIOUS_MOVE = YES;
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 961) CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 962) CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 963) CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 988) + CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
[m 7acf35d3 (作颂 2018-10-19 18:21:07 +0800 964) CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 965) CLANG_WARN_STRICT_PROTOTYPES = YES;
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 966) CLANG_WARN_SUSPICIOUS_MOVE = YES;
a26d549c (Kael 2022-03-19 23:55:24 +0800 1003) "CODECOVERAGE=1",
a26d549c (Kael 2022-03-19 23:55:24 +0800 1004) );
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 1005) INFOPLIST_FILE = templateApp/Info.plist;
[31m - 7acf35d3 (作颂 2018-10-19 18:21:07 +0800 1006) - IPHONEOS_DEPLOYMENT_TARGET = 10.0;
[m[32m + 7acf35d3 (作颂 2018-10-19 18:21:07 +0800 1031) + IPHONEOS_DEPLOYMENT_TARGET = 12.0;
[m 7acf35d3 (作颂 2018-10-19 18:21:07 +0800 1007) LD_RUNPATH_SEARCH_PATHS = (
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 1008) "$(inherited)",
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 1009) "@executable_path/Frameworks",
a26d549c (Kael 2022-03-19 23:55:24 +0800 1042) "CODECOVERAGE=1",
a26d549c (Kael 2022-03-19 23:55:24 +0800 1043) );
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 1044) INFOPLIST_FILE = templateApp/Info.plist;
[31m - 7acf35d3 (作颂 2018-10-19 18:21:07 +0800 1045) - IPHONEOS_DEPLOYMENT_TARGET = 10.0;
[m[32m + 7acf35d3 (作颂 2018-10-19 18:21:07 +0800 1070) + IPHONEOS_DEPLOYMENT_TARGET = 12.0;
[m 7acf35d3 (作颂 2018-10-19 18:21:07 +0800 1046) LD_RUNPATH_SEARCH_PATHS = (
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 1047) "$(inherited)",
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 1048) "@executable_path/Frameworks",
diff --git a/templateApp/templateApp.xcworkspace/xcuserdata/nowcoder.xcuserdatad/UserInterfaceState.xcuserstate b/templateApp/templateApp.xcworkspace/xcuserdata/nowcoder.xcuserdatad/UserInterfaceState.xcuserstate
diff --git a/templateApp/templateApp.xcworkspace/xcuserdata/nowcoder.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist b/templateApp/templateApp.xcworkspace/xcuserdata/nowcoder.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist
--- a/templateApp/templateApp.xcworkspace/xcuserdata/nowcoder.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist
+++ b/templateApp/templateApp.xcworkspace/xcuserdata/nowcoder.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist
a26d549c (Kael 2022-03-19 23:55:24 +0800 23) <BreakpointProxy
a26d549c (Kael 2022-03-19 23:55:24 +0800 24) BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
a26d549c (Kael 2022-03-19 23:55:24 +0800 25) <BreakpointContent
[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 26) - uuid = "4106E7C3-A42D-4234-9672-B20B9FF432D7"
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 26) + uuid = "D4E5A231-CCA1-4B53-8326-85ED18229DA1"
[m a26d549c (Kael 2022-03-19 23:55:24 +0800 27) shouldBeEnabled = "Yes"
a26d549c (Kael 2022-03-19 23:55:24 +0800 28) ignoreCount = "0"
a26d549c (Kael 2022-03-19 23:55:24 +0800 29) continueAfterRunningActions = "No"
febf9a0c (Kael 2022-09-27 16:53:13 +0800 30) filePath = "templateApp/mouldles/iOS16/SystemNewFunctionModule.swift"
a26d549c (Kael 2022-03-19 23:55:24 +0800 31) startingColumnNumber = "9223372036854775807"
a26d549c (Kael 2022-03-19 23:55:24 +0800 32) endingColumnNumber = "9223372036854775807"
[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 33) - startingLineNumber = "145"
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 34) - endingLineNumber = "145"
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 35) - landmarkName = "testUISheetPresentationController()"
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 36) - landmarkType = "7">
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 37) - </BreakpointContent>
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 38) - </BreakpointProxy>
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 39) - <BreakpointProxy
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 40) - BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 41) - <BreakpointContent
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 42) - uuid = "42FFD1BA-56FF-4696-95E2-88BA5F652A16"
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 43) - shouldBeEnabled = "Yes"
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 44) - ignoreCount = "0"
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 45) - continueAfterRunningActions = "No"
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 46) - filePath = "templateApp/mouldles/iOS16/SystemNewFunctionModule.swift"
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 47) - startingColumnNumber = "9223372036854775807"
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 48) - endingColumnNumber = "9223372036854775807"
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 49) - startingLineNumber = "138"
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 50) - endingLineNumber = "138"
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 51) - landmarkName = "testUISheetPresentationController()"
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 52) - landmarkType = "7">
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 53) - </BreakpointContent>
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 54) - </BreakpointProxy>
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 55) - <BreakpointProxy
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 56) - BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 57) - <BreakpointContent
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 58) - uuid = "CC71EF5C-F5B6-43DE-944A-448314FC8051"
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 59) - shouldBeEnabled = "No"
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 60) - ignoreCount = "0"
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 61) - continueAfterRunningActions = "No"
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 62) - filePath = "templateApp/mouldles/iOS16/SystemNewFunctionModule.swift"
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 63) - startingColumnNumber = "9223372036854775807"
[m[31m - a26d549c (Kael 2022-03-19 23:55:24 +0800 64) - endingColumnNumber = "9223372036854775807"
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 65) - startingLineNumber = "214"
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 66) - endingLineNumber = "214"
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 67) - landmarkName = "testDeviceInfo()"
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 33) + startingLineNumber = "57"
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 34) + endingLineNumber = "57"
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 35) + landmarkName = "configPageData()"
[m a26d549c (Kael 2022-03-19 23:55:24 +0800 68) landmarkType = "7">
a26d549c (Kael 2022-03-19 23:55:24 +0800 69) </BreakpointContent>
a26d549c (Kael 2022-03-19 23:55:24 +0800 70) </BreakpointProxy>
diff --git a/templateApp/templateApp/Info.plist b/templateApp/templateApp/Info.plist
--- a/templateApp/templateApp/Info.plist
+++ b/templateApp/templateApp/Info.plist
6f7f06a8 (Kael 2022-03-24 23:50:24 +0800 52) <key>NSAllowsArbitraryLoads</key>
6f7f06a8 (Kael 2022-03-24 23:50:24 +0800 53) <true/>
6f7f06a8 (Kael 2022-03-24 23:50:24 +0800 54) </dict>
[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 55) + <key>NSFaceIDUsageDescription</key>
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 56) + <string>获取FaceID描述</string>
[m 7acf35d3 (作颂 2018-10-19 18:21:07 +0800 55) <key>UILaunchStoryboardName</key>
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 56) <string>LaunchScreen</string>
7acf35d3 (作颂 2018-10-19 18:21:07 +0800 57) <key>UIMainStoryboardFile</key>
diff --git a/templateApp/templateApp/mouldles/iOS16/DeviceViewController.swift b/templateApp/templateApp/mouldles/iOS16/DeviceViewController.swift
--- a/templateApp/templateApp/mouldles/iOS16/DeviceViewController.swift
+++ b/templateApp/templateApp/mouldles/iOS16/DeviceViewController.swift
febf9a0c (Kael 2022-09-27 16:53:13 +0800 13) override func configPageData() {
febf9a0c (Kael 2022-09-27 16:53:13 +0800 14) title = "UIDevice 新特性"
febf9a0c (Kael 2022-09-27 16:53:13 +0800 15)
[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 16) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 17) +
[m febf9a0c (Kael 2022-09-27 16:53:13 +0800 16) }
febf9a0c (Kael 2022-09-27 16:53:13 +0800 17) }
diff --git a/templateApp/templateApp/mouldles/iOS16/LARightStoreVC.swift b/templateApp/templateApp/mouldles/iOS16/LARightStoreVC.swift
--- /dev/null
+++ b/templateApp/templateApp/mouldles/iOS16/LARightStoreVC.swift
[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 1) +//
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 2) +// LARightStoreVC.swift
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 3) +// templateApp
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 4) +//
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 5) +// Created by nowcoder on 2022/10/9.
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 6) +// Copyright © 2022 NowCoder. All rights reserved.
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 7) +//
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 8) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 9) +import Foundation
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 10) +import UIKit
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 11) +import LocalAuthentication
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 12) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 13) +class LARightStoreVC: BaseListViewController {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 14) + override func viewDidLoad() {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 15) + super.viewDidLoad()
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 16) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 17) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 18) + override func viewDidAppear(_ animated: Bool) {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 19) + super.viewDidAppear(animated)
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 20) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 21) + // 存储
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 22) + if #available(iOS 16.0, *) {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 23) + Task {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 24) + let carID = "6270123456789000"
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 25) + let data = carID.data(using: .utf8)
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 26) + if let data {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 27) + try await storeData(data)
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 28) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 29) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 30) + } else {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 31) + // Fallback on earlier versions
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 32) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 33) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 34) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 35) + override func touchesBegan(_ touches: Set<UITouch>, with event: UIEvent?) {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 36) + // 获取
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 37) + if #available(iOS 16.0, *) {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 38) + Task {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 39) + let data = try await fetchData()
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 40) + print(String(decoding: data, as: UTF8.self))
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 41) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 42) + } else {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 43) + // Fallback on earlier versions
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 44) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 45) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 46) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 47) + override func viewWillDisappear(_ animated: Bool) {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 48) + super.viewWillDisappear(animated)
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 49) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 50) + // 解除授权
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 51) + if #available(iOS 16.0, *) {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 52) + Task {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 53) + let loginRight = try await LARightStore.shared.right(forIdentifier: "bank-card")
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 54) + await loginRight.deauthorize()
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 55) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 56) + } else {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 57) + // Fallback on earlier versions
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 58) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 59) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 60) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 61) + // MARK: 存储数据
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 62) + @available(iOS 16.0, *)
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 63) + func storeData(_ data: Data) async throws {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 64) + // 1. 创建LARight
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 65) + let loginRight = LARight()
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 66) + // 2. 请求授权,弹出验证信息,通过TouchID、FaceID或密码验证
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 67) + try await loginRight.authorize(localizedReason: "用户需要向keychain中存储敏感数据")
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 68) + // 3. 存储数据
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 69) + _ = try await LARightStore.shared.saveRight(loginRight, identifier: "bank-card", secret: data)
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 70) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 71) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 72) + // MARK: 读取数据
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 73) + @available(iOS 16.0, *)
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 74) + func fetchData() async throws -> Data {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 75) + // 1. 获取LARight
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 76) + let loginRight = try await LARightStore.shared.right(forIdentifier: "bank-card")
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 77) + // 2. 请求授权
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 78) + try await loginRight.authorize(localizedReason: "用户需要从keychain中获取敏感数据")
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 79) + // 3. 获取数据
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 80) + let data = try await loginRight.secret.rawData
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 81) + return data
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 82) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 83) +}
[mdiff --git a/templateApp/templateApp/mouldles/iOS16/SystemNewFunctionModule.swift b/templateApp/templateApp/mouldles/iOS16/SystemNewFunctionModule.swift
--- a/templateApp/templateApp/mouldles/iOS16/SystemNewFunctionModule.swift
+++ b/templateApp/templateApp/mouldles/iOS16/SystemNewFunctionModule.swift
febf9a0c (Kael 2022-09-27 16:53:13 +0800 64) }
febf9a0c (Kael 2022-09-27 16:53:13 +0800 65) }),
febf9a0c (Kael 2022-09-27 16:53:13 +0800 66) KLFuncItem(funcName: "UIDevice info", callBack: { [weak self] in
[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 67) - if #available(iOS 16.0, *) {
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 68) - self?.testDeviceInfo()
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 69) - } else {
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 70) - // Fallback on earlier versions
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 71) - }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 67) + self?.testDeviceInfo()
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 68) + }),
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 69) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 70) + KLFuncItem(funcName: "UIDevice screen direction", callBack: { [weak self] in
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 71) + self?.testScreenDevice()
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 72) + }),
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 73) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 74) + KLFuncItem(funcName: "Observe screen direction", callBack: { [weak self] in
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 75) + self?.observeScreenDirection()
[m febf9a0c (Kael 2022-09-27 16:53:13 +0800 72) }),
febf9a0c (Kael 2022-09-27 16:53:13 +0800 73)
febf9a0c (Kael 2022-09-27 16:53:13 +0800 74) KLFuncItem(funcName: "SwiftUI cell", callBack: { [weak self] in
febf9a0c (Kael 2022-09-27 16:53:13 +0800 80) }),
febf9a0c (Kael 2022-09-27 16:53:13 +0800 81) ])
febf9a0c (Kael 2022-09-27 16:53:13 +0800 82) let group2 = KLFuncGroup(groupName: "iOS16 其他功能", funcItemList: [
[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 83) - KLFuncItem(funcName: "UICalendarView", callBack: {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 87) + KLFuncItem(funcName: "系统页面 Scheme 跳转", callBack: { [weak self] in
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 88) + self?.testOpenAppSystemSchema()
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 89) + }),
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 90) + KLFuncItem(funcName: "URLSession multipathServiceType", callBack: {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 91) + self.testURLSession()
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 92) + }),
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 93) + KLFuncItem(funcName: "沙盒路径", callBack: {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 94) + self.testDeviceSandboxPath()
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 95) + }),
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 96) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 97) + KLFuncItem(funcName: "Keychain - LARightStore", callBack: { [weak self] in
[m febf9a0c (Kael 2022-09-27 16:53:13 +0800 84) if #available(iOS 16.0, *) {
[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 85) - let urlString = UIApplication.openNotificationSettingsURLString
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 86) - if let url = URL(string: urlString), UIApplication.shared.canOpenURL(url) {
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 87) - UIApplication.shared.open(url, options: [:], completionHandler: nil)
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 88) - }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 99) + self?.navigationController?.pushViewController(LARightStoreVC(), animated: true)
[m febf9a0c (Kael 2022-09-27 16:53:13 +0800 89) } else {
[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 90) - // 新的通知设置URL Scheme
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 91) - var urlString = ""
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 92) - if #available(iOS 15.4, *) {
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 93) - urlString = UIApplicationOpenNotificationSettingsURLString
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 94) - } else {
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 95) - urlString = UIApplication.openSettingsURLString
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 96) - }
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 97) - if let url = URL(string: urlString), UIApplication.shared.canOpenURL(url) {
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 98) - UIApplication.shared.open(url, options: [:], completionHandler: nil)
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 99) - }
[m[32m + febf9a0c (Kael 2022-09-27 16:53:13 +0800 101) + // Fallback on earlier versions
[m febf9a0c (Kael 2022-09-27 16:53:13 +0800 100) }
febf9a0c (Kael 2022-09-27 16:53:13 +0800 101) }),
febf9a0c (Kael 2022-09-27 16:53:13 +0800 102) ])
febf9a0c (Kael 2022-09-27 16:53:13 +0800 137)
febf9a0c (Kael 2022-09-27 16:53:13 +0800 138) if #available(iOS 16.0, *) {
febf9a0c (Kael 2022-09-27 16:53:13 +0800 139) let vc = SystemNewFunctionModule()
[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 140) - var popover = vc.popoverPresentationController
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 142) + let popover = vc.popoverPresentationController
[m febf9a0c (Kael 2022-09-27 16:53:13 +0800 141) guard let sheet = popover?.adaptiveSheetPresentationController else {
febf9a0c (Kael 2022-09-27 16:53:13 +0800 142) return
febf9a0c (Kael 2022-09-27 16:53:13 +0800 143) }
febf9a0c (Kael 2022-09-27 16:53:13 +0800 208)
febf9a0c (Kael 2022-09-27 16:53:13 +0800 209) }
febf9a0c (Kael 2022-09-27 16:53:13 +0800 210)
[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 211) - @available(iOS 16.0, *)
[m febf9a0c (Kael 2022-09-27 16:53:13 +0800 212) func testDeviceInfo() {
[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 213) - let device = UIDevice.current
[m[31m - febf9a0c (Kael 2022-09-27 16:53:13 +0800 214) - device.model
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 214) + print("------------")
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 215) + let name = UIDevice.current.name
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 216) + print(name)
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 217) + print("------------")
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 218) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 219) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 220) + func testScreenDevice() {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 221) + if #available(iOS 16.0, *) {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 222) + let windowScene = UIApplication.shared.connectedScenes.first as? UIWindowScene
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 223) + windowScene?.requestGeometryUpdate(.iOS(interfaceOrientations: .landscapeLeft))
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 224) + } else {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 225) + UIDevice.current.setValue(UIInterfaceOrientation.landscapeLeft.rawValue, forKey: "orientation")
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 226) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 227) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 228) + DispatchQueue.main.asyncAfter(deadline: .now() + 5 ) {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 229) + if #available(iOS 16.0, *) {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 230) + let windowScene = UIApplication.shared.connectedScenes.first as? UIWindowScene
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 231) + windowScene?.requestGeometryUpdate(.iOS(interfaceOrientations: .portrait))
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 232) + } else {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 233) + UIDevice.current.setValue(UIInterfaceOrientation.portrait.rawValue, forKey: "orientation")
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 234) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 235) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 236) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 237) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 238) + func observeScreenDirection () {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 239) + UIDevice.current.beginGeneratingDeviceOrientationNotifications()
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 240) + NotificationCenter.default.addObserver(self, selector: #selector(orientChange(noti:)), name: UIDevice.orientationDidChangeNotification, object: nil)
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 241) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 242) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 243) + @objc
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 244) + func orientChange(noti:Notification) {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 245) + let orient = UIDevice.current.orientation
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 246) + switch orient {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 247) + case .unknown:
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 248) + print("未知")
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 249) + case .portrait:
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 250) + print("竖屏")
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 251) + case .portraitUpsideDown:
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 252) + print("倒立竖屏")
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 253) + case .landscapeLeft:
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 254) + print("Home按键在左侧")
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 255) + case .landscapeRight:
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 256) + print("home 按键在右侧")
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 257) + case .faceUp:
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 258) + print("正面朝上")
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 259) + case .faceDown:
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 260) + print("正面朝下")
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 261) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 262) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 263) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 264) +}
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 265) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 266) +// MARK: - Other
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 267) +extension SystemNewFunctionModule {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 268) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 269) + func testOpenAppSystemSchema() {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 270) + if #available(iOS 16.0, *) {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 271) + let urlString = UIApplication.openNotificationSettingsURLString
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 272) + if let url = URL(string: urlString), UIApplication.shared.canOpenURL(url) {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 273) + UIApplication.shared.open(url, options: [:], completionHandler: nil)
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 274) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 275) + } else {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 276) + // 新的通知设置URL Scheme
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 277) + var urlString = ""
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 278) + if #available(iOS 15.4, *) {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 279) + urlString = UIApplicationOpenNotificationSettingsURLString
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 280) + } else {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 281) + urlString = UIApplication.openSettingsURLString
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 282) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 283) + if let url = URL(string: urlString), UIApplication.shared.canOpenURL(url) {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 284) + UIApplication.shared.open(url, options: [:], completionHandler: nil)
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 285) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 286) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 287) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 288) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 289) + func testURLSession() {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 290) + let configuration = URLSessionConfiguration.default
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 291) + // MultipathServiceType是一个枚举类型,App可以采用不同的策略来利用这些网络通道
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 292) + configuration.multipathServiceType = .handover
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 293) + let session = URLSession(configuration: configuration)
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 294) + }
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 295) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 296) + func testDeviceSandboxPath() {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 297) + if #available(iOS 16.0, *) {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 298) + // Home目录
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 299) + let homeDirectory = URL.homeDirectory
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 300) + print(homeDirectory)
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 301) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 302) + // Documents目录
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 303) + let documentsURL = URL.documentsDirectory
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 304) + print(documentsURL)
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 305) +
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 306) + // Library目录
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 307) + var libraryDirectory = URL.libraryDirectory
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 308) + // append():直接在libraryDirectory进行拼接
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 309) + // directoryHint:是否应该执行文件系统检查,以确定路径是否指向文件夹
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 310) + libraryDirectory.append(path: "abc", directoryHint: .inferFromPath)
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 311) + print(libraryDirectory)
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 312) + // appending():拼接后产生新的URL,不影响原来的libraryDirectory
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 313) + let newURL = libraryDirectory.appending(path: "123", directoryHint: .inferFromPath)
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 314) + print(newURL)
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 315) + } else {
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 316) + // Fallback on earlier versions
[m[32m + 00000000 (Not Committed Yet 2022-10-23 00:44:34 +0800 317) + }
[m febf9a0c (Kael 2022-09-27 16:53:13 +0800 215) }
febf9a0c (Kael 2022-09-27 16:53:13 +0800 216)
febf9a0c (Kael 2022-09-27 16:53:13 +0800 217) }
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。