Mac app generator
Project description
Install
$ [sudo] pip install mac-app
Classes
mac_app.App
Mac app generator
method | description |
---|---|
appify() |
create Mac app |
atexit() |
executed at termination. override this method |
mkalias(dst) |
make Mac alias to app |
run() |
main function. you MUST override this method |
sleep(seconds) |
suspend app for the given number of seconds |
@property | description |
---|---|
app_image |
app image. default is mdfind kMDItemFSName=<name>.png result |
app_name |
app name. default is class name |
app_path |
app path. default is ~/Applications/.appify/<name>.app |
app_script |
source script path. default is class module file |
app_stderr |
stderr path. default is ~/Library/Logs/Applications/<name>/err.log |
app_stdout |
stdout path. default is ~/Library/Logs/Applications/<name>/out.log |
Examples
create app from python file
>>> mac_app.App(app_script="file.py", app_name="name").appify().mkalias("~/name.app")
create app from class
>>> import mac_app
>>> class MyApp(mac_app.App):
def run(self):
pass
if __name__ == "__main__":
MyApp().run()
>>> MyApp().appify().mkalias("~/MyApp.app")
readme-md - README.md generator
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
mac-app-2018.11.20.tar.gz
(3.2 kB
view hashes)
Built Distribution
Close
Hashes for mac_app-2018.11.20-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ec1f7ff33b2268d73804c748ee9b0b5b717305c740f4edd076c7166e39ebcb5b |
|
MD5 | 4a85ac6c112d39e90a98fe0079293e50 |
|
BLAKE2b-256 | 85d447993357c50b3f51991156cd6839304632c382d1d7d0935689b38034bbac |