Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: main page in case it was created from exception #122

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

galargh
Copy link
Contributor

@galargh galargh commented Mar 14, 2022

This fixes the issues that affected Belarusian wiki for example - #120

In case of Belarusian wiki, the main page lands in exceptions. This means that in the resulting website it's available under wiki/main_page/index.html instead of wiki/main_page.

When it's copied to wiki/index.html, one depth level in relative links have to be removed.

Previously, we were looking at the input main page path to determine if relative links need to be fixed up. With this change, we will be looking at the actual path (e.g. after exceptions processing).

This fix was tested as part of #123.

@galargh galargh requested a review from lidel March 14, 2022 16:38
@ipfs ipfs deleted a comment from welcome bot Mar 14, 2022
@BigLep BigLep added this to the Best Effort Track milestone Mar 15, 2022
@galargh
Copy link
Contributor Author

galargh commented May 13, 2022

@lidel Should we merge this fix to make sure the wikis we want to create in the future have correct main pages set up?

@kelson42
Copy link

The latest zimdump has a fix regarding main page teporting... maybe it has an impact here.

@galargh
Copy link
Contributor Author

galargh commented May 13, 2022

The latest zimdump has a fix regarding main page teporting... maybe it has an impact here.

Either way, options.kiwixMainPage refers to the user-provided main page path while kiwixMainPageSrc would refer to the actual path that we end up with. So even if the underlying issue in zimdump is already fixed, this PR corrects the semantics here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Status: 🔎 In Review
Development

Successfully merging this pull request may close these issues.

None yet

3 participants