Comments (5)
Hi Cedric,
Getting crazy with prereleases here!!
Trying to generate a lodash template to generate Android/iOS versionCode/buildNumber that include prerelease info has been unsuccesfull so far.
Tons of test showed me that the SemVer 'next' variable in templates does not contain prerelease info at all.
A template like
ios: "${next} / ${next.version} / ${next.raw} / ${next.build.length} / ${next.prerelease.length}"
generates
1.0.0 / 1.0.0 / 1.0.0 / 0 / 0
the strange thing is that 'recommended' generates "1.0.0-alpha.33" or so
For ios I've been able to extract the prerelease info right from the 'recommended' string (with some regexp), but for android that is an integer with no prerelease info of any kind.
PLEASE HELP!!
from semantic-release-expo.
Hi @byCedric,
I would be also happy to have the prerelease info available for the Android version to be able to construct a different number.
I see that @AlbertoLopSie made a PR which replaces semver.coerce
(#188).
Another possibility is to replace semver.coerce
with semver.parse
(and optionally semver.clean
):
--- current version (semver.coerce)
+++ semver.clean + semver.parse
@@ -2,11 +2,11 @@
options: {},
loose: false,
includePrerelease: false,
- raw: '1.66.18',
+ raw: '1.66.18-alpha.6',
major: 1,
minor: 66,
patch: 18,
- prerelease: [],
+ prerelease: [ 'alpha', 6 ],
build: [],
- version: '1.66.18'
+ version: '1.66.18-alpha.6'
}
As @AlbertoLopSie said, currently it is impossible to generate a new Android version number when only the prerelase part changes, because the prerelease info is not present in any of the available variables.
from semantic-release-expo.
Also, the following lines of the README are untrue:
recommended version - The "raw" next release version (also available in `${next.raw}`)
recommended iOS buildNumber - The "raw" next release version (also available in `${next.raw}`)
because recommended
is not coerce
d, so in the case of e.g. "1.66.18-alpha.6", recommended
is "1.66.18-alpha.6"
but next.raw
is "1.66.18"
from semantic-release-expo.
@byCedric Is there any chance this is going to be fixed? The fix may be as easy as replacing semver.coerce
with semver.parse
(see #185 (comment))
from semantic-release-expo.
Any update on this? Facing the same issue and having this resolved would remove such a headache.
from semantic-release-expo.
Related Issues (20)
- Readme Feedback HOT 2
- Update library for usage with new manifest format HOT 2
- [Android]: "recommended" strategy defaults versionCode to 0 HOT 3
- add support for app.config.js manifest HOT 8
- 2.2.3 does not update android.buildNumber, how can this plugin take care of my android versions? HOT 1
- Error: Cannot find module '@semantic-release/error' HOT 1
- Plugin overwrites keys outside of `expo` HOT 1
- An in-range update of @commitlint/travis-cli is breaking the build 🚨 HOT 2
- An in-range update of @types/fs-extra is breaking the build 🚨 HOT 2
- An in-range update of codecov is breaking the build 🚨 HOT 2
- An in-range update of @types/lodash is breaking the build 🚨 HOT 2
- An in-range update of @types/jest is breaking the build 🚨 HOT 4
- An in-range update of @types/node is breaking the build 🚨 HOT 17
- An in-range update of @types/jest is breaking the build 🚨 HOT 3
- An in-range update of ts-jest is breaking the build 🚨 HOT 2
- An in-range update of codecov is breaking the build 🚨 HOT 2
- An in-range update of @types/node is breaking the build 🚨 HOT 5
- GitHub action HOT 2
- An in-range update of @peakfijn/config-commitlint is breaking the build 🚨 HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from semantic-release-expo.