aboutsummaryrefslogtreecommitdiffstats
path: root/tests/setup.sh
diff options
context:
space:
mode:
authorBaptiste Jonglez <git@bitsofnetworks.org>2026-02-27 16:51:11 +0100
committerChristian Hesse <mail@eworm.de>2026-05-21 15:31:21 +0200
commitc9f91124f9462d8eeb0a9d2ddeff586807413fc0 (patch)
tree19a7c566234b453f55099c9b4461e692a0b77d22 /tests/setup.sh
parent55f8359c0b18e6f2c182fd14132d1d58fb39b6d1 (diff)
downloadcgit-c9f91124f9462d8eeb0a9d2ddeff586807413fc0.tar.gz
cgit-c9f91124f9462d8eeb0a9d2ddeff586807413fc0.tar.bz2
cgit-c9f91124f9462d8eeb0a9d2ddeff586807413fc0.zip
cgit: Fix guessing default branchch/for-jason
Even when HEAD is set to "main" in a repository, cgit still uses the "master" branch to detect the age of the last commit. Example: $ cat repositories/openwrt/openwrt.git/HEAD ref: refs/heads/main $ stat repositories/openwrt/openwrt.git/refs/heads/master Modify: 2024-02-22 23:00:01.285731731 +0000 $ stat repositories/openwrt/openwrt.git/refs/heads/main Modify: 2026-02-27 15:33:49.506017172 +0000 In this situation, cgit displays "25 months" for this repository on the index page. I guess the internal format for HEAD has changed at some point, so it needs to be taken into account when parsing it in cgit. Signed-off-by: Baptiste Jonglez <git@bitsofnetworks.org>
Diffstat (limited to 'tests/setup.sh')
0 files changed, 0 insertions, 0 deletions