Gitea: Submodules dont linked in subdirs

Created on 19 Dec 2017  路  13Comments  路  Source: go-gitea/gitea

  • Gitea version (or commit ref):
  • Git version: 5332052
  • Operating system: debian 8 with docker
  • Database (use [x]):

    • [ ] PostgreSQL

    • [X] MySQL

    • [ ] MSSQL

    • [ ] SQLite

  • Can you reproduce the bug at https://try.gitea.io:

    • [X] Yes (provide example URL)

    • [ ] No

    • [ ] Not relevant

  • Log gist:

Description

Submodules only linked in the root of the repo
reproduce on https://try.gitea.io

Submodules
https://try.gitea.io/tantetoni2/submodule
https://try.gitea.io/tantetoni2/private-submodule

In the root submodules are linked
https://try.gitea.io/tantetoni2/repo

but in subdirs they not linked
https://try.gitea.io/tantetoni2/repo/src/branch/master/submodules

...

Screenshots

kinbug revieweconfirmed

Most helpful comment

Hi there.

I am still unable to link nested submodules. They work as intended if they're on the root directory, however.

I have the exact same setup as the try.gitea project.

.gitmodules file:

[submodule "steamlua"]
path = steamlua
url = /steamlua.git
[submodule "src/Utils"]
path = src/Utils
url = /Utils.git
branch = master

Root submodule works:
image

Nested one does not:
image

Not sure if I'm doing anything wrong.

All 13 comments

when is the bugfix coming?

Nobody is currently working on this so if you can help to fix this that would be great

Please fix this bug...
Links in root of projects are working:
giteabugcorrect
But links in subdirs are dead:
giteabugincorrect

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs during the next 2 weeks. Thank you for your contributions.

I need also this functionality.

Same as previous issue, why is it marked as Stale if nobody in Gitea team is working on it?

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs during the next 2 weeks. Thank you for your contributions.

It's a huge issue in my opinion, I'm sure it could be quickly fix.
I created a repo to validate the issue since other seems to doesn't work.
https://try.gitea.io/salco/SuperProject
Tell me if it's doesn't work.

From what I can find the issue is cause by the code inside repo.go , the function RedirectToRepo.
I've also find a commit that try to fix this issue: 237df2f33987073fdaa1d773faa4c9e87221f9ea .
Maybe it could help someone to fix it.

This looks to be fixed / working as expected based on https://try.gitea.io/salco/SuperProject right? Particularly the fact that https://try.gitea.io/salco/SuperProject/src/branch/master/folder shows the submodule linked as expected.

Closing per above comment. Please re-open if needed

Hi there.

I am still unable to link nested submodules. They work as intended if they're on the root directory, however.

I have the exact same setup as the try.gitea project.

.gitmodules file:

[submodule "steamlua"]
path = steamlua
url = /steamlua.git
[submodule "src/Utils"]
path = src/Utils
url = /Utils.git
branch = master

Root submodule works:
image

Nested one does not:
image

Not sure if I'm doing anything wrong.

If you look on the try gitea the version is 1.9.0... i'm not sure if it solve it the 1.8.0. On my setup it still doesnt work, I will wait the 1.9.0 to be sure this issue is still there.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Fastidious picture Fastidious  路  3Comments

thehowl picture thehowl  路  3Comments

jorise7 picture jorise7  路  3Comments

kolargol picture kolargol  路  3Comments

cookiengineer picture cookiengineer  路  3Comments