diff --git a/.github/scripts/install_dependencies.sh b/.github/scripts/install_dependencies.sh index 637a1f8..a1ba77b 100755 --- a/.github/scripts/install_dependencies.sh +++ b/.github/scripts/install_dependencies.sh @@ -3,25 +3,37 @@ set -Eeuo pipefail mkdir -p target +is_installed () { + dpkg-query -l "$1" | grep '^ii' >/dev/null +} + echo "Installing JRE..." -sudo apt-get update -sudo apt-get install -y default-jre libegl1 libopengl0 libxcb-cursor0 +if ! ((is_installed default-jre || is_installed default-jre-headless) \ + && is_installed libegl1 && is_installed libopengl0 && is_installed libxcb-cursor0); then + sudo apt-get update + sudo apt-get install -y default-jre libegl1 libopengl0 libxcb-cursor0 +fi echo "Installing Calibre..." -wget -nv -O- https://download.calibre-ebook.com/linux-installer.sh | sudo sh /dev/stdin +is_installed calibre || (wget -nv -O- https://download.calibre-ebook.com/linux-installer.sh | sudo sh /dev/stdin) echo "Downloading epubcheck..." curl -L "https://github.com/w3c/epubcheck/releases/download/v$EPUBCHECK_VERSION/epubcheck-$EPUBCHECK_VERSION.zip" -o "target/epubcheck-$EPUBCHECK_VERSION.zip" unzip -o "./target/epubcheck-$EPUBCHECK_VERSION.zip" -d "./target" mv "./target/epubcheck-$EPUBCHECK_VERSION" "./target/epubcheck" -echo "Downloading EB Garamond..." -curl -L "https://github.com/octaviopardo/EBGaramond12/archive/refs/heads/master.zip" -o "target/EB_Garamond.zip" -unzip -o "./target/EB_Garamond.zip" -d "./target/EB_Garamond" +EBGARAMOND_FONT_DIR="/usr/share/fonts/truetype/custom/EB_Garamond" +if [ -d "$EBGARAMOND_FONT_DIR" ]; then + echo "EB Garamond font already installed" +else + echo "Downloading EB Garamond..." + curl -L "https://github.com/octaviopardo/EBGaramond12/archive/refs/heads/master.zip" -o "target/EB_Garamond.zip" + unzip -o "./target/EB_Garamond.zip" -d "./target/EB_Garamond" -# echo "Installing EB Garamond..." -mkdir -p "/usr/share/fonts/truetype/custom/EB_Garamond" -find "./target/EB_Garamond" -name "*.ttf" -exec mv '{}' "/usr/share/fonts/truetype/custom/EB_Garamond" \; -fc-cache -f -v + echo "Installing EB Garamond..." + mkdir -p "$EBGARAMOND_FONT_DIR" + find "./target/EB_Garamond" -name "*.ttf" -exec mv '{}' "$EBGARAMOND_FONT_DIR" \; + fc-cache -f -v +fi echo "Done." diff --git a/src/OEBPS/Chapter10.xhtml b/src/OEBPS/Chapter10.xhtml index da8ca04..7469025 100644 --- a/src/OEBPS/Chapter10.xhtml +++ b/src/OEBPS/Chapter10.xhtml @@ -9,6 +9,7 @@
It was with great reluctance that Harry returned to Number Four, Privet Drive. He was really tempted to just take the Knight Bus back to Diagon Alley and get a room at the Leaky Cauldron. On the other hand, there were still people out there, not to mention Voldemort, who’d like nothing more than his head on a stick. The wards around the Dursley home would keep him safe, at least from outsiders.
diff --git a/src/OEBPS/Chapter12.xhtml b/src/OEBPS/Chapter12.xhtml index 75584f8..4144568 100644 --- a/src/OEBPS/Chapter12.xhtml +++ b/src/OEBPS/Chapter12.xhtml @@ -9,6 +9,7 @@When Harry awoke, he was asked to drink several potions in quick succession. The fact that he could now safely drink normal restorative potions would accelerate his recovery, Healer Stanhope informed him cheerfully.
diff --git a/src/OEBPS/Chapter13.xhtml b/src/OEBPS/Chapter13.xhtml index 8b5805b..31ca219 100644 --- a/src/OEBPS/Chapter13.xhtml +++ b/src/OEBPS/Chapter13.xhtml @@ -9,6 +9,7 @@Hermione Granger was a clever girl.
diff --git a/src/OEBPS/Chapter14.xhtml b/src/OEBPS/Chapter14.xhtml index 364d39c..16c10fe 100644 --- a/src/OEBPS/Chapter14.xhtml +++ b/src/OEBPS/Chapter14.xhtml @@ -9,6 +9,7 @@Hedwig returned before they retired for the night. Goldfarb was noncommittal in his reply, but said that Harry could meet with him any time tomorrow. Ron was in the process of obliterating Harry at wizarding chess when the snowy owl landed on the board, scattering the pieces.
diff --git a/src/OEBPS/Chapter15.xhtml b/src/OEBPS/Chapter15.xhtml index 96f4a65..1b729e7 100644 --- a/src/OEBPS/Chapter15.xhtml +++ b/src/OEBPS/Chapter15.xhtml @@ -8,7 +8,8 @@After lunch, Mrs. Weasley put the boys to work degnoming the garden while Mr. Weasley puttered around in his shed. Ginny and her mother were going to the village to finish their shopping. Before they left, Harry made a trip to the bathroom and then ran up to his room. Before stowing the moneybag he extracted a handful of coins. When he came back down, Mrs. Weasley was alone, putting away the last of the dishes.
diff --git a/src/OEBPS/Chapter17.xhtml b/src/OEBPS/Chapter17.xhtml index 4cf5758..6a9f1d3 100644 --- a/src/OEBPS/Chapter17.xhtml +++ b/src/OEBPS/Chapter17.xhtml @@ -9,6 +9,7 @@This was the strangest summer of Ginevra Weasley’s life.
diff --git a/src/OEBPS/Chapter18.xhtml b/src/OEBPS/Chapter18.xhtml index 022f146..a6a98ad 100644 --- a/src/OEBPS/Chapter18.xhtml +++ b/src/OEBPS/Chapter18.xhtml @@ -8,7 +8,8 @@Friday morning dawned bright and clear, and even the twins joined Harry, Ron, and Ginny on their morning run. With the five of them, the sparring was more interesting as well. By the time they were done, everyone was tired, lightly bruised, and starving for breakfast. Molly clucked her tongue as they filed into the kitchen. She stopped dead in her tracks and stared at her daughter.
diff --git a/src/OEBPS/Chapter19.xhtml b/src/OEBPS/Chapter19.xhtml index 09b34ef..30ea056 100644 --- a/src/OEBPS/Chapter19.xhtml +++ b/src/OEBPS/Chapter19.xhtml @@ -8,7 +8,8 @@Feeling like they were actually doing something about Sirius gave Harry enough peace of mind for a good night’s sleep. Though he woke as soon as Molly began knocking on doors, he was feeling refreshed. Bouncing out of bed, Harry grabbed a quick shower while the rest of the Weasleys were starting to stir. Remembering the chaos of the Weasley departure the first time around, Harry made a point of packing his trunk both rapidly and systematically. Truth be told, he’d never fully unpacked it. He got it locked and carried down to the back door while Ron was still in the bathroom.
diff --git a/src/OEBPS/Chapter2.xhtml b/src/OEBPS/Chapter2.xhtml index 52dddc8..f97f228 100644 --- a/src/OEBPS/Chapter2.xhtml +++ b/src/OEBPS/Chapter2.xhtml @@ -9,6 +9,7 @@Harry woke from his nightmare, screaming at the top of his lungs.
diff --git a/src/OEBPS/Chapter20.xhtml b/src/OEBPS/Chapter20.xhtml index 9473e85..a208a36 100644 --- a/src/OEBPS/Chapter20.xhtml +++ b/src/OEBPS/Chapter20.xhtml @@ -8,7 +8,7 @@Being the headmaster of Hogwarts School of Witchcraft and Wizardry was not an easy job. Neither was leading the Order of the Phoenix during the first war against Voldemort. But both jobs entailed fewer headaches than being the sole person aware of the entire Prophecy.
diff --git a/src/OEBPS/Chapter21.xhtml b/src/OEBPS/Chapter21.xhtml index 5164f16..5777eee 100644 --- a/src/OEBPS/Chapter21.xhtml +++ b/src/OEBPS/Chapter21.xhtml @@ -8,7 +8,7 @@That evening Neville received a hero’s welcome in the Gryffindor common room, which rather embarrassed him. Percy, however, proved to be the exception to the rule. The Weasley prefect seemed to revel in his role as the official killjoy and began berating Neville in front of everyone. This earned Percy some mutinous glares from his housemates, which he ignored.
diff --git a/src/OEBPS/Chapter23.xhtml b/src/OEBPS/Chapter23.xhtml index 4602336..e57759e 100644 --- a/src/OEBPS/Chapter23.xhtml +++ b/src/OEBPS/Chapter23.xhtml @@ -8,7 +8,7 @@Ron and Hermione were starting to stir as Harry and Ginny returned to the compartment. Harry could tell they awoke simultaneously, because they both visibly cringed and immediately sat up, ramrod straight on the bench. The shuffling and coughing awoke Neville as well. The normally shy boy couldn’t react as the others, because Luna was still curled up on his lap, dead to the world. His face became a bit pink as he waited for someone to say something. Fortunately, Ron and Hermione were a little distracted by their own embarrassment, while Harry just shrugged and returned to his seat.
diff --git a/src/OEBPS/Chapter25.xhtml b/src/OEBPS/Chapter25.xhtml index 8b65013..46d1492 100644 --- a/src/OEBPS/Chapter25.xhtml +++ b/src/OEBPS/Chapter25.xhtml @@ -8,7 +8,7 @@For Harry, this was one of the most abnormal holiday seasons he’d ever experienced. No looming threat of war, no one murdered yet, staying with people that were actually glad to have him there; it was utterly bizarre and without precedent. Even in his younger memories, Harry didn’t have many happy holidays. Aside from the Dursleys competing to make him miserable as they spoiled their own child, he’d always spent most of the Christmas season wondering how things would have been if his parents were still alive.
diff --git a/src/OEBPS/Chapter27.xhtml b/src/OEBPS/Chapter27.xhtml index c7ca326..1135531 100644 --- a/src/OEBPS/Chapter27.xhtml +++ b/src/OEBPS/Chapter27.xhtml @@ -8,7 +8,7 @@Harry slowly became aware. It was a very gradual process, hampered by the fact that he seemed to be floating in absolute darkness. Of course, ‘floating’ was his best guess, because he couldn’t feel his body either.
diff --git a/src/OEBPS/Chapter28.xhtml b/src/OEBPS/Chapter28.xhtml index 692bcf8..965687b 100644 --- a/src/OEBPS/Chapter28.xhtml +++ b/src/OEBPS/Chapter28.xhtml @@ -8,7 +8,7 @@Luna gave them a knowing look when Harry and Ginny came in from outdoors and sat down for lunch in the Great Hall. Even though Ginny’s cheeks were a little pink and her eyes were red, she managed to give her friend a small smile.
diff --git a/src/OEBPS/Chapter3.xhtml b/src/OEBPS/Chapter3.xhtml index 4d48dea..29f40e2 100644 --- a/src/OEBPS/Chapter3.xhtml +++ b/src/OEBPS/Chapter3.xhtml @@ -9,6 +9,7 @@Harry relaxed a bit as he and Ron talked about safer topics: Charlie and Bill’s careers, the attempted break-in at Gringotts, and, inevitably, Quidditch. Hearing his friend talk about their favourite sport was like coming home again after a long journey, and Harry didn’t have to feign a happy smile.
diff --git a/src/OEBPS/Chapter4.xhtml b/src/OEBPS/Chapter4.xhtml index a7f58e9..54d6d0e 100644 --- a/src/OEBPS/Chapter4.xhtml +++ b/src/OEBPS/Chapter4.xhtml @@ -9,6 +9,7 @@…And then Ron and Neville went with me to visit Hagrid after lunch. He’s quite possibly the largest man I have ever seen, but he’s really a good bloke. I’ve only ever seen him get mad once, and that was at my uncle who was being really awful at the time. He’s the groundskeeper here at Hogwarts and he really loves animals. He took a look at Trevor, Neville’s toad, and said the reason that Trevor was always getting lost is that he was hungry. Seems like the dried food pellets they sold Nev at Magical Menagerie don’t have everything a toad needs, so he was always scampering off looking for a bug or two. Hagrid gave him a little bottle of fish oil and said a drop or two in Trevor’s food each day should make a difference.
diff --git a/src/OEBPS/Chapter5.xhtml b/src/OEBPS/Chapter5.xhtml index 99d7d6f..7c77b92 100644 --- a/src/OEBPS/Chapter5.xhtml +++ b/src/OEBPS/Chapter5.xhtml @@ -8,7 +8,8 @@Harry kept a low profile with his meddling after that. He enjoyed Oliver’s enthusiasm for the game and their prospects for the new season. The congratulations from Fred and George particularly warmed his heart. He hadn’t seen much of the twins lately — they were no doubt up to the eyebrows in some mischief — but that would change once they started practising together. He concentrated on the here and now, and not on what he knew was coming.
diff --git a/src/OEBPS/Chapter6.xhtml b/src/OEBPS/Chapter6.xhtml index 8dde280..758445e 100644 --- a/src/OEBPS/Chapter6.xhtml +++ b/src/OEBPS/Chapter6.xhtml @@ -8,7 +8,8 @@Things calmed down a bit after the match. The school was abuzz the following Monday of course, but the upset of the feared Slytherin house team seemed to have deflated them considerably. Even Draco Malfoy had pulled in his horns, to Harry’s silent relief. He wasn’t afraid of the pureblood boy so much as alarmed at how quickly their antagonism had heated up, even compared to their past history. Harry wasn’t as easily confused or intimidated as he was before, and his refusal to back down at all seemed to infuriate the boy.
diff --git a/src/OEBPS/Chapter8.xhtml b/src/OEBPS/Chapter8.xhtml index f1e0ac8..99df878 100644 --- a/src/OEBPS/Chapter8.xhtml +++ b/src/OEBPS/Chapter8.xhtml @@ -9,6 +9,7 @@Harry’s stomach lurched and he almost let go of the snitch as he remembered the Triwizard Cup and the port-key that whisked him and Cedric to Little Hangleton.
diff --git a/src/OEBPS/Chapter9.xhtml b/src/OEBPS/Chapter9.xhtml index 0f3399d..330556b 100644 --- a/src/OEBPS/Chapter9.xhtml +++ b/src/OEBPS/Chapter9.xhtml @@ -9,6 +9,7 @@Molly Weasley was concerned.
diff --git a/src/OEBPS/TOC.xhtml b/src/OEBPS/TOC.xhtml index 05e7fb2..15a04d8 100644 --- a/src/OEBPS/TOC.xhtml +++ b/src/OEBPS/TOC.xhtml @@ -17,8 +17,8 @@