diff options
Diffstat (limited to 'Makefile')
| -rw-r--r-- | Makefile | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..4512b74 --- /dev/null +++ b/Makefile @@ -0,0 +1,20 @@ +NAME := mktypst +VERSION := 0.1.0 + +ifeq ($(shell uname),Darwin) +DATADIR := $(HOME)/Library/Application Support +else +DATADIR := $(if $(XDG_DATA_HOME),$(XDG_DATA_HOME),$(HOME)/.local/share) +endif + +PKGDIR := $(DATADIR)/typst/packages/local/$(NAME)/$(VERSION) + +install: + mkdir -p "$(PKGDIR)" + cp typst.toml lib.typ README.md LICENSE "$(PKGDIR)"/ + cp -r templates "$(PKGDIR)"/ + +uninstall: + rm -rf "$(DATADIR)/typst/packages/local/$(NAME)/$(VERSION)" + +.PHONY: install uninstall |
