You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+12-8Lines changed: 12 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -49,6 +49,8 @@ react-native-version will then update your `android/` and `ios/` code. Depending
49
49
50
50
```shell
51
51
npm install -g react-native-version
52
+
# or
53
+
yarn global add react-native-version
52
54
```
53
55
54
56
### Example usage
@@ -65,13 +67,14 @@ react-native-version
65
67
-h, --help output usage information
66
68
-V, --version output the version number
67
69
-a, --amend Amend the previous commit. Also updates the latest Git tag to point to the amended commit. This is done automatically when react-native-version is run from the "version" or "postversion" npm script. Use "--never-amend" if you never want to amend.
68
-
--skip-tag For use with "--amend" if you don't want to update Git tags
69
-
-A, --never-amend Never amend the previous commit
70
-
-b, --increment-build Only increment build number
71
-
-d, --android [path] Path to your "android/app/build.gradle" file
72
-
-i, --ios [path] Path to your "ios/" folder
73
-
-r, --reset-build Reset build number back to "1" (iOS only). Unlike Android's "versionCode", iOS doesn't require you to bump the "CFBundleVersion", as long as "CFBundleShortVersionString" changes. To make it consistent across platforms, react-native-version bumps both by default. You can use this option if you prefer to reset the build number after every version change. If you then need to push another build under the same version, you can use "-bt ios".
74
-
-t, --target <platforms> Only version specified platforms, eg. "--target android,ios"
70
+
--skip-tag For use with "--amend", if you don't want to update Git tags.
71
+
-A, --never-amend Never amend the previous commit.
72
+
-b, --increment-build Only increment build number.
73
+
-d, --android [path] Path to your "android/app/build.gradle" file.
74
+
-i, --ios [path] Path to your "ios/" folder.
75
+
-q, --quiet Be quiet, only report errors.
76
+
-r, --reset-build Reset build number back to "1" (iOS only). Unlike Android's "versionCode", iOS doesn't require you to bump the "CFBundleVersion", as long as "CFBundleShortVersionString" changes. To make it consistent across platforms, react-native-version bumps both by default. You can use this option if you prefer to keep the build number value at "1" after every version change. If you then need to push another build under the same version, you can use "-bt ios" to increment.
77
+
-t, --target <platforms> Only version specified platforms, eg. "--target android,ios".
75
78
```
76
79
77
80
You can apply these options to the "version" or "postversion" script too. If for example you want to commit the changes made by RNV yourself, add the "--never-amend" option:
.option('-a, --amend','Amend the previous commit. Also updates the latest Git tag to point to the amended commit. This is done automatically when '+pkg.name+' is run from the "version" or "postversion" npm script. Use "--never-amend" if you never want to amend.')
14
-
.option('--skip-tag','For use with "--amend" if you don\'t want to update Git tags')
15
-
.option('-A, --never-amend','Never amend the previous commit')
.option('-d, --android [path]','Path to your "android/app/build.gradle" file',defaults.android)
18
-
.option('-i, --ios [path]','Path to your "ios/" folder',defaults.ios)
19
-
.option('-r, --reset-build','Reset build number back to "1" (iOS only). Unlike Android\'s "versionCode", iOS doesn\'t require you to bump the "CFBundleVersion", as long as "CFBundleShortVersionString" changes. To make it consistent across platforms, '+pkg.name+' bumps both by default. You can use this option if you prefer to reset the build number after every version change. If you then need to push another build under the same version, you can use "-bt ios".')
20
-
.option('-t, --target <platforms>','Only version specified platforms, eg. "--target android,ios"',list)
16
+
.option('--skip-tag','For use with "--amend", if you don\'t want to update Git tags.')
17
+
.option('-A, --never-amend','Never amend the previous commit.')
.option('-d, --android [path]','Path to your "android/app/build.gradle" file.',defaults.android)
20
+
.option('-i, --ios [path]','Path to your "ios/" folder.',defaults.ios)
21
+
.option('-q, --quiet','Be quiet, only report errors.')
22
+
.option('-r, --reset-build','Reset build number back to "1" (iOS only). Unlike Android\'s "versionCode", iOS doesn\'t require you to bump the "CFBundleVersion", as long as "CFBundleShortVersionString" changes. To make it consistent across platforms, '+pkg.name+' bumps both by default. You can use this option if you prefer to keep the build number value at "1" after every version change. If you then need to push another build under the same version, you can use "-bt ios" to increment.')
23
+
.option('-t, --target <platforms>','Only version specified platforms, eg. "--target android,ios".',list)
0 commit comments