Wish Help, for merging source codes for a project on which several programmers are working simultaneously

BlueVision

Active Member
Licensed User
Longtime User
One thing that would help me a lot but will be very difficult to implement due to the complexity:
Imagine several developers working together on the source code of a complex programme. It would be nice to have a help function that would then merge the individual projects and help with the adjustments. I realise that this is an almost impossible task, but even hints about differences or timestamps for changes made would be a great help. Just a wish...
 

jahswant

Well-Known Member
Licensed User
Longtime User
 

Andrew (Digitwell)

Well-Known Member
Licensed User
Longtime User
I use Git for this purpose.

This is exactly the use case it was created for.

The only issue I have is with the the .b4a file when merging.

It has both configuration and code in it.

It would be great if in a future version these were separated.....
 

BlueVision

Active Member
Licensed User
Longtime User
Really? I have reservations about that. As I understand it, "Shared Code Modules" is rather meant for porting existing and proven solutions into another project.
What about design changes or two simultaneous changes in the same places in the code? How do you decide which variant of the code to use when several developers started with the same code as a base, but then changed it in the same coding routines in their IDE? How do you merge these changes to decide on the best variant?
Ok "Shared Code Modules", can help, but primarily I am concerned with determining the changes made to the code by the individual programmers, comparing the changes and then deciding on a variant.
This already starts with the definition of variables...
 

Andrew (Digitwell)

Well-Known Member
Licensed User
Longtime User
Really? I have reservations about that. As I understand it, "Shared Code Modules" is rather meant for porting existing and proven solutions into another project.
What about design changes or two simultaneous changes in the same places in the code? How do you decide which variant of the code to use when several developers started with the same code as a base, but then changed it in the same coding routines in their IDE? How do you merge these changes to decide on the best variant?
Ok "Shared Code Modules", can help, but primarily I am concerned with determining the changes made to the code by the individual programmers, comparing the changes and then deciding on a variant.
This already starts with the definition of variables...
All of the issues you mention can be resolved by using source control. take a look at GIT.
 

Andrew (Digitwell)

Well-Known Member
Licensed User
Longtime User
Yes, that is true. As with any binary file and Git.
But in all the time I have been using Git with B4X, I have not had a problem with sharing layouts between developers and having merge problems.

Yes, you do have to be careful occasionally when merging with multiple layouts. But given all of the other advantages, this is more than worth it.
 

LucaMs

Expert
Licensed User
Longtime User
I'm too old to know about this Git.

Maybe I should open a new thread but since it doesn't directly concern B4X and that mine is more of a curiosity...

  1. What about privacy? The managers will be able to read your source codes, I assume, or am I wrong?
  2. Being little interested (now a little more) I'm not sure but I seem to have read that there is a desktop version of that Git, although I don't know if at that point it could be used for the purpose requested by the OP, unless you can use some sort of peer-to-peer.
 
Last edited:

Alessandro71

Well-Known Member
Licensed User
Longtime User
It's the first time I see an issue of privacy of the code: unless you fill your comments with insults to your manager, it should not be a concern...
 

Andrew (Digitwell)

Well-Known Member
Licensed User
Longtime User
  1. What about privacy? The managers will be able to read your source codes, I assume, or am I wrong?
  2. Being little interested (now a little more) I'm not sure but I seem to have read that there is a desktop version of that Git, although I don't know if at that point it could be used for the purpose requested by the OP, unless you can use some sort of peer-to-peer.

Privacy - Yes anyone who is working on the source code can see it. This is nothing to do with the source control system. The only way this can be prevented is by working on the source code alone.

2. You need to read a bit more about how git works. There is a local repository as well as one (or many) remote repositories which are clones of the local repository. You can host the remote on something like GitHub or BitBucket (which I use) or you can host the remote on your own shared server if you wish.
Take a look at this:

I also found this which is a good visual representation.

 

Sandman

Expert
Licensed User
Longtime User
It could also be noted that there are alternatives to Git. I prefer Mercurial, for instance. Seems to me that it's more or less the same, but easier to use and understand. But if one want's to be compatible with the majority out there, Git is absolutely the way to go.

 

Andrew (Digitwell)

Well-Known Member
Licensed User
Longtime User
Sorry misunderstood.

You can host your own git server for the remote repositories.

Some shared hosting provide the tools automatically.
 
Top