-
Notifications
You must be signed in to change notification settings - Fork 9
/
BuildAppledoc.sh
executable file
·48 lines (34 loc) · 1.38 KB
/
BuildAppledoc.sh
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
#!/bin/bash
LAUNCH_DIR=$PWD
APPLEDOC_EXE=$(which appledoc)
if [ -z "$APPLEDOC_EXE" ]; then
APPLEDOC_EXE=/usr/local/bin/appledoc
fi
PROJECT_ROOT=$PWD
DEPLOYMENT_DIR=${PROJECT_ROOT}/deployment
SDK_LIBRARIES_ROOT=${PROJECT_ROOT}/CsvToSqlite
if [ -d "$DEPLOYMENT_DIR" ]; then
rm -rf "$DEPLOYMENT_DIR"
fi
mkdir -p "$DEPLOYMENT_DIR"
cd "$DEPLOYMENT_DIR"
which appledoc
${APPLEDOC_EXE} \
--project-name "CsvToSqlite" \
--project-company "dodikk" \
--company-id org.dodikk \
--no-repeat-first-par \
--ignore $SDK_LIBRARIES_ROOT/Detail \
--ignore $SDK_LIBRARIES_ROOT/LineReaders \
--ignore $SDK_LIBRARIES_ROOT/CsvMacros.h \
--ignore $SDK_LIBRARIES_ROOT/CsvColumnsParser.h \
--ignore $SDK_LIBRARIES_ROOT/DBTableValidator.h \
--ignore $SDK_LIBRARIES_ROOT/StreamUtils.h \
--output . \
"$SDK_LIBRARIES_ROOT" \
| tee appledoc-log.txt
DOCUMENTATION_PATH=$( cat docset-installed.txt | grep Path: | awk 'BEGIN { FS = " " } ; { print $2 }' )
echo DOCUMENTATION_PATH - $DOCUMENTATION_PATH
cp -R "${DOCUMENTATION_PATH}" .
find . -name "*.docset" -exec zip -r CsvToSqlite-doc.zip {} \; -print
cd "$LAUNCH_DIR"