#!/usr/bin/env python3
# runner.py
# Located in the top-level grub-wiz directory

import runpy

# Execute the main module of the package.
# This mimics the behavior of the 'python -m grub_wiz.main' command.
# This assumes your main execution logic (run_cli()/main()) is in
# grub_wiz/main.py
if __name__ == '__main__':
    # ``alter_sys=True`` makes runpy install the module as __main__ and set
    # sys.argv[0] to its file path, so assigning sys.argv[0] here would be
    # immediately overwritten.
    runpy.run_module('grub_wiz.main', run_name='__main__', alter_sys=True)
