You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gitea/routers/web
wxiaoguang 4e33481357
Make label templates have consistent behavior and priority (#23749)
Fix https://github.com/go-gitea/gitea/issues/23715

Other related PRs:

* #23717
* #23716
* #23719

This PR is different from others, it tries to resolve the problem fundamentally (and brings more benefits)

Although it looks like some more lines are added, actually many new lines are for tests.

----

Before, the code was just "guessing" the file type and try to parse them.

<details>

![image](https://user-images.githubusercontent.com/2114189/228002245-57d58e27-1078-4da9-bf42-5bc0b264c6ce.png)

</details>

This PR:

* Always remember the original option file names, and always use correct parser for them.

* Another benefit is that we can sort the Label Templates now (before there was a map, its key order is undefined)

![image](https://user-images.githubusercontent.com/2114189/228002432-931b9f18-3908-484b-a36b-04760c9ad132.png)
2 years ago
..
admin Clean template/helper.go (#23922) 2 years ago
auth Group template helper functions, remove `Printf`, improve template error messages (#23982) 2 years ago
devtest Introduce GitHub markdown editor, keep EasyMDE as fallback (#23876) 2 years ago
events Implement FSFE REUSE for golang files (#21840) 2 years ago
explore Add ONLY_SHOW_RELEVANT_REPOS back, fix explore page bug, make code more strict (#23766) 2 years ago
feed User/Org Feed render description as per web (#23887) 2 years ago
healthcheck Refactor `setting.Database.UseXXX` to methods (#23354) 2 years ago
misc Introduce GitHub markdown editor, keep EasyMDE as fallback (#23876) 2 years ago
org Make label templates have consistent behavior and priority (#23749) 2 years ago
repo Make label templates have consistent behavior and priority (#23749) 2 years ago
shared Add missing tabs to org projects page (#22705) 2 years ago
user Fix profile page email display, respect settings (#23747) 2 years ago
auth.go Implement FSFE REUSE for golang files (#21840) 2 years ago
auth_windows.go Implement FSFE REUSE for golang files (#21840) 2 years ago
base.go Introduce path Clean/Join helper functions (#23495) 2 years ago
goget.go refactor some functions to support ctx as first parameter (#21878) 2 years ago
home.go Implement FSFE REUSE for golang files (#21840) 2 years ago
metrics.go Implement FSFE REUSE for golang files (#21840) 2 years ago
nodeinfo.go Implement FSFE REUSE for golang files (#21840) 2 years ago
swagger_json.go Group template helper functions, remove `Printf`, improve template error messages (#23982) 2 years ago
web.go Support "." char as user name for User/Orgs in RSS/ATOM/GPG/KEYS path ... (#23874) 2 years ago
webfinger.go Use User.ID instead of User.Name in ActivityPub API for Person IRI (#23823) 2 years ago