0
Fork 0
mirror of https://codeberg.org/forgejo/forgejo.git synced 2025-02-21 13:26:24 -05:00
forgejo/models
Gusted 270a2c7fa3 chore: remove usages of sort.Sort (#6689)
improve language stats rounding:

- Add tests (I had to omit some edge cases as the current method is
non-determistic in some cases, due to random order of map access).
- Document the algorithm used.
- Lower the amount of calculations that need to be done.
- Because of the aforementioned non-determistic don't use stable sort
and instead regular sort.

better sorting for `RepositoryList`:

- Add testing
- Use `slices.Sortfunc` instead of `sort.Sort`.
- Remove the methods needed for `sort.Sort`.

better git tag sorter:

- Use `slices.SortFunc` instead of `sort.Sort`.
- Remove `tagSorter` and its related methods.
- Added testing.

Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/6689
Reviewed-by: Earl Warren <earl-warren@noreply.codeberg.org>
Co-authored-by: Gusted <postmaster@gusted.xyz>
Co-committed-by: Gusted <postmaster@gusted.xyz>
2025-01-26 13:30:00 +00:00
..
actions Add search action jobs for API routes, repo, org and global level (#6300) 2025-01-14 11:17:42 +00:00
activities Fix nil panic if repo doesn't exist (#32501) 2024-11-17 12:18:56 +01:00
admin
asymkey
auth fix: xorm needs to be lowercase otherwise it is ignored 2024-12-29 16:25:51 +00:00
avatars
db feat: add limited execution tracing support 2025-01-05 04:07:49 +01:00
dbfs
fixtures feat: add configurable cooldown to claim usernames (#6422) 2025-01-24 04:16:56 +00:00
forgefed
forgejo/semver tests: improve actvititypub integration test code 2024-11-01 22:39:49 +01:00
forgejo_migrations feat: add configurable cooldown to claim usernames (#6422) 2025-01-24 04:16:56 +00:00
git Detect whether action view branch was deleted (#32764) 2024-12-15 09:45:10 +01:00
issues chore(performance): loadCommentsByType sets Issues 2025-01-12 17:52:38 +01:00
migrations fix: reduce noise for the v303 migration (#6591) 2025-01-17 07:42:20 +00:00
organization fix: correct permission loading for limited organisation 2024-12-04 11:03:33 +01:00
packages Alt Linux Apt-Rpm repository support for Forgejo packages. (#6351) 2025-01-22 14:01:49 +00:00
perm tests: improve actvititypub integration test code 2024-11-01 22:39:49 +01:00
project Use project's redirect url instead of composing url (#33058) 2025-01-05 13:46:19 +00:00
pull Add branch auto deletion for scheduled PRs 2024-10-31 03:49:15 +01:00
quota
repo chore: remove usages of sort.Sort (#6689) 2025-01-26 13:30:00 +00:00
secret feat(secret): generate FORGEJO_TOKEN for all tasks 2024-12-08 09:42:18 +08:00
shared/types
system fix: xorm:version default is inconsistent 2024-12-24 09:42:47 +01:00
unit
unittest Refactor env var related code (#33075) 2025-01-05 13:46:19 +00:00
user chore: teach set module about iter.Seq (#6676) 2025-01-24 16:45:46 +00:00
webhook
error.go
main_test.go tests: improve actvititypub integration test code 2024-11-01 22:39:49 +01:00
org.go
org_team.go
org_team_test.go
org_test.go
repo.go Fix issue comment number (#30556) 2025-01-05 12:21:39 +00:00
repo_test.go Fix issue comment number (#30556) 2025-01-05 12:21:39 +00:00
repo_transfer.go
repo_transfer_test.go