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

Don't remove .gitmodules if there're other modules #33

Open
ForNeVeR opened this issue Jan 12, 2018 · 8 comments
Open

Don't remove .gitmodules if there're other modules #33

ForNeVeR opened this issue Jan 12, 2018 · 8 comments
Labels

Comments

@ForNeVeR
Copy link
Owner

ForNeVeR commented Jan 12, 2018

Consider that I have a repository with multiple submodules like this.

After I run git-submerge cscctest, it deletes the .gitmodules, but there're other modules I also want to import!

I think that git-submerge should just remove a reference to the merged module from .gitmodules, and it should remove a .gitmodules after that only if it's empty.

@Minoru
Copy link
Collaborator

Minoru commented Jan 14, 2018

Hi! Sorry for taking so long to respond—I got buried under some work and life commitments.

I planned for git-submerge to be smarter about .gitmodules, but took a shortcut in 362825d so that I could release 0.1 faster.

This project is discontinued and I don't have any plans to revive it. Are you absolutely sure you need it? Have you considered alternative approaches I describe in my blog post?

@ForNeVeR
Copy link
Owner Author

Sorry for taking so long to respond—I got buried under some work and life commitments.

That's never a problem, thanks for reply!

This project is discontinued and I don't have any plans to revive it.

Yes, I understand. That doesn't mean we shouldn't file issues though!

Are you absolutely sure you need it?

As far as I currently understand: yes.

Have you considered alternative approaches I describe in my blog post?

I have read your post. It seems that git-submerge is still the only option if I want the "Pretending we never even had a submodule" way?

Also, I'm curious: why was it discontinued? Have you found any blocking issues, or do you just no longer need it?

@Minoru
Copy link
Collaborator

Minoru commented Jan 15, 2018 via email

@ForNeVeR
Copy link
Owner Author

Yes, I'd like to revive the project. I'm sort of PL librarian/archaeologist, and I often have to deal with old repositories full of odd things like submodules nobody actually use. So I need significantly more tooling to deal with these cases, and git-submerge looks like one of these tools I could use. Could you please transfer the project to me?

(Don't want yet to involve Codingteam because it looks like the project will have only one active ct-related maintainer, myself.)

@Minoru
Copy link
Collaborator

Minoru commented Jan 16, 2018

Could you please transfer the project to me?

Sure! But first, you'll have to remove the fork you made when you worked on Windows build for git-submerge :)

@ForNeVeR
Copy link
Owner Author

Done.

@ForNeVeR ForNeVeR self-assigned this Feb 4, 2018
@ForNeVeR ForNeVeR added the bug label Feb 4, 2018
@ForNeVeR
Copy link
Owner Author

Alright. According to my investigation, we should be able to call something like

$ git config -f .gitmodules --remove-section submodule.$submodulename

And it should remove the submodule info without touching anything else in the config. Will investigate how to call that through libgit2.

@ForNeVeR
Copy link
Owner Author

ForNeVeR commented Mar 3, 2018

I've solved my task at hand using this bash script, so I'm not currently interested in the solution of this issue with .gitmodules.

Here's what we've got so far: I've created a branch feature/33-gitmodules and pushed my implementation of .gitmodule editing subroutine.

The feature is still not implemented because of that: that code removes the .gitmodules file from the repository, although we need it to edit the file instead.

@ForNeVeR ForNeVeR removed their assignment Mar 3, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants