Have you tried using sys.argv ? It usually contains the whole command line including the executable as sys.argv[0], but it seems that Leo startup code stripped that first argument from sys.argv. But it can replaced with sys.executable anyway. It seems that inside Leo sys.argv[0] is the python script that was used to start Leo.
Vitalije -- You received this message because you are subscribed to the Google Groups "leo-editor" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/leo-editor/8ef0407c-1443-4091-8157-0a4c1890b056%40googlegroups.com.
