Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cloning with gitmodule gives me entry not found error #145

Closed
genshen opened this issue Jul 31, 2020 · 5 comments
Closed

cloning with gitmodule gives me entry not found error #145

genshen opened this issue Jul 31, 2020 · 5 comments
Labels
stale Issues/PRs that are marked for closure due to inactivity

Comments

@genshen
Copy link

genshen commented Jul 31, 2020

cloning with gitmodule gives me entry not found error

if repos, err := git.PlainClone("csv-parser", false, &git.CloneOptions{
	URL:      "https://github.com/vincentlaucsb/csv-parser.git",
	Progress: os.Stdout,
	//ReferenceName: referenceName, // specific branch or tag.
	RecurseSubmodules: git.DefaultSubmoduleRecursionDepth,
}); err != nil {
	log.Println(err) // Print error here
}

I notice that, in repo 'https://github.com/vincentlaucsb/csv-parser.git' (e.g. version 1.3.3), there is a . gitmodules file and specified directory 'lib/sqlite-cpp' as submodule (but this directory does not exists in repo).

But it works fine when I use git command:

git clone git@github.com:vincentlaucsb/csv-parser.git
git submodule update --init --recursive
@hwwwi
Copy link

hwwwi commented Oct 16, 2020

@genshen
Hello, I had the same issue with the submodule.
It's a bit confusing since the git CLI silently ignores the broken git submodule which is different from go-git.
I think it's better to remove .gitmodule file if you are not using the submodule anymore or add the git submodule directory in your repo.
The git submodule command will not work without the submodule directory anyway.

@dikkini
Copy link

dikkini commented Dec 2, 2020

i also have an issue with submodules.

i have an error: repository not found

my submodules looks like this:

[submodule "libs/ansible-lib"]
  path = libs/ansible-lib
  url = ../ansible-lib.git

but if i specify full URL to repo:

[submodule "libs/ansible-lib"]
  path = libs/ansible-lib
  url = https://example.com/group/ansible-lib.git

it works!

I can suppose that library does not support relatives paths in submodules

@per1234
Copy link

per1234 commented Jan 11, 2023

I can suppose that library does not support relatives paths in submodules

There is now a dedicated issue about that (resolved) bug: #266

Copy link

To help us keep things tidy and focus on the active tasks, we've introduced a stale bot to spot issues/PRs that haven't had any activity in a while.

This particular issue hasn't had any updates or activity in the past 90 days, so it's been labeled as 'stale'. If it remains inactive for the next 30 days, it'll be automatically closed.

We understand everyone's busy, but if this issue is still important to you, please feel free to add a comment or make an update to keep it active.

Thanks for your understanding and cooperation!

@github-actions github-actions bot added the stale Issues/PRs that are marked for closure due to inactivity label Nov 17, 2023
@pjbgf
Copy link
Member

pjbgf commented Nov 17, 2023

Closing this as it has been pointed out as fixed above.

@pjbgf pjbgf closed this as completed Nov 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stale Issues/PRs that are marked for closure due to inactivity
Projects
None yet
Development

No branches or pull requests

5 participants