-
Notifications
You must be signed in to change notification settings - Fork 22
/
Makefile
23 lines (18 loc) · 1008 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
MKDOCS_ROOT := $(dir $(abspath $(lastword $(MAKEFILE_LIST))))
SITE_DIR := $(MKDOCS_ROOT)/site
COMMIT_ID := $(shell git rev-parse --short HEAD)
NEWEST_TAG := $(shell git describe --tags --abbrev=0)
CNAME := docs.abci.ai
build:
mkdocs build --config-file $(MKDOCS_ROOT)/root/mkdocs.yml --site-dir $(SITE_DIR)
mkdocs build --config-file $(MKDOCS_ROOT)/ja/mkdocs.yml --site-dir $(SITE_DIR)/ja/
mkdocs build --config-file $(MKDOCS_ROOT)/en/mkdocs.yml --site-dir $(SITE_DIR)/en/
mkdocs build --config-file $(MKDOCS_ROOT)/portal/root/mkdocs.yml --site-dir $(SITE_DIR)/portal/
mkdocs build --config-file $(MKDOCS_ROOT)/portal/ja/mkdocs.yml --site-dir $(SITE_DIR)/portal/ja/
mkdocs build --config-file $(MKDOCS_ROOT)/portal/en/mkdocs.yml --site-dir $(SITE_DIR)/portal/en/
publish-head:
ghp-import -m "deploy $(COMMIT_ID)" -c $(CNAME) -r origin -b gh-pages -p site
publish:
ghp-import -m "deploy tag $(NEWEST_TAG)" -c $(CNAME) -r origin -b gh-pages -p site
clean:
rm -rf $(SITE_DIR)