Skip to content

Commit ecf0c27

Browse files
Update HyperTrack SDK to 6.4.2 (#19)
Add git hook to check plugin.xml version. Update CONTRIBUTING.
1 parent 2b735ec commit ecf0c27

File tree

8 files changed

+33
-11
lines changed

8 files changed

+33
-11
lines changed

.githooks/pre-push

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# Read the version from package.json
2+
package_version=$(cat package.json | grep -m 1 "\"version\"" | awk -F: '{gsub(/[", ]/, "", $2); print $2}')
3+
4+
# Read the version from plugin.xml
5+
plugin_version=$(cat plugin.xml | tail -n +2 | grep -o 'version="[^"]*"' | head -n 1 | sed 's/version="//' | sed 's/"//')
6+
7+
# Compare the versions
8+
if [ "$package_version" != "$plugin_version" ]; then
9+
echo "Error: Version mismatch!"
10+
echo "Package.json version: $package_version"
11+
echo "Plugin.xml version: $plugin_version"
12+
exit 1
13+
fi

.justfile

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
1-
release:
1+
hooks:
2+
chmod +x .githooks/pre-push
3+
git config core.hooksPath .githooks
4+
5+
release: hooks
26
npm publish --dry-run
37
@echo "THIS IS DRY RUN. Check if everything is ok and then run 'npm publish'. Checklist:"
48
@echo "\t- check the release steps in CONTRIBUTING"

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,11 @@
33
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
44
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
55

6+
## [1.0.2] - 2023-06-15
7+
8+
### Changed
9+
- Updated HyperTrack Android SDK to 6.4.2
10+
611
## [1.0.1] - 2023-06-01
712

813
### Changed

CONTRIBUTING.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,22 +6,22 @@
66

77
1. Update SDK version constant
88
- Android
9-
- src/android/HypertrackPlugin.gradle
9+
- [src/android/HypertrackPlugin.gradle](src/android/HypertrackPlugin.gradle)
1010
- HYPERTRACK_SDK_VERSION
1111
- iOS
12-
- plugin.xml
12+
- [plugin.xml](plugin.xml)
1313
- `<platform name="ios">`
1414
- `<pod name="HyperTrack" version="**version**"/>`
1515

1616
2. Update wrapper version
17-
- package.json
17+
- [package.json](package.json)
1818
- version
19-
- plugin.xml
19+
- [plugin.xml](plugin.xml)
2020
- version
2121

22-
3. Update CHANGELOG
22+
3. Update [CHANGELOG](CHANGELOG.md)
2323

24-
4. Update the README badge
24+
4. Update the [README](README.md) badge
2525

2626
5. Do the release dry run with `just release` and verify that the release is correct (checklist is in the command output)
2727

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
![GitHub](https://img.shields.io/github/license/hypertrack/cordova-plugin-hypertrack.svg)
44
![npm](https://img.shields.io/npm/v/cordova-plugin-hypertrack-v3.svg)
55
[![iOS SDK](https://img.shields.io/badge/iOS%20SDK-4.16.0-brightgreen.svg)](https://cocoapods.org/pods/HyperTrack)
6-
![Android SDK](https://img.shields.io/badge/Android%20SDK-6.4.0-brightgreen.svg)
6+
![Android SDK](https://img.shields.io/badge/Android%20SDK-6.4.2-brightgreen.svg)
77

88
[HyperTrack](https://www.hypertrack.com/) lets you add live location tracking to your mobile app. Live location is made available along with ongoing activity, tracking controls and tracking outage with reasons.
99

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"version": "1.0.1",
2+
"version": "1.0.2",
33
"name": "cordova-plugin-hypertrack-v3",
44
"cordova_name": "Cordova HyperTrack Plugin",
55
"description": "Cordova Plugin for native HyperTrack SDKs",

plugin.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<plugin xmlns="http://apache.org/cordova/ns/plugins/1.0"
33
xmlns:android="http://schemas.android.com/apk/res/android"
44
id="cordova-plugin-hypertrack-v3"
5-
version="1.0.0">
5+
version="1.0.2">
66
<name>HyperTrackPlugin</name>
77
<description>Cordova HyperTrack Plugin is a wrapper around native iOS and Android SDKs that allows to integrate HyperTrack into Cordova apps.</description>
88
<license>MIT</license>

src/android/HyperTrackPlugin.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ def ANDROID_FCM_VERSION = System.getenv('ANDROID_FCM_VERSION') ?: rootProject.ha
22
buildscript {
33

44
ext {
5-
HYPERTRACK_SDK_VERSION = '6.4.0'
5+
HYPERTRACK_SDK_VERSION = '6.4.2'
66
ANDROID_GRADLE_TOOLS_VERSION = System.getenv('ANDROID_GRADLE_TOOLS_VERSION') ?: rootProject.hasProperty('ANDROID_GRADLE_TOOLS_VERSION') ? rootProject.ext.ANDROID_GRADLE_TOOLS_VERSION : '3.5.3'
77
ANDROID_GOOGLE_SERVICES_VERSION = System.getenv('ANDROID_GOOGLE_SERVICES_VERSION') ?: rootProject.hasProperty('ANDROID_GOOGLE_SERVICES_VERSION') ? rootProject.ext.ANDROID_GOOGLE_SERVICES_VERSION : '4.3.3'
88
ext.gradleNumberVersion = ANDROID_GRADLE_TOOLS_VERSION.substring(0, ANDROID_GRADLE_TOOLS_VERSION.lastIndexOf(".")).toFloat()

0 commit comments

Comments
 (0)