Skip to content

Commit 8c32db1

Browse files
Merge pull request #5 from dfreeman/optional-app-version
Allow users to opt out of `appVersion`
2 parents 23080ce + 49a1763 commit 8c32db1

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@ Set in [`config/deploy.js`](http://ember-cli-deploy.com/docs/v1.0.x/configuratio
6969
| `distFiles` | array of strings | No | `context.distFiles` | The array of built project files. This option should be relative to `distDir`. By default, this option will use the `distFiles` property of the [deployment context](http://ember-cli-deploy.com/docs/v0.5.x/deployment-context/). |
7070
| `overwrite` | string | No | `true` | If set to `false`, existing sourcemaps for the same version of your app will not be overwritten. Options are `true` or `false`. |
7171
| `publicUrl` | string | Yes | `<none>` | The fully qualified domain name for your application e.g., `https://app.fancy-app.com` |
72+
| `includeAppVersion` | boolean | No | `true` | Whether to tag the uploaded sourcemaps as belonging to a particular app version. |
7273

7374
#### Related plugin options
7475

index.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ module.exports = {
2929
return process.env.SOURCE_VERSION || '';
3030
}
3131
},
32+
includeAppVersion: true,
3233
deleteSourcemaps: true,
3334
overwrite: 'true',
3435
},
@@ -43,6 +44,7 @@ module.exports = {
4344
var distFiles = this.readConfig('distFiles');
4445
var publicUrl = this.readConfig('publicUrl');
4546
var overwrite = this.readConfig('overwrite');
47+
var includeAppVersion = this.readConfig('includeAppVersion');
4648
var promises = [];
4749
var jsFilePaths = fetchFilePaths(distFiles, publicUrl, 'js');
4850
var mapFilePaths = fetchFilePaths(distFiles, distDir, 'map');
@@ -57,7 +59,7 @@ module.exports = {
5759
minifiedUrl: jsFilePath,
5860
sourceMap: fs.createReadStream(mapFilePath)
5961
};
60-
if (revisionKey) {
62+
if (revisionKey && includeAppVersion) {
6163
formData.appVersion = revisionKey;
6264
}
6365
var promise = request({

0 commit comments

Comments
 (0)