-
-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathjekyll-build.mac.command
More file actions
executable file
·37 lines (27 loc) · 869 Bytes
/
jekyll-build.mac.command
File metadata and controls
executable file
·37 lines (27 loc) · 869 Bytes
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
#! /bin/bash
cd "$(dirname "$0")"
export PATH="$HOME/.local/homebrew/jekyll/bin":$PATH
site="../micro-os-plus.github.io.git"
# Be sure the 'vendor/' folder is excluded,
# otherwise a strage error occurs.
bundle exec jekyll build --destination "${site}"
export NOKOGIRI_USE_SYSTEM_LIBRARIES=true
# Temporarily move the `reference` folder out of the way, it is
# too large to be validated.
rm -rf "${site}-reference"
if [ -d "${site}/reference" ]
then
mv "${site}/reference" "${site}-reference"
fi
# --log-level debug \
# Validate images and links (internal & external).
bundle exec htmlproofer \
--url-ignore="/reference/cmsis-plus/,/pt/,https://www.element14.com/community/.*" \
"${site}"
# Bring back the `reference` folder, it is needed for deployment.
if [ -d "${site}-reference" ]
then
mv "${site}-reference" "${site}/reference"
fi
echo
echo "Done"