Commit 92d2920c authored by Rafael Monnerat's avatar Rafael Monnerat

slapos.package: Use do_upgrade and not main

 This was a legacy when it was used as script directly
parent 19f30348
......@@ -29,7 +29,7 @@ setup(name=name,
'console_scripts': [
# Those entry points are development version and
# self updatable API
'slappkg-update-raw = slapos.package.update:main',
'slappkg-update-raw = slapos.package.update:do_update',
'slappkg-discover-raw = slapos.package.distribution:do_discover',
'slappkg-upload-key-raw = slapos.package.upload_key:main',
'slappkg-update = slapos.package.autoupdate:do_update',
......
......@@ -164,7 +164,7 @@ class Upgrader:
"""
self.checkConsistency(fixit=not self.config.dry_run)
def main():
def do_update():
"""Update computer and slapos"""
usage = "usage: %s [options] " % sys.argv[0]
# Parse arguments
......@@ -172,5 +172,3 @@ def main():
upgrader.run()
sys.exit()
if __name__ == '__main__':
main()
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment