gitea/services
wxiaoguang b39a5bbbd6
Make wiki title supports dashes and improve wiki name related features (#24143)
Close #7570


1. Clearly define the wiki path behaviors, see
`services/wiki/wiki_path.go` and tests
2. Keep compatibility with old contents
3. Allow to use dashes in titles, eg: "2000-01-02 Meeting record"
4. Add a "Pages" link in the dropdown, otherwise users can't go to the
Pages page easily.
5. Add a "View original git file" link in the Pages list, even if some
file names are broken, users still have a chance to edit or remove it,
without cloning the wiki repo to local.
6. Fix 500 error when the name contains prefix spaces.


This PR also introduces the ability to support sub-directories, but it
can't be done at the moment due to there are a lot of legacy wiki data,
which use "%2F" in file names.



![image](https://user-images.githubusercontent.com/2114189/232239004-3359d7b9-7bf3-4ff3-8446-bfb0e79645dd.png)


![image](https://user-images.githubusercontent.com/2114189/232239020-74b92c72-bf73-4377-a319-1c85609f82b1.png)

Co-authored-by: Giteabot <teabot@gitea.io>
2023-04-19 13:50:10 -04:00
..
actions Support triggering workflows by wiki related events (#24119) 2023-04-17 13:49:47 -04:00
agit add user rename endpoint to admin api (#22789) 2023-03-14 03:45:21 -04:00
asymkey Add context cache as a request level cache (#22294) 2023-02-15 21:37:34 +08:00
attachment Preserve file size when creating attachments (#23406) 2023-03-12 03:48:07 -04:00
auth Allow adding new files to an empty repo (#24164) 2023-04-19 21:40:42 +08:00
automerge Add force_merge to merge request and fix checking mergable (#23010) 2023-02-21 08:42:07 -06:00
context Use User.ID instead of User.Name in ActivityPub API for Person IRI (#23823) 2023-04-04 10:08:23 +08:00
convert Make wiki title supports dashes and improve wiki name related features (#24143) 2023-04-19 13:50:10 -04:00
cron Add Cargo package registry (#21888) 2023-02-05 18:12:31 +08:00
externalaccount Implement FSFE REUSE for golang files (#21840) 2022-11-27 18:20:29 +00:00
forms Title can be empty when creating tag only (#23917) 2023-04-06 21:44:52 -04:00
gitdiff Fix broken code editor diff preview (#23307) 2023-03-06 09:37:58 +08:00
issue Make more functions use ctx instead of db.DefaultContext (#24068) 2023-04-14 14:18:28 -04:00
lfs Improve LFS error logs (#24072) 2023-04-12 11:01:41 -04:00
mailer Preserve file size when creating attachments (#23406) 2023-03-12 03:48:07 -04:00
markup Implement FSFE REUSE for golang files (#21840) 2022-11-27 18:20:29 +00:00
migrations Update github.com/google/go-github to v51 (#23946) 2023-04-08 19:27:30 +08:00
mirror Fill head commit to in payload when notifying push commits for mirroring (#23215) 2023-03-03 23:45:53 -05:00
org Implement FSFE REUSE for golang files (#21840) 2022-11-27 18:20:29 +00:00
packages Introduce path Clean/Join helper functions (#23495) 2023-03-21 16:02:49 -04:00
pull Make more functions use ctx instead of db.DefaultContext (#24068) 2023-04-14 14:18:28 -04:00
release Delete deleted release attachments immediately from storage (#23913) 2023-04-06 18:01:36 -04:00
repository Allow adding new files to an empty repo (#24164) 2023-04-19 21:40:42 +08:00
task Implement FSFE REUSE for golang files (#21840) 2022-11-27 18:20:29 +00:00
user add user rename endpoint to admin api (#22789) 2023-03-14 03:45:21 -04:00
webhook Fix incorrect HookEventType of pull request review comments (#23650) 2023-03-24 13:13:04 +08:00
wiki Make wiki title supports dashes and improve wiki name related features (#24143) 2023-04-19 13:50:10 -04:00