previous_version is an object, not a string
This commit is contained in:
parent
0d1fca8dbb
commit
4f84450979
@ -6,7 +6,7 @@ import { simpleGit } from "simple-git";
|
|||||||
|
|
||||||
const code_churn = async (previous_version) => {
|
const code_churn = async (previous_version) => {
|
||||||
previous_version = previous_version
|
previous_version = previous_version
|
||||||
? "v" + previous_version
|
? "v" + previous_version.version
|
||||||
: "4b825dc642cb6eb9a060e54bf8d69288fbee4904"; // empty tree sha1
|
: "4b825dc642cb6eb9a060e54bf8d69288fbee4904"; // empty tree sha1
|
||||||
|
|
||||||
return simpleGit().diff(["--shortstat", previous_version, "HEAD"]);
|
return simpleGit().diff(["--shortstat", previous_version, "HEAD"]);
|
||||||
@ -47,7 +47,10 @@ const handler = async (config) => {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
next.version = semverInc(previous_version ?? "0.0.0", bumper);
|
next.version = semverInc(
|
||||||
|
previous_version ? previous_version.version : "0.0.0",
|
||||||
|
bumper
|
||||||
|
);
|
||||||
|
|
||||||
if (config.dry) {
|
if (config.dry) {
|
||||||
config.consola.info("running in dry mode, not saving\n", next);
|
config.consola.info("running in dry mode, not saving\n", next);
|
||||||
|
Loading…
Reference in New Issue
Block a user