Skip to content

Conversation

@a1012112796
Copy link
Member

@a1012112796 a1012112796 commented Aug 15, 2025

ref: golang/go@835e36f

close #35135

example view:

725ee68caeb956e7cd514f4476e4e3ef
2eb1ceee4741f1ceaa34547b0f99f903

go get test result:

# get https://private.zhao1012112796.top/?go-get=1
# get https://private.zhao1012112796.top/testg?go-get=1
# get https://private.zhao1012112796.top/testg/test_repo?go-get=1
# get https://private.zhao1012112796.top/testg/test_repo?go-get=1: 200 OK (0.027s)
# get https://private.zhao1012112796.top/?go-get=1: 200 OK (0.029s)
get "private.zhao1012112796.top/testg/test_repo": found meta tag vcs.metaImport{Prefix:"private.zhao1012112796.top/testg/test_repo", VCS:"git", RepoRoot:"https://private.zhao1012112796.top/testg/test_repo.git", SubDir:"haha"} at //private.zhao1012112796.top/testg/test_repo?go-get=1
mkdir -p C:\Users\zzc\go\pkg\mod\cache\vcs # git3 https://private.zhao1012112796.top/testg/test_repo.git
# lock C:\Users\zzc\go\pkg\mod\cache\vcs\77054afae63cbb57d438e03e37c62470cbdab339bba361937e2b4fdc7de818a3.lock
# C:\Users\zzc\go\pkg\mod\cache\vcs\77054afae63cbb57d438e03e37c62470cbdab339bba361937e2b4fdc7de818a3 for git3 https://private.zhao1012112796.top/testg/test_repo.git
cd C:\Users\zzc\go\pkg\mod\cache\vcs\77054afae63cbb57d438e03e37c62470cbdab339bba361937e2b4fdc7de818a3; git config extensions.objectformat
# get https://private.zhao1012112796.top/testg?go-get=1: 200 OK (0.030s)
0.016s # cd C:\Users\zzc\go\pkg\mod\cache\vcs\77054afae63cbb57d438e03e37c62470cbdab339bba361937e2b4fdc7de818a3; git config extensions.objectformat
cd C:\Users\zzc\go\pkg\mod\cache\vcs\77054afae63cbb57d438e03e37c62470cbdab339bba361937e2b4fdc7de818a3; git ls-remote -q origin
0.060s # cd C:\Users\zzc\go\pkg\mod\cache\vcs\77054afae63cbb57d438e03e37c62470cbdab339bba361937e2b4fdc7de818a3; git ls-remote -q origin
cd C:\Users\zzc\go\pkg\mod\cache\vcs\77054afae63cbb57d438e03e37c62470cbdab339bba361937e2b4fdc7de818a3; git -c log.showsignature=false log --no-decorate -n1 '--format=format:%H %ct %D' 140fbb298455c311df6f8242316f406308fa3ffe --
0.017s # cd C:\Users\zzc\go\pkg\mod\cache\vcs\77054afae63cbb57d438e03e37c62470cbdab339bba361937e2b4fdc7de818a3; git -c log.showsignature=false log --no-decorate -n1 '--format=format:%H %ct %D' 140fbb298455c311df6f8242316f406308fa3ffe --
cd C:\Users\zzc\go\pkg\mod\cache\vcs\77054afae63cbb57d438e03e37c62470cbdab339bba361937e2b4fdc7de818a3; git for-each-ref --format %(refname) refs/tags --merged 140fbb298455c311df6f8242316f406308fa3ffe
0.016s # cd C:\Users\zzc\go\pkg\mod\cache\vcs\77054afae63cbb57d438e03e37c62470cbdab339bba361937e2b4fdc7de818a3; git for-each-ref --format %(refname) refs/tags --merged 140fbb298455c311df6f8242316f406308fa3ffe
cd C:\Users\zzc\go\pkg\mod\cache\vcs\77054afae63cbb57d438e03e37c62470cbdab339bba361937e2b4fdc7de818a3; git -c log.showsignature=false log --no-decorate -n1 '--format=format:%H %ct %D' 140fbb298455 --
0.015s # cd C:\Users\zzc\go\pkg\mod\cache\vcs\77054afae63cbb57d438e03e37c62470cbdab339bba361937e2b4fdc7de818a3; git -c log.showsignature=false log --no-decorate -n1 '--format=format:%H %ct %D' 140fbb298455 --
cd C:\Users\zzc\go\pkg\mod\cache\vcs\77054afae63cbb57d438e03e37c62470cbdab339bba361937e2b4fdc7de818a3; git cat-file blob 140fbb298455c311df6f8242316f406308fa3ffe:haha/go.mod
0.016s # cd C:\Users\zzc\go\pkg\mod\cache\vcs\77054afae63cbb57d438e03e37c62470cbdab339bba361937e2b4fdc7de818a3; git cat-file blob 140fbb298455c311df6f8242316f406308fa3ffe:haha/go.mod

@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Aug 15, 2025
@github-actions github-actions bot added modifies/translation modifies/api This PR adds API routes or modifies them modifies/go Pull requests that update Go code modifies/templates This PR modifies the template files labels Aug 15, 2025
Copy link
Member

@techknowlogick techknowlogick left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm unsure if the package code should be involved, as the meta import tag also exists for regular repositories.

@GiteaBot GiteaBot added lgtm/blocked A maintainer has reservations with the PR and thus it cannot be merged and removed lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. labels Aug 15, 2025
@a1012112796

This comment was marked as outdated.

@a1012112796
Copy link
Member Author

I'm unsure if the package code should be involved, as the meta import tag also exists for regular repositories.

Or maybe add maybe add a special unit named as misc to sore these special repo level configs? in my view store config in units is a better way than others since #22500 was closed.

@lunny
Copy link
Member

lunny commented Aug 16, 2025

You can just use UnitCode to store this configuration if it's necessary. I don't think UnitMisc is necessary and correct.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

lgtm/blocked A maintainer has reservations with the PR and thus it cannot be merged modifies/api This PR adds API routes or modifies them modifies/go Pull requests that update Go code modifies/templates This PR modifies the template files modifies/translation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

adapt subdirectory in go-import for go 1.25

4 participants