Note about __main__.py with +launch

This commit is contained in:
Kovid Goyal 2022-05-31 07:56:01 +05:30
parent 2a361d1de1
commit 135818f34b
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -66,7 +66,8 @@ def launch(args: List[str]) -> None:
raise SystemExit( raise SystemExit(
'usage: kitty +launch script.py [arguments to be passed to script.py ...]\n\n' 'usage: kitty +launch script.py [arguments to be passed to script.py ...]\n\n'
'script.py will be run with full access to kitty code. If script.py is ' 'script.py will be run with full access to kitty code. If script.py is '
'prefixed with a : it will be searched for in PATH' 'prefixed with a : it will be searched for in PATH. If script.py is a directory '
'the __main__.py file inside it is run just as with the normal Python interpreter.'
) )
if exe.startswith(':'): if exe.startswith(':'):
import shutil import shutil