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

Can't Merge a Sub-Module! #1

Open
RandomDSdevel opened this issue Dec 1, 2014 · 32 comments
Open

Can't Merge a Sub-Module! #1

RandomDSdevel opened this issue Dec 1, 2014 · 32 comments

Comments

@RandomDSdevel
Copy link
Owner

From @RandomDSdevel on November 3, 2014 21:34

After finally succeeding in running a script described here on this repository, I cannot seem to create a pull request that will allow me to merge my work with that which is stored inside this repository's base repository. The problem appears to be that, in the scenario which I have created, pull requests don't work. In order to merge my work, I apparently need to be given the permissions necessary to push my commits directly to this repository's base repository.

Copied from original issue: RandomDSdevel/OBJC4-437.1-Runtime#1

@RandomDSdevel
Copy link
Owner Author

Maybe I have to be added to the base repository as a contributor before I can make this work?

@RandomDSdevel
Copy link
Owner Author

From @macmade on November 12, 2014 12:1

I'm a bit surprised you added me on your fork... Not the usual kind of workflow.
That being said, I don't understand what you are trying to achieve.

The base repository is a mirror of the Objective-C runtime version 437.1, as available at opensource.apple.com.
Downloading sources from opensource.apple.com is a real pain, and as I needed those sources, I've made them available on GitHub.

But that's still a mirror, and so there's no change to do.
I will never modify anything in this code by Apple, nor accept pull requests.

If you need to modify sources of the Objective-C runtime for some reason, I suggest you first check for a new version at opensource.apple.com.
And if you really need to modify something, then do it on your own fork. That's what forks intended for.

@RandomDSdevel
Copy link
Owner Author

But there are forks of Objective-C and its run-time components everywhere on GitHub. Just do a search for 'objc4' here on GitHub, and you'll find at least nine copies of Apple's Objective-C source code! I'm trying to merge all of them this repository so that we only have to deal with one of them! The first step that is required for me to be able to do that is one in which I merge your repository into that target repository, but I can't easily do that because of how your repository deletes everything but the 'runtime' folder found in the other repositories that I want to merge together, empties this folder's contents out into your repository's root directory, and then deletes the now-empty 'runtime' folder! If I can't undo this, then I can't merge your repository repository into mine! I would have notified you about this on this repository's base repository, but it doesn't have GitHub Issues enabled!

@RandomDSdevel
Copy link
Owner Author

From @macmade on November 12, 2014 14:11

Then why did you a fork?

If you want to create a repository with other repositories, use submodules.
There's no way a modification is needed in the submodule's repository for this.

@RandomDSdevel
Copy link
Owner Author

From @macmade on November 12, 2014 14:14

And please, if you still think you need to modify something, do it in your own fork, as you've created one.

@RandomDSdevel
Copy link
Owner Author

But can you merge a fork of another repository into your own as a submodule while still maintaining the link between the repositories even after integrating the submodule into your repository?

@RandomDSdevel
Copy link
Owner Author

From @macmade on November 12, 2014 16:15

I don't understand why, what and where you want to merge.

Use submodules, that's all you need to do...

@RandomDSdevel
Copy link
Owner Author

I suppose that would be a simpler way to do it, wouldn't it? And here I was, thinking that trying to merge a submodule created out of my fork of your repository into this repository using these instructions would be a much better idea! But what'll happen to my submodule when I merge its parent repository with some others? Will the link survive intact, or will it be lost in transit?

@RandomDSdevel
Copy link
Owner Author

Oh, wait…I think I lost the inter-repository linkage in my last attempt. I got all of the repository history, though, and maybe that's all that really matters?

@RandomDSdevel
Copy link
Owner Author

From @macmade on November 12, 2014 17:47

Let's start again, as this is getting nowhere...

Basically, what you want is a repository which contains multiple repositories from GitHub, preserving what you call a link...

Am I right?

Sent from my iPhone

On Nov 12, 2014, at 6:13 PM, Bryce Glover notifications@github.com wrote:

Oh, wait…I think I lost the inter-repository linkage in my last attempt. I got all of the repository history, though, and maybe, then, that's all that really matters?


Reply to this email directly or view it on GitHub.

@RandomDSdevel
Copy link
Owner Author

Er…yes, I suppose, but I don't want all of the repositories to be side by side in their own separate little folders; I instead want them to be saved in as different revisions of the same repository. This is because the repositories in question, as listed here are actually all just different snapshots of the same repository. Your repository seems to be the oldest snapshot of Apple's Objective-C code as stored on its repository, so your repository is the first one with which I am dealing. To do so, I plan to either merge your repository into my target repository completely, getting rid of yours entirely, or have this target repository contain your repository as a sub-module or other form of linked repository in an older commit. The end result of this whole giant mess of a merger should be an exact mirror of the latest version of the Objective-C source code stored in the current state of Apple's repository, but with older versions of the Objective-C source code saved as older commits.
The reason that I'm having trouble merging your repository in is because it doesn't have the same directory tree structure as all of the other repositories! I was trying to rectify that in my fork before attempting a merger, but I keep losing connectivity with your repository. The problem is that I can't seem to create that fork in such a way that I can still go through it and create a pull request with which to ask you to merge my changes back into your repository. Maybe part of the reason that this keeps happening is because I keep trying to use the instructions I've mentioned several times in order to try and integrate the sub-module that I created out of my fork of your repository into my target repository? In all likelihood, I should probably just start over and just add your repository directly into my master Objective-C repository as a sub-module without going through a fork…or did I already succeed in moving your changes over even though I may have accidentally done a copy operation instead? In that case, could I just delete my fork? The article I keep referencing says to delete the source repository — yours, in this case — but it has forks other than mine attached to it…

@RandomDSdevel
Copy link
Owner Author

From @macmade on November 12, 2014 19:1

I think you're overthinking this whole stuff...

If I understand, you want your own objc4 repository to contain specific tags, each one containing one (and only one) of the many repositories containing the Objective-C runtime...

So there's nothing complicated, and nothing involving merges and whatsoever.

  1. Create a repository
  2. Add repository XXX as a submodule
  3. Commit your changes
  4. Tag the commit
  5. Remove XXX from the submodules
  6. Add repository YYY as a submodule
  7. Commit your changes
  8. Tag the commit
  9. ... repeat ...

@RandomDSdevel
Copy link
Owner Author

I think I get what you're saying, but I'm pretty sure that your repository is the only one that I'll need to add into mine as a sub-module; I'll probably add the rest of them in as remote-tracking branches and then merge the resulting branches together in version order as discussed here.

@RandomDSdevel
Copy link
Owner Author

From @macmade on November 12, 2014 23:29

Whatever...

Try to avoid loosing time and getting headaches with queer procedures...

Start using submodules, and use tags...

Trust me on this one.

@RandomDSdevel
Copy link
Owner Author

But all of these repositories contain at least some of the same files, and most of them have revisions that are exactly the same! Aren't tags for keeping track of different files from different sub-repositories that all have to do with at least one of their parent repositories' releases? What I want to do is merge a bunch of remote-tracking branches together without losing my capability to track their parents. Is that possible when one of the branches isn't really a true remote tracking branch and is, instead, a branch containing a sub-repository, or will I lose connectivity?

@RandomDSdevel
Copy link
Owner Author

From @macmade on November 22, 2014 15:7

Well, tags are usually meant to manage different versions/releases of some source code.
I think it's what you are looking for...

Branches are generally used for different implementations, while in development, feature experimentations, etc...

Obviously you're free to use them as you want...

Last thing: you began working with a fork of my repos, and you now imagine my repos has something special because you can't achieve what you thought would be nice.

Let me just tell you this repository has nothing special regarding its configuration. How could it be, with only 4 commits in a single branch?

So if you have issues with it, you'll have issues with the others too...

So keep it simple...

@RandomDSdevel
Copy link
Owner Author

No, no, no; it's not your repository's configuration that's causing me trouble, but the fact that the file structure that you use in your repository is different from all of the others (listed here.) What you have in your repository is what all the other repositories have inside a folder named 'runtime,' just like Apple does in its repository. That is the reason why I can add your repository, but none of the others on my 'to do' list, as a sub-module. (As discussed earlier on in this thread, I originally tried to fix this problem by making your repository's directory-tree structure match that used in all of the others so that I could just create a tracking branch for each repository involved and then merge them, but that procedure apparently disconnected the fork in which I tried to do this from your repository in such a way that I could no longer create pull requests. As such, I've switched to including your repository in my main one as a sub-module inside its own branch and, therefore, no longer need this fork — I would have deleted it a while back because of this, but this issue is still attached to it.) For all of the other repositories involved in this big mess, I will, at least at first, need to track them using other branches. I do intend to merge everything together into my main repository's 'master' branch in the end, though, and will most likely do so by making sure that every single one of my branches has been tagged similarly enough so that the merger can be done by tag.

@RandomDSdevel
Copy link
Owner Author

@macmade: Can you add me to your upstream repository as a contributor so that I can move this issue there using one of the tools mentioned here and then delete my fork? I've included your upstream repository in my main Objective-C repository's 'macadamia' branch as a submodule, so I don't really need this fork any more.

@RandomDSdevel
Copy link
Owner Author

From @macmade on December 1, 2014 0:30

@RandomDSdevel No...

@RandomDSdevel
Copy link
Owner Author

@macmade: Then can you migrate my issue for me so that I can delete this fork?

@RandomDSdevel
Copy link
Owner Author

From @macmade on December 1, 2014 0:41

@RandomDSdevel Sorry but no. This issue has nothing to do with my repository. Plus I don't want to activate the issue system on such a repository, as it simply doesn't make sense at all.
Why don't you simply delete your fork?

@RandomDSdevel
Copy link
Owner Author

@macmade: I just don't want to lose this issue in the process. Maybe I'll move it to my main 'objc4' repository instead, then. I'll still need your help merging your repository into my main one, though, so could you follow me over there?

@RandomDSdevel
Copy link
Owner Author

@macmade: OK, the issue's been moved and I've deleted the old fork.

@RandomDSdevel
Copy link
Owner Author

@macmade: You can remove yourself from the 'Assignee' and 'Collaborators' lists once you've gotten yourself back on the record as a 'participant' in this issue's discussion. (I'm just trying to facilitate that here, 'kay?)

@RandomDSdevel
Copy link
Owner Author

@macmade: Oh, wait…I think that I put you back on this issue's 'Participants' list just by temporarily assigning this issue to you until you reply to this thread again; I'm going to leave you as this issue's assignee until you've commented again so that you don't drop off of the 'Participants' list once you're no longer assigned to work on this issue, though, all right?

@macmade
Copy link

macmade commented Dec 4, 2014

Once again, do whatever you want with your forks, repos, etc...

Please don't assign my an issue just because you want/need help with your own repositories and stuff, or just because you want me to reply...
I'm OK with helping people, but there's a limit... Please don't abuse people's kindness...

@macmade macmade removed their assignment Dec 4, 2014
@macmade macmade closed this as completed Dec 4, 2014
@RandomDSdevel RandomDSdevel changed the title Can't Create a Pull Request! Can't Merge a Tracking Branch! Dec 5, 2014
@RandomDSdevel
Copy link
Owner Author

OK, @macmade, here's what I need your help with: you don't seem to be maintaining your copy of Objective-C any more, and there should really only be one mirror of the part of Apple's repository used by the company to host Objective-C, so what I've been trying to do is permanently merge your Objective-C repository into my Objective-C repository. The first step to doing that is adding a sub-module containing your repository into a branch of my repository that I prepared to receive such a sub-module, and I've done that. The second step to merging your repository into mine is following these instructions, and, as I've tried to tell you before, I've already attempted to do this once. The procedure in question did not, however, delete your repository after making all of the forks that are currently branched off of it point to my instantiation of your repository. Because of this, I initially thought that I had done something wrong in the process of attempting to merge a sub-module containing your repository into a branch of my repository and therefore eventually managed to revert the changes which I committed as part of my first try at doing this. What I now realize, though, is that for this to work, I'm going to need your cooperation: after I merge the sub-module containing your repository into the branch of my repository which I've prepared for it, I'll need you to help me migrate the forks currently attached to your repository over to that branch of my repository and then delete your repository. Now do you understand what I've been trying to do all of this time?

@RandomDSdevel RandomDSdevel reopened this Dec 5, 2014
@RandomDSdevel RandomDSdevel changed the title Can't Merge a Tracking Branch! Can't Merge a Sub-Module! Dec 5, 2014
@macmade
Copy link

macmade commented Dec 5, 2014

No...

My repository is a mirror of a specific version of the runtime.
There's nothing to maintain.

If you decided to waste time on this, fair enough. But please don't waste mine.

@macmade macmade closed this as completed Dec 5, 2014
@RandomDSdevel
Copy link
Owner Author

@macmade: But you could still check that specific version out even if there was only a single mirror of Apple's Objective-C repository like there should be!

@RandomDSdevel RandomDSdevel reopened this Dec 16, 2014
@RandomDSdevel
Copy link
Owner Author

@macmade: See above. IMHO, only one Objective-C repo mirror should exist on GitHub, and this issue is documentation on the first step to achieving that.

@macmade
Copy link

macmade commented Dec 16, 2014

Ok kiddo...

Now you crossed the line...
Tried to help you, tried to make you understand a few stuff, tried to be nice...

And you just piss me off again and again, assigning issues that only exists in your sick head...

You know what? You've won...
From now on, you're being blocked. Tired of your bullshit...

Get a life...

@RandomDSdevel
Copy link
Owner Author

@macmade: Um…okay? And I wasn't exactly being rude, per se, just persistent. You, my friend, are the one who's being rude for interpreting my insistence as impertinence. And I would have thought that you would've been more helpful; so much for solidarity in productivity!

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

No branches or pull requests

2 participants