props/MultiShop/scripts/watch_all.py
Harrison Deng 3d3c43b944 Began transition to Vue3.
Implemented logging in and logging out.

Implemented authenticated http client.

Laid some groundwork for SCSS.
2021-07-10 12:29:34 -05:00

30 lines
648 B
Python

import os
import asyncio
import sys
SERVER_CSPROJ_DIR = "server"
CLIENT_PACKAGE_DIR = "client"
async def exec(cmd, path):
os.chdir(os.path.dirname(os.path.realpath(__file__)))
os.chdir(os.pardir)
os.chdir(path)
print("Executing \"{0}\" in \"{1}\".".format(cmd, path))
proc = await asyncio.create_subprocess_shell(
cmd,
stdout=sys.stdout,
stderr=sys.stderr,
)
await proc.wait()
async def main():
print("Beginning development servers.")
await asyncio.gather(
exec("dotnet watch run", SERVER_CSPROJ_DIR),
exec("npm run serve", CLIENT_PACKAGE_DIR))
asyncio.run(main())