forked from processing/processing-docs
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathprocessingrefBuild.sh
More file actions
executable file
·115 lines (95 loc) · 4.08 KB
/
processingrefBuild.sh
File metadata and controls
executable file
·115 lines (95 loc) · 4.08 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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
#!/bin/sh
echo "[REFERENCE GENERATOR] Booting up..."
# PROCESSING_SRC_PATH=./test
PROCESSING_SRC_PATH=../../../processing/core/src
PROCESSING_LIB_PATH=../../../processing/java/libraries
# GENERATE REFERENCE ENTRIES AND INDEX THROUGH JAVADOC - BY DAVID WICKS
echo "[REFERENCE GENERATOR] Source Path :: $PROCESSING_SRC_PATH"
echo "[REFERENCE GENERATOR] Library Path :: $PROCESSING_LIB_PATH"
echo "[REFERENCE GENERATOR] Removing previous version of the ref..."
rm -rf ../../reference
mkdir ../../reference
rm -rf ../../distribution
mkdir ../../distribution
echo "[REFERENCE GENERATOR] Generating new javadocs..."
javadoc -doclet ProcessingWeblet \
-docletpath bin/ \
-public \
-webref ../../reference \
-localref ../../distribution \
-templatedir ../templates \
-examplesdir ../../content/api_en \
-includedir ../../content/api_en/include \
-imagedir images \
-encoding UTF-8 \
-corepackage processing.data \
-corepackage processing.event \
-corepackage processing.opengl \
-rootclass PConstants \
$PROCESSING_SRC_PATH/processing/core/*.java \
$PROCESSING_SRC_PATH/processing/data/*.java \
$PROCESSING_SRC_PATH/processing/event/*.java \
$PROCESSING_SRC_PATH/processing/opengl/*.java \
$PROCESSING_LIB_PATH/io/src/processing/io/*.java \
$PROCESSING_LIB_PATH/net/src/processing/net/*.java \
$PROCESSING_LIB_PATH/serial/src/processing/serial/*.java \
$PROCESSING_LIB_PATH/../../../processing-video/src/processing/video/*.java \
$PROCESSING_LIB_PATH/../../../processing-sound/src/processing/sound/*.java \
-noisy
echo "[REFERENCE GENERATOR] Copying images from content directory to the correct location..."
echo "[REFERENCE GENERATOR] Updating web paths..."
cp -R ../../css ../../reference/
cp -R ../../javascript ../../reference/
mkdir -p ../../reference/images
cp -R ../../content/api_media/*.jpg ../../reference/images/
cp -R ../../content/api_media/*.gif ../../reference/images/
cp -R ../../content/api_media/*.png ../../reference/images/
echo "[REFERENCE GENERATOR] Updating local reference paths..."
cp -R ../../css ../../distribution/
cp -R ../../javascript ../../distribution/
rm -rf ../../distribution/css/fonts/TheSerif_B4_Bold_.eot
rm -rf ../../distribution/css/fonts/TheSerif_B4_Bold_.woff
rm -rf ../../distribution/css/fonts/TheSerif_B4_Italic.eot
rm -rf ../../distribution/css/fonts/TheSerif_B4_Italic.woff
rm -rf ../../distribution/css/fonts/TheSerif_B4_Plain_.eot
rm -rf ../../distribution/css/fonts/TheSerif_B4_Plain_.woff
mkdir -p ../../distribution/images
cp -R ../../content/api_media/*.jpg ../../distribution/images/
cp -R ../../content/api_media/*.gif ../../distribution/images/
cp -R ../../content/api_media/*.png ../../distribution/images/
# COPY IMAGES
echo "[REFERENCE GENERATOR] Copying images to web reference..."
# copy images for web reference isn't needed because they are already on server
# copy images for local reference
echo "[REFERENCE GENERATOR] Copying images to local reference..."
mkdir -p ../../distribution/img
chmod 755 ../../distribution/img
mkdir -p ../../distribution/img/about/
cp ../../favicon.ico ../../distribution/img/
cp ../../img/processing-web.png ../../distribution/img/
cp ../../img/processing-logo.svg ../../distribution/img/
cp ../../img/processing-logo.png ../../distribution/img/
cp ../../img/search.png ../../distribution/img/
cp ../../img/search.svg ../../distribution/img/
cp ../../img/about/people-header.gif ../../distribution/img/about/
cp ../../content/api_en/images/header.gif ../../distribution/img/
# GENERATE OTHER REFERENCE CONTENT
# move to folder for generating other files
cd ../../generate/
# run web reference creations files
echo "[REFERENCE GENERATOR] Running PHP to generate static files..."
php staticpages.php
php tools.php
php libraries.php
php environment.php
# run local reference creations files
php staticpages_local.php
php tools_local.php
php libraries_local.php
php environment_local.php
# add the links to load in the libraries and tools lists online
echo "[REFERENCE GENERATOR] Generating symlinks for web libraries and tools..."
cd ../reference/libraries/
ln -s index.html index.shtml
cd ../tools/
ln -s index.html index.shtml