Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,8 @@ android {
applicationId 'com.pgarr.simplenotepad'
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
versionCode 13
versionName "1.1.1"
versionCode 19
versionName "1.4.2"

buildConfigField "String", "REACT_NATIVE_RELEASE_LEVEL", "\"${findProperty('reactNativeReleaseLevel') ?: 'stable'}\""
}
Expand Down
6 changes: 3 additions & 3 deletions app.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"expo": {
"name": "simple-notepad",
"slug": "simple-notepad",
"version": "1.4.1",
"version": "1.4.2",
"orientation": "portrait",
"icon": "./assets/images/icon.png",
"scheme": "simple-notepad",
Expand All @@ -24,7 +24,7 @@
"backgroundColor": "#ffffff"
},
"package": "com.pgarr.simplenotepad",
"versionCode": 18
"versionCode": 19
},
"web": {
"bundler": "metro",
Expand All @@ -43,7 +43,7 @@
"projectId": "9e3820b7-558b-4bd2-a1b2-e49561e741e6"
}
},
"runtimeVersion": "1.4.1",
"runtimeVersion": "1.4.2",
"updates": {
"url": "https://u.expo.dev/9e3820b7-558b-4bd2-a1b2-e49561e741e6"
}
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "simple-notepad",
"main": "expo-router/entry",
"version": "1.4.1",
"version": "1.4.2",
"scripts": {
"prebuild": "expo prebuild",
"dev": "expo start",
Expand Down
14 changes: 9 additions & 5 deletions scripts/bump-version.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,20 @@ TYPE=${1:-patch} # patch | minor | major
# Bump package.json and capture new version
NEW_VERSION=$(npm version $TYPE --no-git-tag-version | tr -d 'v')

# Sync app.json
node -e "
# Sync app.json and capture new versionCode
NEW_VERSION_CODE=$(node -e "
const fs = require('fs');
const app = JSON.parse(fs.readFileSync('app.json', 'utf8'));
app.expo.version = '$NEW_VERSION';
app.expo.runtimeVersion = '$NEW_VERSION';
app.expo.android = app.expo.android || {};
app.expo.android.versionCode = (app.expo.android.versionCode || 0) + 1;
const parts = '$NEW_VERSION'.split('.').map(Number);
fs.writeFileSync('app.json', JSON.stringify(app, null, 2) + '\n');
"
process.stdout.write(String(app.expo.android.versionCode));
")

echo "Bumped to $NEW_VERSION"
# Sync android/app/build.gradle (EAS reads this when a native android/ dir exists)
sed -i "s/versionCode [0-9]*/versionCode $NEW_VERSION_CODE/" android/app/build.gradle
sed -i "s/versionName \"[^\"]*\"/versionName \"$NEW_VERSION\"/" android/app/build.gradle

echo "Bumped to $NEW_VERSION (versionCode $NEW_VERSION_CODE)"
Loading