From 999bcb1ebbf5ad2305c6cf6808ac85ae6a1b6601 Mon Sep 17 00:00:00 2001 From: OS-ricardomoreirasilva Date: Thu, 24 Oct 2024 12:28:57 +0100 Subject: [PATCH] chore: update example app for new plugin version This also fixes a crash with the iOS app when opening the barcode scanner, as the 'NSCameraUsageDescription' permission is missing. References: https://outsystemsrd.atlassian.net/browse/RMET-3755 --- example-app/android/build.gradle | 2 +- example-app/android/capacitor.settings.gradle | 10 ++-- .../gradle/wrapper/gradle-wrapper.properties | 2 +- .../ios/App/App.xcodeproj/project.pbxproj | 8 +-- example-app/ios/App/App/Info.plist | 4 +- example-app/ios/App/Podfile | 16 +++--- example-app/ios/App/Podfile.lock | 54 +++++++++---------- example-app/package.json | 16 +++--- 8 files changed, 57 insertions(+), 55 deletions(-) diff --git a/example-app/android/build.gradle b/example-app/android/build.gradle index 3f500b5..4dd07e6 100644 --- a/example-app/android/build.gradle +++ b/example-app/android/build.gradle @@ -7,7 +7,7 @@ buildscript { mavenCentral() } dependencies { - classpath 'com.android.tools.build:gradle:8.2.1' + classpath 'com.android.tools.build:gradle:8.7.1' classpath 'com.google.gms:google-services:4.4.0' // NOTE: Do not place your application dependencies here; they belong diff --git a/example-app/android/capacitor.settings.gradle b/example-app/android/capacitor.settings.gradle index a7fa91b..519c162 100644 --- a/example-app/android/capacitor.settings.gradle +++ b/example-app/android/capacitor.settings.gradle @@ -1,18 +1,18 @@ // DO NOT EDIT THIS FILE! IT IS GENERATED EACH TIME "capacitor update" IS RUN include ':capacitor-android' -project(':capacitor-android').projectDir = new File('../../node_modules/.pnpm/@capacitor+android@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/android/capacitor') +project(':capacitor-android').projectDir = new File('../../node_modules/.pnpm/@capacitor+android@7.0.0-alpha.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/android/capacitor') include ':capacitor-app' -project(':capacitor-app').projectDir = new File('../../node_modules/.pnpm/@capacitor+app@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/app/android') +project(':capacitor-app').projectDir = new File('../../node_modules/.pnpm/@capacitor+app@6.0.0-rc.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/app/android') include ':capacitor-barcode-scanner' project(':capacitor-barcode-scanner').projectDir = new File('../../plugin/android') include ':capacitor-haptics' -project(':capacitor-haptics').projectDir = new File('../../node_modules/.pnpm/@capacitor+haptics@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/haptics/android') +project(':capacitor-haptics').projectDir = new File('../../node_modules/.pnpm/@capacitor+haptics@6.0.0-rc.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/haptics/android') include ':capacitor-keyboard' -project(':capacitor-keyboard').projectDir = new File('../../node_modules/.pnpm/@capacitor+keyboard@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/keyboard/android') +project(':capacitor-keyboard').projectDir = new File('../../node_modules/.pnpm/@capacitor+keyboard@6.0.0-rc.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/keyboard/android') include ':capacitor-status-bar' -project(':capacitor-status-bar').projectDir = new File('../../node_modules/.pnpm/@capacitor+status-bar@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/status-bar/android') +project(':capacitor-status-bar').projectDir = new File('../../node_modules/.pnpm/@capacitor+status-bar@6.0.0-rc.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/status-bar/android') diff --git a/example-app/android/gradle/wrapper/gradle-wrapper.properties b/example-app/android/gradle/wrapper/gradle-wrapper.properties index c747538..dedd5d1 100644 --- a/example-app/android/gradle/wrapper/gradle-wrapper.properties +++ b/example-app/android/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.2.1-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.9-all.zip networkTimeout=10000 validateDistributionUrl=true zipStoreBase=GRADLE_USER_HOME diff --git a/example-app/ios/App/App.xcodeproj/project.pbxproj b/example-app/ios/App/App.xcodeproj/project.pbxproj index dde701f..a81ac6a 100644 --- a/example-app/ios/App/App.xcodeproj/project.pbxproj +++ b/example-app/ios/App/App.xcodeproj/project.pbxproj @@ -349,9 +349,9 @@ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CODE_SIGN_STYLE = Automatic; CURRENT_PROJECT_VERSION = 1; - DEVELOPMENT_TEAM = 9YN2HU59K8; + DEVELOPMENT_TEAM = S25XN959HW; INFOPLIST_FILE = App/Info.plist; - IPHONEOS_DEPLOYMENT_TARGET = 13.0; + IPHONEOS_DEPLOYMENT_TARGET = 14.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; MARKETING_VERSION = 1.0; OTHER_SWIFT_FLAGS = "$(inherited) \"-D\" \"COCOAPODS\" \"-DDEBUG\""; @@ -370,9 +370,9 @@ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CODE_SIGN_STYLE = Automatic; CURRENT_PROJECT_VERSION = 1; - DEVELOPMENT_TEAM = 9YN2HU59K8; + DEVELOPMENT_TEAM = S25XN959HW; INFOPLIST_FILE = App/Info.plist; - IPHONEOS_DEPLOYMENT_TARGET = 13.0; + IPHONEOS_DEPLOYMENT_TARGET = 14.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; MARKETING_VERSION = 1.0; PRODUCT_BUNDLE_IDENTIFIER = io.ionic.starter; diff --git a/example-app/ios/App/App/Info.plist b/example-app/ios/App/App/Info.plist index cf1affd..b7212cb 100644 --- a/example-app/ios/App/App/Info.plist +++ b/example-app/ios/App/App/Info.plist @@ -5,7 +5,7 @@ CFBundleDevelopmentRegion en CFBundleDisplayName - example-app + example-app CFBundleExecutable $(EXECUTABLE_NAME) CFBundleIdentifier @@ -45,5 +45,7 @@ UIViewControllerBasedStatusBarAppearance + NSCameraUsageDescription + Uses the camera to scan barcodes. diff --git a/example-app/ios/App/Podfile b/example-app/ios/App/Podfile index 93d056d..89cbc73 100644 --- a/example-app/ios/App/Podfile +++ b/example-app/ios/App/Podfile @@ -1,6 +1,6 @@ -require_relative '../../../node_modules/.pnpm/@capacitor+ios@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/ios/scripts/pods_helpers' +require_relative '../../../node_modules/.pnpm/@capacitor+ios@7.0.0-alpha.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/ios/scripts/pods_helpers' -platform :ios, '13.0' +platform :ios, '14.0' use_frameworks! # workaround to avoid Xcode caching of Pods that requires @@ -9,13 +9,13 @@ use_frameworks! install! 'cocoapods', :disable_input_output_paths => true def capacitor_pods - pod 'Capacitor', :path => '../../../node_modules/.pnpm/@capacitor+ios@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/ios' - pod 'CapacitorCordova', :path => '../../../node_modules/.pnpm/@capacitor+ios@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/ios' - pod 'CapacitorApp', :path => '../../../node_modules/.pnpm/@capacitor+app@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/app' + pod 'Capacitor', :path => '../../../node_modules/.pnpm/@capacitor+ios@7.0.0-alpha.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/ios' + pod 'CapacitorCordova', :path => '../../../node_modules/.pnpm/@capacitor+ios@7.0.0-alpha.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/ios' + pod 'CapacitorApp', :path => '../../../node_modules/.pnpm/@capacitor+app@6.0.0-rc.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/app' pod 'CapacitorBarcodeScanner', :path => '../../../plugin' - pod 'CapacitorHaptics', :path => '../../../node_modules/.pnpm/@capacitor+haptics@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/haptics' - pod 'CapacitorKeyboard', :path => '../../../node_modules/.pnpm/@capacitor+keyboard@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/keyboard' - pod 'CapacitorStatusBar', :path => '../../../node_modules/.pnpm/@capacitor+status-bar@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/status-bar' + pod 'CapacitorHaptics', :path => '../../../node_modules/.pnpm/@capacitor+haptics@6.0.0-rc.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/haptics' + pod 'CapacitorKeyboard', :path => '../../../node_modules/.pnpm/@capacitor+keyboard@6.0.0-rc.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/keyboard' + pod 'CapacitorStatusBar', :path => '../../../node_modules/.pnpm/@capacitor+status-bar@6.0.0-rc.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/status-bar' end target 'App' do diff --git a/example-app/ios/App/Podfile.lock b/example-app/ios/App/Podfile.lock index db0a9e2..b8dc66a 100644 --- a/example-app/ios/App/Podfile.lock +++ b/example-app/ios/App/Podfile.lock @@ -1,28 +1,28 @@ PODS: - - Capacitor (6.0.0): + - Capacitor (7.0.0-alpha.1): - CapacitorCordova - - CapacitorApp (6.0.0): + - CapacitorApp (6.0.0-rc.1): - Capacitor - - CapacitorBarcodeScanner (1.0.0): + - CapacitorBarcodeScanner (1.0.1): - Capacitor - OSBarcodeLib (~> 1.1.0) - - CapacitorCordova (6.0.0) - - CapacitorHaptics (6.0.0): + - CapacitorCordova (7.0.0-alpha.1) + - CapacitorHaptics (6.0.0-rc.1): - Capacitor - - CapacitorKeyboard (6.0.0): + - CapacitorKeyboard (6.0.0-rc.1): - Capacitor - - CapacitorStatusBar (6.0.0): + - CapacitorStatusBar (6.0.0-rc.1): - Capacitor - OSBarcodeLib (1.1.0) DEPENDENCIES: - - "Capacitor (from `../../../node_modules/.pnpm/@capacitor+ios@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/ios`)" - - "CapacitorApp (from `../../../node_modules/.pnpm/@capacitor+app@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/app`)" + - "Capacitor (from `../../../node_modules/.pnpm/@capacitor+ios@7.0.0-alpha.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/ios`)" + - "CapacitorApp (from `../../../node_modules/.pnpm/@capacitor+app@6.0.0-rc.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/app`)" - CapacitorBarcodeScanner (from `../../../plugin`) - - "CapacitorCordova (from `../../../node_modules/.pnpm/@capacitor+ios@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/ios`)" - - "CapacitorHaptics (from `../../../node_modules/.pnpm/@capacitor+haptics@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/haptics`)" - - "CapacitorKeyboard (from `../../../node_modules/.pnpm/@capacitor+keyboard@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/keyboard`)" - - "CapacitorStatusBar (from `../../../node_modules/.pnpm/@capacitor+status-bar@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/status-bar`)" + - "CapacitorCordova (from `../../../node_modules/.pnpm/@capacitor+ios@7.0.0-alpha.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/ios`)" + - "CapacitorHaptics (from `../../../node_modules/.pnpm/@capacitor+haptics@6.0.0-rc.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/haptics`)" + - "CapacitorKeyboard (from `../../../node_modules/.pnpm/@capacitor+keyboard@6.0.0-rc.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/keyboard`)" + - "CapacitorStatusBar (from `../../../node_modules/.pnpm/@capacitor+status-bar@6.0.0-rc.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/status-bar`)" SPEC REPOS: trunk: @@ -30,30 +30,30 @@ SPEC REPOS: EXTERNAL SOURCES: Capacitor: - :path: "../../../node_modules/.pnpm/@capacitor+ios@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/ios" + :path: "../../../node_modules/.pnpm/@capacitor+ios@7.0.0-alpha.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/ios" CapacitorApp: - :path: "../../../node_modules/.pnpm/@capacitor+app@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/app" + :path: "../../../node_modules/.pnpm/@capacitor+app@6.0.0-rc.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/app" CapacitorBarcodeScanner: :path: "../../../plugin" CapacitorCordova: - :path: "../../../node_modules/.pnpm/@capacitor+ios@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/ios" + :path: "../../../node_modules/.pnpm/@capacitor+ios@7.0.0-alpha.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/ios" CapacitorHaptics: - :path: "../../../node_modules/.pnpm/@capacitor+haptics@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/haptics" + :path: "../../../node_modules/.pnpm/@capacitor+haptics@6.0.0-rc.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/haptics" CapacitorKeyboard: - :path: "../../../node_modules/.pnpm/@capacitor+keyboard@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/keyboard" + :path: "../../../node_modules/.pnpm/@capacitor+keyboard@6.0.0-rc.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/keyboard" CapacitorStatusBar: - :path: "../../../node_modules/.pnpm/@capacitor+status-bar@6.0.0_@capacitor+core@6.0.0/node_modules/@capacitor/status-bar" + :path: "../../../node_modules/.pnpm/@capacitor+status-bar@6.0.0-rc.1_@capacitor+core@7.0.0-alpha.1/node_modules/@capacitor/status-bar" SPEC CHECKSUMS: - Capacitor: 559d073c4ca6c27f8e7002c807eea94c3ba435a9 - CapacitorApp: 9d53aec7101f7b030a950c5bdc4df8612576b279 - CapacitorBarcodeScanner: 3780aa09a86e526b2903d3b804bd867100f4c924 - CapacitorCordova: 8c4bfdf69368512e85b1d8b724dd7546abeb30af - CapacitorHaptics: 9ebc9363f0e9b8eb4295088a0b474530acf1859b - CapacitorKeyboard: deacbd09d8d1029c3681197fb05d206b721d5f73 - CapacitorStatusBar: 2e4369f99166125435641b1908d05f561eaba6f6 + Capacitor: bba49f57640a895581dee494f20489e97a6a4fe2 + CapacitorApp: 649eca1980ddb28d43177bc78b252123e243b848 + CapacitorBarcodeScanner: c2c1dfda29d805c99ac4531b6f87c94ea64735ce + CapacitorCordova: f3378f035160ac7b234ee39d10098c1ecbb6f078 + CapacitorHaptics: b004f0eb5b1cbef124889ccf745679f3aa9568ef + CapacitorKeyboard: 683563ad6b13c1a46bfc710d49b4621570feef48 + CapacitorStatusBar: 31febfff4331f2e800847abdac79d64f04eb4206 OSBarcodeLib: ced133bc1ec073636e18c6a0553d0a5c4b90cf17 -PODFILE CHECKSUM: 1d6169ce9a8e5c5a436844292f343842268f688b +PODFILE CHECKSUM: 66a45479d1024a7f650ee9589958afd9cb575718 COCOAPODS: 1.15.2 diff --git a/example-app/package.json b/example-app/package.json index daa0354..e02fa2d 100644 --- a/example-app/package.json +++ b/example-app/package.json @@ -12,14 +12,14 @@ "lint": "eslint" }, "dependencies": { - "@capacitor/android": "^6.0.0", - "@capacitor/app": "^6.0.0", + "@capacitor/android": "next", + "@capacitor/app": "next", "@capacitor/barcode-scanner": "workspace:*", - "@capacitor/core": "^6.0.0", - "@capacitor/haptics": "^6.0.0", - "@capacitor/ios": "^6.0.0", - "@capacitor/keyboard": "^6.0.0", - "@capacitor/status-bar": "^6.0.0", + "@capacitor/core": "next", + "@capacitor/haptics": "next", + "@capacitor/ios": "next", + "@capacitor/keyboard": "next", + "@capacitor/status-bar": "next", "@ionic/react": "^7.0.0", "@ionic/react-router": "^7.0.0", "@types/react-router": "^5.1.20", @@ -31,7 +31,7 @@ "react-router-dom": "^5.3.4" }, "devDependencies": { - "@capacitor/cli": "^6.0.0", + "@capacitor/cli": "next", "@testing-library/dom": ">=7.21.4", "@testing-library/jest-dom": "^5.16.5", "@testing-library/react": "^14.0.0",