.PHONY: check run test clean help

NODE ?= node
JS_LOAD = import { Aip56 } from './aip56.mjs'; const aip56 = await Aip56.selfContained()

check:
	$(NODE) --input-type=module -e "$(JS_LOAD); console.log('AIP-56 ECMAScript validation: OK')"

run:
	$(NODE) --input-type=module -e "$(JS_LOAD); console.log(aip56.generate())"

test: check

clean:
	@echo "No ECMAScript build artifacts to remove."

help:
	@printf '%s\n' \
		'make check     Validate the embedded compressed payload with the ES module' \
		'make run       Generate one phrase using Node only as an ES-module runner' \
		'make test      Run the validation check' \
		'make clean     Remove generated temporary files' \
		'make help      Show these targets'
