Skip to content

Commit

Permalink
Use SENTRY_FILE_PREFIX in 'gulp sentry:release'
Browse files Browse the repository at this point in the history
  • Loading branch information
beheh committed Sep 3, 2016
1 parent 51064cf commit feae441
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ gulp.task("sentry:release", ["env:set-release"], function (cb) {
throw Error("Sentry Token not found (expected environment variable " + key + ")");
}
var sentry = new Sentry({token: token});
var prefix = process.env.SENTRY_FILE_PREFIX ? process.env.SENTRY_FILE_PREFIX : "";

sentry.releases.create("hearthsim", "joust", {
version: version,
Expand All @@ -116,7 +117,7 @@ gulp.task("sentry:release", ["env:set-release"], function (cb) {
var files = ["dist/joust.css", "dist/joust.css.map", "dist/joust.js", "dist/joust.js.map"];
var uploads = files.map(function (file) {
return sentry.releases.createFile("hearthsim", "joust", version, {
name: path.basename(file),
name: prefix + path.basename(file),
file: fs.createReadStream(file)
}).then(function (newFile) {
gutil.log("Uploaded", gutil.colors.green(newFile.name), "to Sentry");
Expand Down

0 comments on commit feae441

Please sign in to comment.