-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathMakefile
More file actions
54 lines (45 loc) · 1.34 KB
/
Makefile
File metadata and controls
54 lines (45 loc) · 1.34 KB
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
# The submodule path
MATHQUILL = ./vendor/mathquill_custom/
# All of the built assets are in the build folder
MATHQUILL_BUILD = ./vendor/mathquill_custom/build
# All of the files that are moved into the main project
RES = ./tinymce/
RES_JS = ${RES}/js/mathquill.min.js
RES_CSS = ${RES}/css/mathquill.css
RES_FONT = ${RES}/css/font
# Deploy file name
DEPLOY_NAME = matheditor.zip
all: ${RES_JS} ${RES_CSS} ${RES_FONT}
# Copy the JS file
${RES_JS}: ${MATHQUILL_BUILD}/mathquill.js
cp ${MATHQUILL_BUILD}/mathquill.min.js ${RES_JS}
# Copy the CSS file
${RES_CSS}: ${MATHQUILL_BUILD}/mathquill.css
cp ${MATHQUILL_BUILD}/mathquill.css ${RES_CSS}
# Copy the fonts
${RES_FONT}: ${MATHQUILL_BUILD}/font
cp -r ${MATHQUILL_BUILD}/font ${RES_FONT}
# Build dependency, watches the src folder for changes
${MATHQUILL_BUILD}/mathquill.js: ${MATHQUILL}/src/css/* ${MATHQUILL}/src/*
make -C ${MATHQUILL}
# Creates a zip file ready for deployment
deploy:
make clean
make all
mkdir matheditor
cp -r lang matheditor
cp -r pix matheditor
cp -r tinymce matheditor
cp -r lib.php matheditor
cp -r matheditor.php matheditor
cp -r all_strings.php matheditor
cp -r version.php matheditor
zip -r ${DEPLOY_NAME} matheditor
rm -f -r matheditor
clean:
make -C ${MATHQUILL} clean
rm -f ${RES_JS}
rm -f ${RES_CSS}
rm -f -r ${RES}/css/font
rm -f ${DEPLOY_NAME}
rm -f -r temp