Add a conveninet shortcut to test kittens
This commit is contained in:
parent
805baad9cd
commit
9dc571d8a9
@ -31,6 +31,13 @@ def launch(args):
|
|||||||
runpy.run_path(args[1], run_name='__main__')
|
runpy.run_path(args[1], run_name='__main__')
|
||||||
|
|
||||||
|
|
||||||
|
def run_kitten(args):
|
||||||
|
import runpy
|
||||||
|
kitten = args[1]
|
||||||
|
sys.argv = args[1:]
|
||||||
|
runpy.run_module('kittens.{}.main'.format(kitten), run_name='__main__')
|
||||||
|
|
||||||
|
|
||||||
def namespaced(args):
|
def namespaced(args):
|
||||||
func = namespaced_entry_points[args[1]]
|
func = namespaced_entry_points[args[1]]
|
||||||
func(args[1:])
|
func(args[1:])
|
||||||
@ -42,6 +49,7 @@ entry_points = {
|
|||||||
'list-fonts': list_fonts,
|
'list-fonts': list_fonts,
|
||||||
'runpy': runpy,
|
'runpy': runpy,
|
||||||
'launch': launch,
|
'launch': launch,
|
||||||
|
'kitten': run_kitten,
|
||||||
|
|
||||||
'@': remote_control,
|
'@': remote_control,
|
||||||
'+': namespaced,
|
'+': namespaced,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user