From c08e0b6fde17d041c9bfe8ce06b0071ba849c6cc Mon Sep 17 00:00:00 2001 From: Nemo Date: Thu, 31 Jan 2019 15:31:32 +0530 Subject: [PATCH] Switch to relative paths so it works without docker as well --- README.md | 2 +- bootstrap.sh | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index edf609d..dbd93dd 100644 --- a/README.md +++ b/README.md @@ -39,7 +39,7 @@ Requirements: - Ruby - `gem install bundler` -- `gem install nokogiri` +- `bundle install` - `brew install pandoc` - `brew cask install calibre` - `brew install wget` diff --git a/bootstrap.sh b/bootstrap.sh index c94246e..2aa6b78 100755 --- a/bootstrap.sh +++ b/bootstrap.sh @@ -39,7 +39,7 @@ fi # Add extension to files. # That because `pandoc` cannot generate the right `mime type` without the extension. # https://github.com/captn3m0/google-sre-ebook/issues/19 -IMGS_FILES="$(ls /src/html/${IMGS_DOMAIN}/*)" +IMGS_FILES="$(ls html/${IMGS_DOMAIN}/*)" for FILE_NAME_FULL in ${IMGS_FILES}; do # Get file vars. @@ -52,8 +52,8 @@ for FILE_NAME_FULL in ${IMGS_FILES}; do done -ruby generate.rb -pushd html/landing.google.com/sre/${BOOK_FILE}/toc +bundle exec ruby generate.rb +pushd html/landing.google.com/sre/${BOOK_NAME}/toc pandoc --from=html --to=epub \ --output=../../../../../${BOOK_FILE}.epub \ --epub-metadata=../../../../../${BOOK_NAME}.xml \