-
-
Notifications
You must be signed in to change notification settings - Fork 5.8k
/
Makefile
71 lines (59 loc) ยท 1.94 KB
/
Makefile
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
clean: ## Clean
rm -rf dist
rm -rf build
rm -rf *.egg-info
build: clean ## Build PIPy Package
python setup.py sdist bdist_wheel
check-content: build ## List contents of PIPy Package
tar -tvf dist/*.tar.gz
check: build ## Check PIPy Package
twine check dist/*
upload: build ## Upload PIPy Package
twine upload dist/*
install: ## Install from repo
pip install -e .
uninstall: ## Uninstall
pip uninstall labml_nn
docs-si: ## Sinhalese Translation
rm -rf docs/si
mv docs/zh docs_zh
mv docs/ja docs_ja
cp -r docs docs_si
mv docs_si docs/si
mv docs_zh docs/zh
mv docs_ja docs/ja
cd labml_nn; pylit --translate si --translate_cache ../translate_cache --remove_empty_sections --title_md -t ../../../pylit/templates/nn -d ../docs/si -w *
docs-zh: ## Chinese Translation
rm -rf docs/zh
mv docs/si docs_si
mv docs/ja docs_ja
cp -r docs docs_zh
mv docs_si docs/si
mv docs_zh docs/zh
mv docs_ja docs/ja
cd labml_nn; pylit --translate zh --translate_cache ../translate_cache --remove_empty_sections --title_md -t ../../../pylit/templates/nn -d ../docs/zh -w *
docs-ja: ## Japanese Translation
rm -rf docs/ja
mv docs/si docs_si
mv docs/zh docs_zh
cp -r docs docs_ja
mv docs_si docs/si
mv docs_zh docs/zh
mv docs_ja docs/ja
cd labml_nn; pylit --translate ja --translate_cache ../translate_cache --remove_empty_sections --title_md -t ../../../pylit/templates/nn -d ../docs/ja -w *
docs: ## Render annotated HTML
mv docs/zh docs_zh
mv docs/si docs_si
mv docs/ja docs_ja
find ./docs/ -name "*.html" -type f -delete
find ./docs/ -name "*.svg" -type f -delete
mv docs_si docs/si
mv docs_zh docs/zh
mv docs_ja docs/ja
python utils/sitemap.py
python utils/diagrams.py
cd labml_nn; pylit --remove_empty_sections --title_md -t ../../../pylit/templates/nn -d ../docs -w *
help: ## Show this help.
@fgrep -h "##" $(MAKEFILE_LIST) | fgrep -v fgrep | sed -e 's/\\$$//' | sed -e 's/##//'
.PHONY: clean build check upload help docs
.DEFAULT_GOAL := help