summaryrefslogtreecommitdiffstats
path: root/modules/git/submodule_test.go
Commit message (Collapse)AuthorAgeFilesLines
* format with gofumpt (#18184)65432022-01-201-1/+1
| | | | | | | | | | | * gofumpt -w -l . * gofumpt -w -l -extra . * Add linter * manual fix * change make fmt
* Compare SSH_DOMAIN when parsing submodule URLs (#12753)mrsdizzie2020-09-071-17/+19
| | | | | Right now we only compare the hostname from a submodule with the prefixURL it is viewed from to check if the submodule is hosted on the same Gitea instance. This adds an additional check to compare it against SSH_DOMAIN as well since the same Gitea instance might have a different hostname for SSH and if the submodule uses that hostname we should also detect that and link to the proper DOMAIN value. Fixes #12747, #9756
* Do not add prefix on http/https submodule links (#12477)zeripath2020-08-131-0/+1
| | | | | Fix #12345 Signed-off-by: Andrew Thornton <art27@cantab.net>
* Fix submodule paths when AppSubUrl is not root (#11098)zeripath2020-04-221-14/+14
| | | | | | | | Fix submodule paths when AppSubUrl is not root Fix #11002 Signed-off-by: Andrew Thornton <art27@cantab.net>
* Refactor submodule URL parsing (#7100)mrsdizzie2019-06-031-1/+12
| | | | | | | | | | Use combination of url.Parse and regex to parse refURL rather than by hand with indexes & attempt to check if refURL is from same instance and adjust output to match. Also now return empty string instead of our original guess at URL if we are unable to parse it. Fixes #1526
* move code.gitea.io/git to code.gitea.io/gitea/modules/git (#6364)Lunny Xiao2019-03-271-0/+29
* move code.gitea.io/git to code.gitea.io/gitea/modules/git * fix imports * fix fmt * fix misspell * remove wrong tests data * fix unit tests * fix tests * fix tests * fix tests * fix tests * fix tests * enable Debug to trace the failure tests * fix tests * fix tests * fix tests * fix tests * fix tests * comment commit count tests since git clone depth is 50 * fix tests * update from code.gitea.io/git * revert change to makefile