import os class AppOpener: def open_app(self, app_name): os.system(f'open -a "{app_name}"') def close_app(self, app_name): os.system(f'killall "{app_name}"') def open_document(self, document_name): os.system(f'open "{document_name}"')