@@ -387,14 +387,24 @@ $(foreach chart,$(charts),build/$(chart)_helm_$(VERSION).tgz): build/%_helm_$(VE
387
387
--chart $* \
388
388
--output " $@ "
389
389
390
- site/out/index.html : site/package.json $(shell find ./site $(FIND_EXCLUSIONS ) -type f \( -name '* .ts' -o -name '* .tsx' \) )
390
+ node_modules/.installed : package.json
391
+ ./scripts/pnpm_install.sh
392
+
393
+ offlinedocs/node_modules/.installed : offlinedocs/package.json
394
+ cd offlinedocs
395
+ ../scripts/pnpm_install.sh
396
+
397
+ site/node_modules/.installed : site/package.json
398
+ cd site
399
+ ../scripts/pnpm_install.sh
400
+
401
+ site/out/index.html : site/package.json site/node_modules/.installed $(shell find ./site $(FIND_EXCLUSIONS ) -type f \( -name '* .ts' -o -name '* .tsx' \) )
391
402
cd site
392
403
# prevents this directory from getting to big, and causing "too much data" errors
393
404
rm -rf out/assets/
394
- ../scripts/pnpm_install.sh
395
405
pnpm build
396
406
397
- offlinedocs/out/index.html : $(shell find ./offlinedocs $(FIND_EXCLUSIONS ) -type f) $(shell find ./docs $(FIND_EXCLUSIONS ) -type f | sed 's: :\\ :g')
407
+ offlinedocs/out/index.html : offlinedocs/node_modules/.installed $(shell find ./offlinedocs $(FIND_EXCLUSIONS ) -type f) $(shell find ./docs $(FIND_EXCLUSIONS ) -type f | sed 's: :\\ :g')
398
408
cd offlinedocs
399
409
../scripts/pnpm_install.sh
400
410
pnpm export
@@ -425,7 +435,7 @@ fmt/go:
425
435
go run mvdan.cc/
[email protected] -w -l
.
426
436
.PHONY : fmt/go
427
437
428
- fmt/ts :
438
+ fmt/ts : site/node_modules/.installed
429
439
echo " $( GREEN) ==>$( RESET) $( BOLD) fmt/ts$( RESET) "
430
440
cd site
431
441
# Avoid writing files in CI to reduce file write activity
@@ -468,7 +478,7 @@ lint/site-icons:
468
478
./scripts/check_site_icons.sh
469
479
.PHONY : lint/site-icons
470
480
471
- lint/ts :
481
+ lint/ts : site/node_modules/.installed
472
482
cd site
473
483
pnpm lint
474
484
.PHONY : lint/ts
@@ -643,14 +653,12 @@ site/src/api/typesGenerated.ts: $(wildcard scripts/apitypings/*) $(shell find ./
643
653
# -C sets the directory for the go run command
644
654
go run -C ./scripts/apitypings main.go > $@
645
655
646
- site/e2e/provisionerGenerated.ts : provisionerd/proto/provisionerd.pb.go provisionersdk/proto/provisioner.pb.go
656
+ site/e2e/provisionerGenerated.ts : site/node_modules/.installed provisionerd/proto/provisionerd.pb.go provisionersdk/proto/provisioner.pb.go
647
657
cd site
648
- ../scripts/pnpm_install.sh
649
658
pnpm run gen:provisioner
650
659
651
- site/src/theme/icons.json : $(wildcard scripts/gensite/* ) $(wildcard site/static/icon/* )
660
+ site/src/theme/icons.json : site/node_modules/.installed $(wildcard scripts/gensite/* ) $(wildcard site/static/icon/* )
652
661
go run ./scripts/gensite/ -icons " $@ "
653
- ./scripts/pnpm_install.sh
654
662
pnpm -C site/ exec biome format --write src/theme/icons.json
655
663
656
664
examples/examples.gen.json : scripts/examplegen/main.go examples/examples.go $(shell find ./examples/templates)
@@ -674,24 +682,20 @@ site/src/api/rbacresourcesGenerated.ts: scripts/typegen/codersdk.gotmpl scripts/
674
682
site/src/api/countriesGenerated.ts : scripts/typegen/countries.tstmpl scripts/typegen/main.go codersdk/countries.go
675
683
go run scripts/typegen/main.go countries > " $@ "
676
684
677
- docs/admin/integrations/prometheus.md : scripts/metricsdocgen/main.go scripts/metricsdocgen/metrics
685
+ docs/admin/integrations/prometheus.md : node_modules/.installed scripts/metricsdocgen/main.go scripts/metricsdocgen/metrics
678
686
go run scripts/metricsdocgen/main.go
679
- ./scripts/pnpm_install.sh
680
687
pnpm exec prettier --write ./docs/admin/integrations/prometheus.md
681
688
682
- docs/reference/cli/index.md : scripts/clidocgen/main.go examples/examples.gen.json $(GO_SRC_FILES )
689
+ docs/reference/cli/index.md : node_modules/.installed scripts/clidocgen/main.go examples/examples.gen.json $(GO_SRC_FILES )
683
690
CI=true BASE_PATH=" ." go run ./scripts/clidocgen
684
- ./scripts/pnpm_install.sh
685
691
pnpm exec prettier --write ./docs/reference/cli/index.md ./docs/reference/cli/* .md ./docs/manifest.json
686
692
687
- docs/admin/security/audit-logs.md : coderd/database/querier.go scripts/auditdocgen/main.go enterprise/audit/table.go coderd/rbac/object_gen.go
693
+ docs/admin/security/audit-logs.md : node_modules/.installed coderd/database/querier.go scripts/auditdocgen/main.go enterprise/audit/table.go coderd/rbac/object_gen.go
688
694
go run scripts/auditdocgen/main.go
689
- ./scripts/pnpm_install.sh
690
695
pnpm exec prettier --write ./docs/admin/security/audit-logs.md
691
696
692
- coderd/apidoc/swagger.json : $(shell find ./scripts/apidocgen $(FIND_EXCLUSIONS ) -type f) $(wildcard coderd/* .go) $(wildcard enterprise/coderd/* .go) $(wildcard codersdk/* .go) $(wildcard enterprise/wsproxy/wsproxysdk/* .go) $(DB_GEN_FILES ) .swaggo docs/manifest.json coderd/rbac/object_gen.go
697
+ coderd/apidoc/swagger.json : node_modules/.installed $(shell find ./scripts/apidocgen $(FIND_EXCLUSIONS ) -type f) $(wildcard coderd/* .go) $(wildcard enterprise/coderd/* .go) $(wildcard codersdk/* .go) $(wildcard enterprise/wsproxy/wsproxysdk/* .go) $(DB_GEN_FILES ) .swaggo docs/manifest.json coderd/rbac/object_gen.go
693
698
./scripts/apidocgen/generate.sh
694
- ./scripts/pnpm_install.sh
695
699
pnpm exec prettier --write ./docs/reference/api ./docs/manifest.json ./coderd/apidoc/swagger.json
696
700
697
701
update-golden-files : \
@@ -874,5 +878,5 @@ test-clean:
874
878
.PHONY : test-clean
875
879
876
880
.PHONY : test-e2e
877
- test-e2e :
881
+ test-e2e : site/node_modules/.installed
878
882
cd ./site && DEBUG=pw:api pnpm playwright:test --forbid-only --workers 1
0 commit comments