gitweb: Split body of git_search into subroutines