Alex Dunmow 96b87b3e81 initial: theme plugin scifi-clean
Bootstrapped during the 2026-06-06 BlockNinja consolidation. Was previously
an unversioned directory inside ~/src/blockninja-themes/scifi-clean.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-06-06 14:11:43 +08:00

32 lines
951 B
Makefile

# Sci-Fi Clean — build helpers (.so plugin workflow)
#
# Local-only targets. `make` produces scifi-clean.so via CGO go build -buildmode=plugin.
# `make rebuild` deploys to the live CMS container and is intentionally NOT defined here
# in this implementation pass — see gotham/Makefile if/when you want to add it.
.PHONY: all clean templ help
PLUGIN_NAME := scifi-clean
TEMPL := $(HOME)/go/bin/templ
# Default target: build the .so locally.
all: $(PLUGIN_NAME).so
# Local plugin build (no container).
$(PLUGIN_NAME).so: $(wildcard *.go) plugin.mod go.mod
CGO_ENABLED=1 go build -buildmode=plugin -ldflags="-s -w" -o $(PLUGIN_NAME).so .
# Regenerate templ Go files locally.
templ:
$(TEMPL) generate
# Remove build artefacts.
clean:
rm -f $(PLUGIN_NAME).so
help:
@echo "Targets:"
@echo " all Build $(PLUGIN_NAME).so locally (default)"
@echo " templ Regenerate templ Go files locally"
@echo " clean Remove built .so"