You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sometimes people merge new templates into the development branches and do not create new releases. Hence, the new template version only resides in the development branch.
However, when cloning the repository in the automatic sync the new version is compared against the master branch, which may still have the old template version. Despite the new version already being merged into the development branch annoying sync pushes occur.
I suggest 2 things:
blacklist changelog.rst as @sven1103 already suggested.
Adapt sync.py to something like
def has_template_version_changed(self, project_dir: Path) -> (bool, bool, bool, str, str):
"""
Check, if the mlf-core template has been updated since last check/sync of the user.
:return: Both false if no versions changed or a micro change happened (for ex. 1.2.3 to 1.2.4). Return is_major_update True if a major version release
happened for the mlf-core template (for example 1.2.3 to 2.0.0). Return is_minor_update True if a minor change happened (1.2.3 to 1.3.0).
Return is_patch_update True if its a micro update (for example 1.2.3 to 1.2.4).
mlf-core will use this to decide which syncing strategy to apply. Also return both versions.
"""
# Try to compare against the development branch, since it is the most up to date (usually).
# If a development branch does not exist compare against master.
repo = git.Repo(self.project_dir)
try:
repo.git.checkout('development')
except git.exc.GitCommandError:
print('[bold red]Could not checkout development branch. Trying to checkout master...')
try:
repo.git.checkout('master')
except git.exc.GitCommandError as e:
print(f'[bold red]Could not checkout master branch.\n{e}')
sys.exit(1)
As a result when syncing the version will be checked against the development branch.
Cheers
The text was updated successfully, but these errors were encountered:
Sometimes people merge new templates into the development branches and do not create new releases. Hence, the new template version only resides in the development branch.
However, when cloning the repository in the automatic sync the new version is compared against the master branch, which may still have the old template version. Despite the new version already being merged into the development branch annoying sync pushes occur.
I suggest 2 things:
As a result when syncing the version will be checked against the development branch.
Cheers
The text was updated successfully, but these errors were encountered: