Add helper scripts for building and testing all packages

This commit is contained in:
Lucas Dower 2023-10-10 20:01:55 +01:00
parent 06a915d3b7
commit 87facde6eb
6 changed files with 50 additions and 2 deletions

13
.github/workflows/build_sandbox.js.yml vendored Normal file
View File

@ -0,0 +1,13 @@
name: Build-Sandbox
on: push
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install modules
working-directory: ./Sandbox
run: npm ci
- name: Run build
working-directory: ./Sandbox
run: npm run build

13
.github/workflows/tests_sandbox.js.yml vendored Normal file
View File

@ -0,0 +1,13 @@
name: Tests-Sandbox
on: push
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install modules
working-directory: ./Sandbox
run: npm ci
- name: Run tests
working-directory: ./Sandbox
run: npm test

View File

@ -8,7 +8,8 @@
"test": "tests" "test": "tests"
}, },
"scripts": { "scripts": {
"test": "echo \"Error: no test specified\" && exit 1" "build": "echo \"Nothing to build\" && exit 0",
"test": "echo \"No tests\" && exit 0"
}, },
"keywords": [], "keywords": [],
"author": "", "author": "",

View File

@ -5,7 +5,8 @@
"description": "", "description": "",
"main": "index.js", "main": "index.js",
"scripts": { "scripts": {
"test": "echo \"Error: no test specified\" && exit 1" "build": "echo \"Nothing to build\" && exit 0",
"test": "echo \"No tests\" && exit 0"
}, },
"keywords": [], "keywords": [],
"author": "", "author": "",

10
build_all.sh Executable file
View File

@ -0,0 +1,10 @@
#!/bin/sh
echo "Building Core..."
npm run build --prefix Core
echo "Building Editor..."
npm run build --prefix Editor
echo "Building Sandbox..."
npm run build --prefix Sandbox

10
test_all.sh Executable file
View File

@ -0,0 +1,10 @@
#!/bin/sh
echo "Testing Core..."
npm run test --prefix Core
echo "Testing Editor..."
npm run test --prefix Editor
echo "Testing Sandbox..."
npm run test --prefix Sandbox