Skip to content

Latest commit

 

History

History
23 lines (16 loc) · 367 Bytes

README.md

File metadata and controls

23 lines (16 loc) · 367 Bytes

Launchy

from launchy import Launchy
import asyncio

launchy = Launchy("ls -l --color")

loop = asyncio.get_event_loop()
Launchy.attach_loop(loop)

async def main():
    # start subprocess
    await launchy.launch()

    # wait until subprocess exits
    await launchy.wait()

    # terminate
    await Launchy.stop()

loop.run_until_complete(main())