...
Python scripts that are written as an extension can be run directly from the button, or the Settings / Run GX... menu item, or by specifying the name of the script with .py extension as an ITEM entry in an omn file (see Oasis montaj Menus).
The Python Tutorial for Geosoft GX Developer provides an overview of Python with lessons that demonstrate how to create extensions (see Hello World#DesktopExtension), and how to add an extension to a menu (see Create a Menu to Run Python Extensions).
...