-
Notifications
You must be signed in to change notification settings - Fork 2
/
Makefile
31 lines (24 loc) · 905 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
MDPATH?=../massdriver
CLIPATH?=../cli
all: sync-cli-docs sync-gql-docs sync-authz-docs
.PHONY: sync-gql-docs
sync-gql-docs: # Generate GraphQL docs
rm -rf ./docs/swapi/{directives,inputs,objects,scalars,subscriptions,unions,enums,mutations,queries}
cd ${MDPATH} && mix absinthe.schema.sdl
mv ${MDPATH}/schema.graphql ./schema/md.graphql
npx docusaurus graphql-to-doc
.PHONY: yarn
yarn:
docker run --rm -it -v ${PWD}:/app -w /app -p 3001:3000 node:19-alpine3.16 yarn install
.PHONY: build
build:
docker run --rm -it -v ${PWD}:/app -w /app -p 3001:3000 node:19-alpine3.16 yarn build
.PHONY: dev
dev:
docker run --rm -it -v ${PWD}:/app -w /app -p 3001:3000 node:19-alpine3.16 yarn start
.PHONY: sync-cli-docs
sync-cli-docs: # Generate CLI docs
rsync -a ${CLIPATH}/cmd/helpdocs/ ./docs/cli/
.PHONY: sync-authz-docs
sync-authz-docs:
cp ${MDPATH}/adrs/0013* ./docs/security/02-authorization.md