You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Github allows you to use special characters in the titles of wiki pages. If you mirror a Github repository with Gitea, it pulls the wiki as well. However, any wiki pages with special characters in the titles cannot be accessed. They redirect to /wiki/_pages instead.
The text was updated successfully, but these errors were encountered:
I did some deeper digging and found that when you make a wiki page with special characters in the title from within Gitea (instead of from a mirror), it saves the file with escaped characters in the filename. So my solution at #8374 would break any existing wiki pages with special characters in the title because Gitea would be looking for unescaped characters in the filename.
This presents a more complex issue. As it stands right now, a wiki page with special characters in the name does work, but the filename contains escaped characters (Title-with-comma%2C-ampersand-%26-%5Bbrackets%5D.md). The same wiki page from a mirror is broken because the filename contains unescaped characters (Title-with-comma,-ampersand-&-[brackets].md). If we change Gitea to look for filenames with unescaped characters, the reverse will be true.
One way to fix this would be to have Gitea look for an escaped filename first and if it finds none, look again for an unescaped filename. If it finds one, use that. This would allow Gitea to find filenames that are saved either way. This is the solution presented in #8408
My personal opinion is that Gitea should be saving the filenames with unescaped characters as well. Sometimes these wikis are cloned and edited locally. Unescaped filenames are better for that. If Gitea is changed to look for both escaped and unescaped filenames, it could also optionally be changed to save new wiki pages with unescaped characters instead. Also, it could be changed so that any edits made with the Gitea editor to filenames with escaped characters could result in the file being re-saved with unescaped characters.
^ I'm going to separate that into another issue. #8410
[x]
):Description
Github allows you to use special characters in the titles of wiki pages. If you mirror a Github repository with Gitea, it pulls the wiki as well. However, any wiki pages with special characters in the titles cannot be accessed. They redirect to
/wiki/_pages
instead.The text was updated successfully, but these errors were encountered: