typescript-action
typescript-action copied to clipboard
Release script fails if no latest release tag exists
I ran into the issue that the release script fails after step 6. Tag a new release
if no latest release tag exists:
fatal: No names found, cannot describe anything.
No tags found (yet) - Continue to create and push your first tag
The latest release tag is: [unknown]
Enter a new release tag (vX.X.X format): v1.0.0
Tag: v1.0.0 is valid syntax
Make sure the version field in package.json is v1.0.0. Yes? [Y/n] y
Tagged: v1.0.0
This seems to be caused by
# 7. Set 'is_major_release' variable
latest_major_release_tag=$(expr "$latest_tag" : "$major_semver_tag_regex")
which fails with exit code 1 if latest_tag
contains [unknown]
.