Thank @tlienart for the insightful answer! The issue is resolved now.
Both of your suggestions were crucial. Specifically,
- I included
prepath = "<my ID>/pages"inconfig.md.- Previously I had tried
prepath = "pages"thinking thatprepathwould need to be the repository name, but it seems that it needs to be the entire part that comes after the first/in the URL.
- Previously I had tried
- I performed
optimize()before pushing the website contents to GitHub.
Implementing only one of the above two steps didn’t solve the issue.