react-native-bspatch 3.1.0 → 3.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-native-bspatch",
3
- "version": "3.1.0",
3
+ "version": "3.1.1",
4
4
  "description": "Premium OTA Update Solution for React Native using TurboModules and bsdiff",
5
5
  "main": "lib/commonjs/index.js",
6
6
  "module": "lib/module/index.js",
@@ -6,7 +6,7 @@
6
6
  // - package.json ("version")
7
7
  // - android/app/build.gradle (versionName & increments versionCode)
8
8
  // - ios/*.xcodeproj/project.pbxproj (MARKETING_VERSION & increments CURRENT_PROJECT_VERSION)
9
- // - src/ota/otaConfig.ts (APP_VERSION, if it exists)
9
+ // JS reads the native version at runtime (getAppVersion); never hardcode it in source.
10
10
  //
11
11
  // Usage:
12
12
  // node bump_version.js <new_version> [--root <path>]
@@ -118,16 +118,4 @@ if (fs.existsSync(iosDir)) {
118
118
  }
119
119
  }
120
120
 
121
- // 4. src/ota/otaConfig.ts (if exists)
122
- const otaConfigPath = path.join(rootDir, 'src/ota/otaConfig.ts');
123
- if (fs.existsSync(otaConfigPath)) {
124
- try {
125
- let content = fs.readFileSync(otaConfigPath, 'utf8');
126
- content = content.replace(/export const APP_VERSION = ['"][^'"]+['"];/, `export const APP_VERSION = '${newVersion}';`);
127
- fs.writeFileSync(otaConfigPath, content, 'utf8');
128
- console.log(` ✓ src/ota/otaConfig.ts: APP_VERSION → '${newVersion}'`);
129
- changedCount++;
130
- } catch (e) {}
131
- }
132
-
133
121
  console.log(`\n✓ Done! Updated ${changedCount} file(s) to version ${newVersion}.\n`);