Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions src/sinol_make/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,17 +109,18 @@ def main():
'https://github.com/sio2project/sinol-make/#reporting-bugs-and-contributing-code')
finally:
if new_version is not None:
install_method = 'pipx' if util.is_probably_installed_by_pipx() else 'pip'
install_method = 'pipx upgrade sinol-make' if util.is_probably_installed_by_pipx() \
else 'pip install sinol-make --upgrade'
if not util.is_dev(new_version):
print(util.warning(
f'New version of sinol-make is available (your version: {__version__}, available version: '
f'{new_version}).\n'
f'Changelog can be found at https://github.com/sio2project/sinol-make/releases.\n'
f'You can update sinol-make by running `{install_method} install sinol-make --upgrade`.'))
f'You can update sinol-make by running `{install_method}`.'))
elif util.is_dev(new_version):
print(util.warning(
f'New development version of sinol-make is available (your version: {__version__}, available '
f'version: {new_version}).\n'
f'Changelog can be found at https://github.com/sio2project/sinol-make/releases.\n'
f'You can update sinol-make by running `{install_method} install sinol-make --pre --upgrade`.'
f'You can update sinol-make by running `{install_method} --pre`.'
))
Loading