diff options
| author | Cliff Click <cliffc@acm.org> | 2026-09-22 11:25:05 -0700 |
|---|---|---|
| committer | Cliff Click <cliffc@acm.org> | 2026-09-22 11:25:05 -0700 |
| commit | 29fb671e69f90ad3b04c6fa8d746caf857f89e77 (patch) | |
| tree | 2f39d082f8a6de6a2b60b66406f8c9f0190d25c2 /graph/graph.mk | |
| parent | 1d961838cff168a101069d08a8ab6594f49f0911 (diff) | |
| download | Simple-29fb671e69f90ad3b04c6fa8d746caf857f89e77.tar.gz Simple-29fb671e69f90ad3b04c6fa8d746caf857f89e77.zip | |
Add shared graph viewer to all chapters
Diffstat (limited to 'graph/graph.mk')
| -rw-r--r-- | graph/graph.mk | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/graph/graph.mk b/graph/graph.mk new file mode 100644 index 00000000..1d5eb95a --- /dev/null +++ b/graph/graph.mk @@ -0,0 +1,11 @@ +# Include after defining chapter source variables. Works in linearized checkouts too. +GRAPH_DIR := $(patsubst %/,%,$(dir $(lastword $(MAKEFILE_LIST)))) +graph_javas := $(wildcard $(GRAPH_DIR)/src/main/java/com/seaofnodes/graph/*.java) +main_javas += $(graph_javas) + +# Defining view here must not change the chapter's default target. +graph_goal := $(.DEFAULT_GOAL) +.PHONY: view +view: build + java -ea -cp "$(CLZDIR)/main" com.seaofnodes.simple.print.SimpleGraphObserver +.DEFAULT_GOAL := $(graph_goal) |
