(project_path)
| 10 | |
| 11 | |
| 12 | def download_web_files(project_path): |
| 13 | print('Downloading web files...') |
| 14 | |
| 15 | from io import BytesIO |
| 16 | from zipfile import ZipFile |
| 17 | from urllib.request import urlopen |
| 18 | |
| 19 | response = urlopen('https://github.com/bugy/script-server/releases/download/dev/script-server.zip') |
| 20 | with ZipFile(BytesIO(response.read())) as zipfile: |
| 21 | for file in zipfile.namelist(): |
| 22 | if file.startswith('web/'): |
| 23 | zipfile.extract(file, project_path) |
| 24 | |
| 25 | print('Done') |
| 26 | |
| 27 | |
| 28 | def build_web_files(project_path): |