Skip to content

Commit b9d7e47

Browse files
committed
Update to @capacitor/[email protected]
1 parent b056d02 commit b9d7e47

File tree

18 files changed

+1009
-3714
lines changed

18 files changed

+1009
-3714
lines changed

CHANGELOG.md

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,41 @@
1+
# 5.0.0 (2023-05-24)
2+
3+
### Chore
4+
5+
- Update to @capacitor/core@5.0.4
6+
- Update to @capacitor/ios@5.0.4
7+
- Update to @capacitor/android@5.0.4
8+
9+
### Added Features
10+
11+
- Enable electron database encryption PR#342 from Clément Béligat
12+
13+
### Bug Fixes
14+
15+
- Fix Encrypted electron database issue#162
16+
17+
# 5.0.0-beta.2 (2023-05-08)
18+
19+
### Chore
20+
21+
- Update to @capacitor/core 5.0.0
22+
- Update to @capacitor/ios 5.0.0
23+
- Update to @capacitor/android 5.0.0
24+
25+
# 5.0.0-beta.1 (2023-04-12)
26+
27+
### Bug Fixes
28+
29+
- Fix UtilsJson (Android}
30+
31+
# 5.0.0-beta.0 (2023-04-08)
32+
33+
### Chore
34+
35+
- Update to @capacitor/core@5.0.0-beta.1
36+
- Update to @capacitor/ios@5.0.0-beta.1
37+
- Update to @capacitor/android@5.0.0-beta.1
38+
139
# 4.8.0 (2023-05-24)
240

341
### Added Features

README.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<p align="center"><br><img src="https://user-images.githubusercontent.com/236501/85893648-1c92e880-b7a8-11ea-926d-95355b8175c7.png" width="128" height="128" /></p>
22
<h3 align="center">SQLITE DATABASE</h3>
3-
<p align="center"><strong><code>@capacitor-community/sqlite</code></strong></p>
3+
<p align="center"><strong><code>@capacitor-community/sqlite@next</code></strong></p>
44
<br>
5-
<p align="center" style="font-size:50px;color:red"><strong>CAPACITOR 4</strong></p><br>
5+
<p align="center" style="font-size:50px;color:red"><strong>CAPACITOR 5</strong></p><br>
66

77
<p align="center">
88
Capacitor community plugin for Native and Electron SQLite Databases. In Native databases could be encrypted with SQLCipher
@@ -16,7 +16,7 @@
1616
<a href="https://www.npmjs.com/package/@capacitor-community/sqlite"><img src="https://img.shields.io/npm/dw/@capacitor-community/sqlite?style=flat-square" /></a>
1717
<a href="https://www.npmjs.com/package/@capacitor-community/sqlite"><img src="https://img.shields.io/npm/v/@capacitor-community/sqlite?style=flat-square" /></a>
1818
<!-- ALL-CONTRIBUTORS-BADGE:START - Do not remove or modify this section -->
19-
<a href="#contributors-"><img src="https://img.shields.io/badge/all%20contributors-34-orange?style=flat-square" /></a>
19+
<a href="#contributors-"><img src="https://img.shields.io/badge/all%20contributors-35-orange?style=flat-square" /></a>
2020
<!-- ALL-CONTRIBUTORS-BADGE:END -->
2121
</p>
2222

@@ -79,6 +79,7 @@ then add plugin to main `capacitor.config.json` file:
7979

8080
## More Reading:
8181

82+
- [Updating to Capacitor 5](https://capacitorjs.com/docs/updating/5-0)
8283
- [Releases](https://github.com/capacitor-community/sqlite/blob/master/info_releases.md)
8384
- [Changelog](https://github.com/capacitor-community/sqlite/blob/master/CHANGELOG.md)
8485
- [Issues](https://github.com/capacitor-community/sqlite/issues)
@@ -116,8 +117,8 @@ You'll need the usual capacitor/android/react npm script to build and copy the a
116117
See [#301](https://github.com/capacitor-community/sqlite/issues/301) and [SO question](https://stackoverflow.com/questions/63291529/how-to-fix-more-than-one-file-was-found-with-os-independent-path-build-data-pro) for more information.
117118

118119
- Check/Add the following:
119-
Gradle JDK version 11
120-
Android Gradle Plugin Version 7.2.2
120+
Gradle JDK version 17
121+
Android Gradle Plugin Version 8.0.0
121122
In variables.gradle
122123

123124
```
Binary file not shown.
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
#Sun Aug 07 13:48:51 CEST 2022
2-
gradle.version=7.4.2
1+
#Wed May 24 08:44:29 CEST 2023
2+
gradle.version=8.0.2
Binary file not shown.

android/build.gradle

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -11,20 +11,21 @@ buildscript {
1111
mavenCentral()
1212
}
1313
dependencies {
14-
classpath 'com.android.tools.build:gradle:7.2.2'
14+
classpath 'com.android.tools.build:gradle:8.0.0'
1515
}
1616
}
1717

1818
apply plugin: 'com.android.library'
1919

2020
android {
21-
compileSdkVersion project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion : 32
21+
namespace "com.getcapacitor.community.database.sqlite"
22+
compileSdkVersion project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion : 33
2223
packagingOptions {
2324
exclude 'build-data.properties'
2425
}
2526
defaultConfig {
2627
minSdkVersion project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 22
27-
targetSdkVersion project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion : 32
28+
targetSdkVersion project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion : 33
2829
versionCode 1
2930
versionName "1.0"
3031
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
@@ -39,8 +40,8 @@ android {
3940
abortOnError false
4041
}
4142
compileOptions {
42-
sourceCompatibility JavaVersion.VERSION_11
43-
targetCompatibility JavaVersion.VERSION_11
43+
sourceCompatibility JavaVersion.VERSION_17
44+
targetCompatibility JavaVersion.VERSION_17
4445
}
4546
}
4647

@@ -55,15 +56,15 @@ dependencies {
5556
implementation fileTree(dir: 'libs', include: ['*.jar'])
5657
implementation project(':capacitor-android')
5758
implementation "androidx.appcompat:appcompat:$androidxAppCompatVersion"
58-
implementation 'androidx.room:room-runtime:2.5.0'
59+
implementation 'androidx.room:room-runtime:2.5.1'
5960
testImplementation "junit:junit:$junitVersion"
6061
androidTestImplementation "androidx.test.ext:junit:$androidxJunitVersion"
6162
androidTestImplementation "androidx.test.espresso:espresso-core:$androidxEspressoCoreVersion"
6263
implementation "androidx.coordinatorlayout:coordinatorlayout:1.2.0"
6364
implementation 'net.zetetic:android-database-sqlcipher:4.5.3'
64-
implementation "androidx.sqlite:sqlite:2.3.0"
65+
implementation "androidx.sqlite:sqlite:2.3.1"
6566
//security library
66-
implementation "androidx.security:security-crypto:1.1.0-alpha05"
67+
implementation "androidx.security:security-crypto:1.1.0-alpha06"
6768
implementation "androidx.biometric:biometric:1.1.0"
68-
annotationProcessor 'androidx.room:room-compiler:2.5.0'
69+
annotationProcessor 'androidx.room:room-compiler:2.5.1'
6970
}

android/gradle.properties

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,5 +20,4 @@ org.gradle.jvmargs=-Xmx1536m
2020
# Android operating system, and which are packaged with your app's APK
2121
# https://developer.android.com/topic/libraries/support-library/androidx-rn
2222
android.useAndroidX=true
23-
# Automatically convert third-party libraries to use AndroidX
24-
android.enableJetifier=true
23+
1.75 KB
Binary file not shown.
Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
1-
#Sat May 29 10:04:38 CEST 2021
21
distributionBase=GRADLE_USER_HOME
3-
#distributionUrl=https\://services.gradle.org/distributions/gradle-7.0.2-bin.zip
4-
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4.2-all.zip
52
distributionPath=wrapper/dists
6-
zipStorePath=wrapper/dists
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.0.2-all.zip
4+
networkTimeout=10000
75
zipStoreBase=GRADLE_USER_HOME
6+
zipStorePath=wrapper/dists

android/gradlew

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@
5555
# Darwin, MinGW, and NonStop.
5656
#
5757
# (3) This script is generated from the Groovy template
58-
# https://github.com/gradle/gradle/blob/master/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
58+
# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
5959
# within the Gradle project.
6060
#
6161
# You can find Gradle at https://github.com/gradle/gradle/.
@@ -80,10 +80,10 @@ do
8080
esac
8181
done
8282

83-
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit
84-
85-
APP_NAME="Gradle"
83+
# This is normally unused
84+
# shellcheck disable=SC2034
8685
APP_BASE_NAME=${0##*/}
86+
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit
8787

8888
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
8989
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
@@ -143,12 +143,16 @@ fi
143143
if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
144144
case $MAX_FD in #(
145145
max*)
146+
# In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked.
147+
# shellcheck disable=SC3045
146148
MAX_FD=$( ulimit -H -n ) ||
147149
warn "Could not query maximum file descriptor limit"
148150
esac
149151
case $MAX_FD in #(
150152
'' | soft) :;; #(
151153
*)
154+
# In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked.
155+
# shellcheck disable=SC3045
152156
ulimit -n "$MAX_FD" ||
153157
warn "Could not set maximum file descriptor limit to $MAX_FD"
154158
esac
@@ -205,6 +209,12 @@ set -- \
205209
org.gradle.wrapper.GradleWrapperMain \
206210
"$@"
207211

212+
# Stop when "xargs" is not available.
213+
if ! command -v xargs >/dev/null 2>&1
214+
then
215+
die "xargs is not available"
216+
fi
217+
208218
# Use "xargs" to parse quoted args.
209219
#
210220
# With -n1 it outputs one arg per line, with the quotes and backslashes removed.

android/gradlew.bat

Lines changed: 92 additions & 89 deletions
Original file line numberDiff line numberDiff line change
@@ -1,89 +1,92 @@
1-
@rem
2-
@rem Copyright 2015 the original author or authors.
3-
@rem
4-
@rem Licensed under the Apache License, Version 2.0 (the "License");
5-
@rem you may not use this file except in compliance with the License.
6-
@rem You may obtain a copy of the License at
7-
@rem
8-
@rem https://www.apache.org/licenses/LICENSE-2.0
9-
@rem
10-
@rem Unless required by applicable law or agreed to in writing, software
11-
@rem distributed under the License is distributed on an "AS IS" BASIS,
12-
@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13-
@rem See the License for the specific language governing permissions and
14-
@rem limitations under the License.
15-
@rem
16-
17-
@if "%DEBUG%" == "" @echo off
18-
@rem ##########################################################################
19-
@rem
20-
@rem Gradle startup script for Windows
21-
@rem
22-
@rem ##########################################################################
23-
24-
@rem Set local scope for the variables with windows NT shell
25-
if "%OS%"=="Windows_NT" setlocal
26-
27-
set DIRNAME=%~dp0
28-
if "%DIRNAME%" == "" set DIRNAME=.
29-
set APP_BASE_NAME=%~n0
30-
set APP_HOME=%DIRNAME%
31-
32-
@rem Resolve any "." and ".." in APP_HOME to make it shorter.
33-
for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi
34-
35-
@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
36-
set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
37-
38-
@rem Find java.exe
39-
if defined JAVA_HOME goto findJavaFromJavaHome
40-
41-
set JAVA_EXE=java.exe
42-
%JAVA_EXE% -version >NUL 2>&1
43-
if "%ERRORLEVEL%" == "0" goto execute
44-
45-
echo.
46-
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
47-
echo.
48-
echo Please set the JAVA_HOME variable in your environment to match the
49-
echo location of your Java installation.
50-
51-
goto fail
52-
53-
:findJavaFromJavaHome
54-
set JAVA_HOME=%JAVA_HOME:"=%
55-
set JAVA_EXE=%JAVA_HOME%/bin/java.exe
56-
57-
if exist "%JAVA_EXE%" goto execute
58-
59-
echo.
60-
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
61-
echo.
62-
echo Please set the JAVA_HOME variable in your environment to match the
63-
echo location of your Java installation.
64-
65-
goto fail
66-
67-
:execute
68-
@rem Setup the command line
69-
70-
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
71-
72-
73-
@rem Execute Gradle
74-
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %*
75-
76-
:end
77-
@rem End local scope for the variables with windows NT shell
78-
if "%ERRORLEVEL%"=="0" goto mainEnd
79-
80-
:fail
81-
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
82-
rem the _cmd.exe /c_ return code!
83-
if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
84-
exit /b 1
85-
86-
:mainEnd
87-
if "%OS%"=="Windows_NT" endlocal
88-
89-
:omega
1+
@rem
2+
@rem Copyright 2015 the original author or authors.
3+
@rem
4+
@rem Licensed under the Apache License, Version 2.0 (the "License");
5+
@rem you may not use this file except in compliance with the License.
6+
@rem You may obtain a copy of the License at
7+
@rem
8+
@rem https://www.apache.org/licenses/LICENSE-2.0
9+
@rem
10+
@rem Unless required by applicable law or agreed to in writing, software
11+
@rem distributed under the License is distributed on an "AS IS" BASIS,
12+
@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
@rem See the License for the specific language governing permissions and
14+
@rem limitations under the License.
15+
@rem
16+
17+
@if "%DEBUG%"=="" @echo off
18+
@rem ##########################################################################
19+
@rem
20+
@rem Gradle startup script for Windows
21+
@rem
22+
@rem ##########################################################################
23+
24+
@rem Set local scope for the variables with windows NT shell
25+
if "%OS%"=="Windows_NT" setlocal
26+
27+
set DIRNAME=%~dp0
28+
if "%DIRNAME%"=="" set DIRNAME=.
29+
@rem This is normally unused
30+
set APP_BASE_NAME=%~n0
31+
set APP_HOME=%DIRNAME%
32+
33+
@rem Resolve any "." and ".." in APP_HOME to make it shorter.
34+
for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi
35+
36+
@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
37+
set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
38+
39+
@rem Find java.exe
40+
if defined JAVA_HOME goto findJavaFromJavaHome
41+
42+
set JAVA_EXE=java.exe
43+
%JAVA_EXE% -version >NUL 2>&1
44+
if %ERRORLEVEL% equ 0 goto execute
45+
46+
echo.
47+
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
48+
echo.
49+
echo Please set the JAVA_HOME variable in your environment to match the
50+
echo location of your Java installation.
51+
52+
goto fail
53+
54+
:findJavaFromJavaHome
55+
set JAVA_HOME=%JAVA_HOME:"=%
56+
set JAVA_EXE=%JAVA_HOME%/bin/java.exe
57+
58+
if exist "%JAVA_EXE%" goto execute
59+
60+
echo.
61+
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
62+
echo.
63+
echo Please set the JAVA_HOME variable in your environment to match the
64+
echo location of your Java installation.
65+
66+
goto fail
67+
68+
:execute
69+
@rem Setup the command line
70+
71+
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
72+
73+
74+
@rem Execute Gradle
75+
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %*
76+
77+
:end
78+
@rem End local scope for the variables with windows NT shell
79+
if %ERRORLEVEL% equ 0 goto mainEnd
80+
81+
:fail
82+
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
83+
rem the _cmd.exe /c_ return code!
84+
set EXIT_CODE=%ERRORLEVEL%
85+
if %EXIT_CODE% equ 0 set EXIT_CODE=1
86+
if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE%
87+
exit /b %EXIT_CODE%
88+
89+
:mainEnd
90+
if "%OS%"=="Windows_NT" endlocal
91+
92+
:omega

android/src/main/AndroidManifest.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
2-
package="com.getcapacitor.community.database.sqlite">
2+
>
33
</manifest>

0 commit comments

Comments
 (0)