Skip to content

Commit

Permalink
prepare next release
Browse files Browse the repository at this point in the history
  • Loading branch information
AlCalzone committed Mar 15, 2018
1 parent 9b758b7 commit cc0d66e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -502,7 +502,7 @@ A DeviceInfo object contains general information about a device. It has the foll

## Changelog

#### NEXT:
#### 0.10.0 (2018-03-15)
* (AlCalzone) Swallow `"CoapClient was reset"` promise rejections and emit an `"error"` instead
* (AlCalzone) Avoid sending `5712: null` in payloads when a group's transition time is `null` for some reason

Expand Down
7 changes: 4 additions & 3 deletions maintenance/release.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,16 @@ function fail(reason: string) {
const gitStatus = execSync("git status", {cwd: rootDir, encoding: "utf8"});
if (/have diverged/.test(gitStatus)) {
if (!argv.dry) fail(colors.red("Cannot continue, the local branch has diverged from the git repo!"));
else console.log(colors.yellow("This is a dry run. The full run would fail due to a diverged branch\n"));
else console.log(colors.red("This is a dry run. The full run would fail due to a diverged branch\n"));
} else if (!/working tree clean/.test(gitStatus)) {
if (!argv.dry) fail(colors.red("Cannot continue, the local branch has uncommited changes!"));
else console.log(colors.yellow("This is a dry run. The full run would fail due to uncommited changes\n"));
else console.log(colors.red("This is a dry run. The full run would fail due to uncommited changes\n"));
} else if (/Your branch is behind/.test(gitStatus)) {
if (!argv.dry) fail(colors.red("Cannot continue, the local branch is behind the remote changes!"));
else console.log(colors.yellow("This is a dry run. The full run would fail due to the local branch being behind\n"));
else console.log(colors.red("This is a dry run. The full run would fail due to the local branch being behind\n"));
} else if (/Your branch is up\-to\-date/.test(gitStatus) || /Your branch is ahead/.test(gitStatus)) {
// all good
console.log(colors.green("git status is good - I can continue..."));
}

const releaseTypes = ["major", "premajor", "minor", "preminor", "patch", "prepatch", "prerelease"];
Expand Down

0 comments on commit cc0d66e

Please sign in to comment.