File: Makefile

package info (click to toggle)
golang-github-tdewolff-minify 2.20.37-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 39,388 kB
  • sloc: javascript: 394,644; xml: 25,649; ansic: 253; makefile: 108; python: 108; sh: 47
file content (27 lines) | stat: -rw-r--r-- 524 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
SHELL=/usr/bin/env bash
VERSION=`git describe --tags --abbrev=0 | cut -b 2-`

all: build

compile:
	# called from workflow
	sed -i.bak -e "s/{VERSION}/${VERSION}/" setup.py
	go build -buildmode=c-shared -o src/minify/minify.so

build: compile
	go mod init github.com/tdewolff/minify/bindings/js
	go mod tidy
	python -m build --sdist
	mv setup.py.bak setup.py
	rm -rf go.*

publish: clean build
	twine upload dist/*

clean:
	rm -rf dist
	rm -rf tdewolff_minify.egg-info
	rm -rf go.*

.PHONY: all compile build publish clean