diff --git a/Cargo.toml b/Cargo.toml index 1afa923..aa64f97 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -11,6 +11,7 @@ homepage = "https://hllmn.net/projects/jotdown" repository = "https://github.com/hellux/jotdown" documentation = "https://docs.rs/jotdown" exclude = [ + "contrib", ".github", ".gitmodules", "Makefile", diff --git a/contrib/tag-release.sh b/contrib/tag-release.sh new file mode 100755 index 0000000..5723dc6 --- /dev/null +++ b/contrib/tag-release.sh @@ -0,0 +1,13 @@ +c_awk_latest=' +/^## \[.*\]/ {if (latest) exit; else {latest=1; next}} +latest {print} +' + +tag=$(grep ^version Cargo.toml | cut -d" " -f3 | tr -d '"') +changes=$(awk "$c_awk_latest" CHANGELOG.md | tail -n+2) + +git -c core.commentchar='%' tag --edit \ + -m "Release $tag" \ + -m "$changes" \ + "$tag" +git push github master "$tag"