-
Notifications
You must be signed in to change notification settings - Fork 11
/
Makefile
49 lines (40 loc) · 1.09 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
#!/usr/bin/make
#
lo_version="7.3"
args = $(filter-out $@,$(MAKECMDGOALS))
all: run
py:=3.9
.PHONY: bootstrap buildout run test cleanall startlibreoffice stoplibreoffice
bootstrap:
virtualenv -p python$(py) .
bin/pip install -r requirements.txt
buildout:
if ! test -f bin/buildout;then make bootstrap;fi
bin/buildout -Nt 5
run:
if ! test -f bin/instance;then make buildout;fi
mkdir -p var/tmp
make startlibreoffice
bin/instance fg
test:
if ! test -f bin/test;then make buildout;fi
make startlibreoffice
rm -fr htmlcov
bin/translation-manage -c
if test -z "$(args)" ;then bin/test;else bin/test -t $(args);fi
make stoplibreoffice
cleanall:
rm -fr bin develop-eggs devel htmlcov include .installed.cfg lib .mr.developer.cfg parts downloads eggs local
startlibreoffice:
make stoplibreoffice
docker run -p 2002:2002\
-d \
--rm \
--pull always \
--name="oo_server" \
-v /tmp:/tmp \
-v /var/tmp:/var/tmp \
harbor.imio.be/library/libreoffice:$(lo_version)
docker ps
stoplibreoffice:
if docker ps | grep oo_server;then docker stop oo_server;fi