summaryrefslogtreecommitdiff
path: root/Makefile
blob: a3240e4ba51b652b485657e12c90a04812f4cf9b (plain)
1
2
3
4
5
6
7
8
9
10
11
wrk-dir := $(shell pwd)
dst-dir := $(CRX_DST_DIR)
pem-dir := $(CRX_PEM_DIR)

ext-name := $(shell basename $(wrk-dir))

$(dst-dir)/$(ext-name).crx: manifest.json
	@echo ID: $(shell openssl rsa -pubout -outform DER -in $(pem-dir)/$(ext-name).pem 2>/dev/null | sha256sum | head -c32 | tr 0-9a-f a-p)
	@cd ..
	@crx3 -p $(pem-dir)/$(ext-name).pem -o $@ $(wrk-dir)