mirror of
https://github.com/mjl-/mox.git
synced 2024-12-25 07:53:47 +03:00
automatically install typescript into ./node_modules if missing during build
simplifies process.
This commit is contained in:
parent
d9f5625a89
commit
fece75cfe7
3 changed files with 7 additions and 7 deletions
1
.github/workflows/build-test.yml
vendored
1
.github/workflows/build-test.yml
vendored
|
@ -17,7 +17,6 @@ jobs:
|
|||
with:
|
||||
node-version: 16
|
||||
cache: 'npm'
|
||||
- run: npm ci
|
||||
- run: 'touch */*.ts'
|
||||
|
||||
- uses: actions/setup-go@v4
|
||||
|
|
6
Makefile
6
Makefile
|
@ -110,10 +110,12 @@ fmt:
|
|||
tswatch:
|
||||
bash -c 'while true; do inotifywait -q -e close_write *.ts webadmin/*.ts webaccount/*.ts webmail/*.ts; make frontend; done'
|
||||
|
||||
install-js:
|
||||
node_modules/.bin/tsc:
|
||||
-mkdir -p node_modules/.bin
|
||||
npm ci
|
||||
|
||||
install-js: node_modules/.bin/tsc
|
||||
|
||||
install-js0:
|
||||
-mkdir -p node_modules/.bin
|
||||
npm install --save-dev --save-exact typescript@5.1.6
|
||||
|
@ -133,7 +135,7 @@ webadmin/admin.js: lib.ts webadmin/api.ts webadmin/admin.ts
|
|||
webaccount/account.js: lib.ts webaccount/api.ts webaccount/account.ts
|
||||
./tsc.sh $@ $^
|
||||
|
||||
frontend: webadmin/admin.js webaccount/account.js webmail/webmail.js webmail/msg.js webmail/text.js
|
||||
frontend: node_modules/.bin/tsc webadmin/admin.js webaccount/account.js webmail/webmail.js webmail/msg.js webmail/text.js
|
||||
|
||||
install-apidiff:
|
||||
go install golang.org/x/exp/cmd/apidiff@v0.0.0-20231206192017-f3f8817b8deb
|
||||
|
|
|
@ -3,10 +3,9 @@ This file has notes useful for mox developers.
|
|||
# Building & testing
|
||||
|
||||
For a full build, you'll need a recent Go compiler/toolchain and nodejs/npm for
|
||||
the frontend. First install frontend dependencies (typescript) with "make
|
||||
install-js". Then run "make build" to do a full build. Run "make test" to run
|
||||
the test suite. With docker installed, you can run "make test-integration" to
|
||||
start up a few mox instances, a dns server, a postfix instance, and send email
|
||||
the frontend. Run "make build" to do a full build. Run "make test" to run the
|
||||
test suite. With docker installed, you can run "make test-integration" to start
|
||||
up a few mox instances, a dns server, a postfix instance, and send email
|
||||
between them.
|
||||
|
||||
The mox localserve command is a convenient way to test locally. Most of the
|
||||
|
|
Loading…
Reference in a new issue