Skip to content

Commit

Permalink
Bump version number to 1.3.4
Browse files Browse the repository at this point in the history
  • Loading branch information
maurerle committed Sep 20, 2022
1 parent bce3a48 commit b7f662d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 10 deletions.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "eralchemy2"
version = "1.3.3"
version = "1.3.4"
description = "Simple entity relation (ER) diagrams generation"
authors = ["Florian Maurer <fmaurer@disroot.org>"]
license = "Apache License 2.0"
Expand Down
16 changes: 7 additions & 9 deletions script/make_release.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from subprocess import PIPE, Popen

# inspired by https://github.com/mitsuhiko/flask/blob/master/scripts/make-release.py

from poetry.poetry import Poetry

def set_filename_version(filename, version_number):
with open(filename, "w+") as f:
Expand Down Expand Up @@ -81,11 +81,8 @@ def parse_args():


def get_current_version():
with open("eralchemy2/version.py") as f:
lines = f.readlines()
namespace = {}
exec(lines[0], namespace)
return version_str_to_lst(namespace["version"])
from importlib.metadata import version
return version_str_to_lst(version("eralchemy2"))


def get_git_tags():
Expand All @@ -104,6 +101,7 @@ def get_next_version(major, minor, fix, current_version):

def main():
os.chdir(os.path.join(os.path.dirname(__file__), ".."))
Popen(["poetry", "install"]).wait()
current_version = get_current_version()
major, minor, fix = parse_args()
next_version = get_next_version(major, minor, fix, current_version)
Expand All @@ -113,10 +111,10 @@ def main():
if next_version_str in tags:
fail('Version "%s" is already tagged', next_version_str)

if not git_is_clean():
fail("You have uncommitted changes in git")
#if not git_is_clean():
# fail("You have uncommitted changes in git")

set_init_version(next_version_str)
Popen(["poetry", "version", next_version_str]).wait()
make_git_commit("Bump version number to %s", next_version_str)
make_git_tag("v" + next_version_str)
build_and_upload()
Expand Down

0 comments on commit b7f662d

Please sign in to comment.