Skip to content

Commit d7c9e0a

Browse files
committed
devops: remove ruby installation part from local scripts. Future work
to support RVM installation is required.
1 parent d8effe6 commit d7c9e0a

File tree

5 files changed

+17
-13
lines changed

5 files changed

+17
-13
lines changed

TODO.md

+3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
- devops: install.sh needs to rewritten to install ruby using RVM or
2+
rbenv.
3+
14
- feature: encode email to svg graph.
25

36
- optimize: handle newline in Chinese text converted to a space when

scripts/build.sh

+3-3
Original file line numberDiff line numberDiff line change
@@ -6,17 +6,17 @@ _DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
66
ROOT_DIR="${_DIR}/.."
77

88
## Load library functions
9-
. ${_DIR}/lib.sh
9+
# . ${_DIR}/lib.sh
1010

1111
## Changed the current directory to the project root directory
1212
pushd "${ROOT_DIR}" > /dev/null
1313

1414
## Add bundle binary executable to PATH (onetime)
15-
add_gems_user_dir_to_path
15+
# add_gems_user_dir_to_path
1616

1717
## Build the site
1818
bundle exec jekyll build
19-
bundle exec htmlproofer --enforce-https=false --ignore-urls '/www.linkedin.com/' "${ROOT_DIR}"/_site
19+
bundle exec htmlproofer --ignore-urls '/www.flaticon.com/,/www.linkedin.com/' "${ROOT_DIR}"/_site
2020

2121
## Go back to the original directory
2222
popd > /dev/null

scripts/clean.sh

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,13 @@ _DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
66
ROOT_DIR="${_DIR}/.."
77

88
## Load library functions
9-
. ${_DIR}/lib.sh
9+
# . ${_DIR}/lib.sh
1010

1111
## Changed the current directory to the project root directory
1212
pushd "${ROOT_DIR}" > /dev/null
1313

1414
## Add bundle binary executable to PATH (onetime)
15-
add_gems_user_dir_to_path
15+
# add_gems_user_dir_to_path
1616

1717
## Clean
1818
bundle exec jekyll clean

scripts/install.sh

+7-6
Original file line numberDiff line numberDiff line change
@@ -6,24 +6,25 @@ _DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
66
ROOT_DIR="${_DIR}/.."
77

88
## Load library functions
9-
. ${_DIR}/lib.sh
9+
# . ${_DIR}/lib.sh
1010

1111
## Changed the current directory to the project root directory
1212
pushd "${ROOT_DIR}" > /dev/null
1313

14+
# TODO: install ruby!
1415
## Install dependent packages on Ubuntu if they don't exist
15-
declare -a PKGS=("ruby-full" "build-essential" "zlib1g-dev")
16-
for pkg in "${PKGS[@]}"; do
17-
dpkg -s "${pkg}" > /dev/null || sudo apt install "${pkg}"
18-
done
16+
# declare -a PKGS=("ruby-full" "build-essential" "zlib1g-dev")
17+
# for pkg in "${PKGS[@]}"; do
18+
# dpkg -s "${pkg}" > /dev/null || sudo apt install "${pkg}"
19+
# done
1920

2021
## Uncomment the following line if you are behind the GFW
2122
# gem sources --add https://gems.ruby-china.com/ --remove https://rubygems.org/
2223
## Install bundler
2324
gem install bundler
2425

2526
## Add bundle binary executable to PATH (onetime)
26-
add_gems_user_dir_to_path
27+
# add_gems_user_dir_to_path
2728

2829
## Uncomment the following line if you are behind the GFW
2930
# bundle config mirror.https://rubygems.org https://gems.ruby-china.com

scripts/serve.sh

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,13 @@ _DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
66
ROOT_DIR="${_DIR}/.."
77

88
## Load library functions
9-
. ${_DIR}/lib.sh
9+
# . ${_DIR}/lib.sh
1010

1111
## Changed the current directory to the project root directory
1212
pushd "${ROOT_DIR}" > /dev/null
1313

1414
## Add bundle binary executable to PATH (onetime)
15-
add_gems_user_dir_to_path
15+
# add_gems_user_dir_to_path
1616

1717
## Start a local server
1818
bundle exec jekyll serve

0 commit comments

Comments
 (0)