@sentry/craft 2.1.1 → 2.2.0

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.
Files changed (3) hide show
  1. package/README.md +61 -2
  2. package/dist/craft +2 -2
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -112,6 +112,66 @@ Options:
112
112
  -h, --help Show help [boolean]
113
113
  ```
114
114
 
115
+
116
+ ### Version naming conventions
117
+
118
+ Craft currently supports [semantic versioning (semver)](https://semver.org)-like versions for the `NEW-VERSION` argument passed to its `prepare` and `publish` commands. This means, releases made with craft need to follow a general pattern as follows:
119
+
120
+ ```txt
121
+ <major>.<minor>.<patch>(-<prerelease>)?(-<build>)?
122
+ ```
123
+
124
+ - The `<major>`, `<minor>` and `<patch>` numbers are required
125
+ - The `<prerelease>` and `<build>` identifiers are optional
126
+
127
+ #### Preview releases (`<prerelease>`)
128
+
129
+ Preview or pre-release identifiers **must** include one of the following identifiers
130
+
131
+ ```txt
132
+ preview|pre|rc|dev|alpha|beta|unstable|a|b
133
+ ```
134
+
135
+ and may additionally include incremental pre-release version numbers.
136
+ Adding identifiers other than the ones listed above result in Craft either rejecting the release (if not parse-able) or the release being treated by individual targets as a stable release.
137
+
138
+ Examples:
139
+
140
+ ```txt
141
+ 1.0.0-preview
142
+ 1.0.0-alpha.0
143
+ 1.0.0-beta.1
144
+ 1.0.0-rc.20
145
+ 1.0.0-a
146
+
147
+ // invalid or incorrectly treated
148
+ 1.0.0-foo
149
+ 1.0.0-canary.0
150
+ ```
151
+
152
+ #### Special Case: Python Post Releases
153
+
154
+
155
+ Python has the concept of post releases, which craft handles implicitly. A post release is indicated by a `-\d+` suffix to the semver version, for example: `1.0.0-1`.
156
+ Given that we only consider certain identifiers as [pre-releases](#preview-releases-prerelease), post releases are considered stable releases.
157
+
158
+ ### Build identifiers (`<build>`)
159
+
160
+ Craft supports adding a build identifier to your version, for example if you release the same package version for different platforms or architectures.
161
+ You can also combine build and pre-release identifiers but in this case, the pre-release identifier has to come first.
162
+
163
+ Examples:
164
+
165
+ ```txt
166
+ // valid
167
+ 1.0.0+x86_64
168
+ 1.0.0-rc.1+x86_64
169
+
170
+ // invalid or incorrectly treated
171
+ 1.0.0+rc.1+x86_64
172
+ 1.0.0+x86_64-beta.0
173
+ ```
174
+
115
175
  ## Caveats
116
176
 
117
177
  - When interacting with remote GitHub repositories, `craft` uses the
@@ -519,8 +579,7 @@ changelog. Otherwise, defaults to the tag name and tag's commit message.
519
579
 
520
580
  If `previewReleases` is set to `true` (which is the default), the release
521
581
  created on GitHub will be marked as a pre-release version if the release name
522
- contains any one of `preview`, `pre`, `rc`, `dev`,`alpha`, `beta`, `unstable`,
523
- `a`, or `b`.
582
+ contains any one of [pre-release identifiers](#preview-releases-prerelease).
524
583
 
525
584
  **Environment**
526
585