5 Replies - 1520 Views - Last Post: 15 April 2014 - 06:03 AM

#1 Logik22  Icon User is offline

  • D.I.C Head

Reputation: 10
  • View blog
  • Posts: 164
  • Joined: 12-December 11

How to organize coding between 2 programmers?

Posted 11 April 2014 - 06:10 AM

For the past few years I've been writing software for the HVAC industry. At my last job I was working under someone who had been doing that job for over 20 years. At my new job I'm working under an electrical engineer who got pushed in to writing the software. So he doesn't have a background in computer science or in the actual programming environment. The software is proprietary so there isn't much information on it which means he ended up teaching himself. Unfortunately since he doesn't have a background in software he doesn't know a lot of the core principles regarding writing code that is easy to manage and clean overall.

A few of the problems we have is the version number and date is randomly updated. We might be on version 6.2 01/10/2014 , make 30 changes over several months, and then randomly we'll update it to 6.3 04/11/2014. The problem is a controller with 6.2 in February will be different than one in March. Since the version and date are the same we'd have no way to tell them apart. On top of that we don't have a change log so if someone needs to know what the difference between the February version and March version, they're SOL.

Another of my primary concerns is forking. Due to this version control issue I may be working on 6.2 and then later in the day he may start working on 6.2. A few days later he'll put his version on the network and it will be on me to combine the 2 copies. To me it would be easier if he would have just said he was making a change, then I'd put my version on the network for him, he'd apply his changes, then I'd continue working on it after he's done. We're working on communicating better but there will always be a chance for human error. I'm not sure of what we can do to minimize this though. We have about 8 programs we must manage so sometimes it can get hectic with some of the deadlines.

There are a few other minor issues that are just a matter of me going through all the programs and fixing them. Stuff like lack of consistency between the organization of the program, variable names, UI, etc.



With all that being said, I would really like to clean this up and get things moving more efficiency. The problem is I'm not sure how to approach this since he's my boss and I don't have as much experience as him in this type of work. Any suggestions on how I should handle this and/or guidelines that both of us can follow to make it easier on ourselves? I'm having trouble finding ways that wouldn't involve working on the software for 10 minutes and then updating document for 20 minutes.

Is This A Good Question/Topic? 0
  • +

Replies To: How to organize coding between 2 programmers?

#2 Skydiver  Icon User is offline

  • Code herder
  • member icon

Reputation: 3590
  • View blog
  • Posts: 11,168
  • Joined: 05-May 12

Re: How to organize coding between 2 programmers?

Posted 11 April 2014 - 06:26 AM

Maximize the use of your version control system. Use developer branches where you both individually make your changes. Have the main trunk where both of your changes are merged into. And have release branches for each build that gets released to a customer.

Use continuous integration. Jenkins is pretty good, but there also out there. Have the CI server build all branches whenever something gets checked in. With the CI server, as part of your build script you can automate the version stamping. A nice feature of Jenkins is that you can have it "fingerprint" the generated builds, so that even if you didn't update the version stamps, you can always hand the binary back to Jenkins, ask for its fingerprints, and get back the build number that created that binary.
Was This Post Helpful? 2
  • +
  • -

#3 Skydiver  Icon User is offline

  • Code herder
  • member icon

Reputation: 3590
  • View blog
  • Posts: 11,168
  • Joined: 05-May 12

Re: How to organize coding between 2 programmers?

Posted 11 April 2014 - 06:42 AM

Also, another way to inculcate some good development skills, is propose to do some "pair programming". Float it as a way so that you can learn more from his experience, as well as, get to know his coding style more, but hopefully, he also sees the value in the good practices that you will be showing him when are controlling the keyboard.

http://guide.agileal...de/pairing.html
Was This Post Helpful? 2
  • +
  • -

#4 ArtificialSoldier  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 400
  • View blog
  • Posts: 1,465
  • Joined: 15-January 14

Re: How to organize coding between 2 programmers?

Posted 11 April 2014 - 10:18 AM

Just to be completely explicit - it sounds like you need to start using a version control system if you are not using one now. It is still up to you to update the version text that your program displays, but every individual change to any part of the system will be considered a new revision number. You can export a particular revision if you want to install that, or you can export the current revision. Multiple people would each need a client application installed which will let them check out the code to work on it, and then commit their changes. When multiple people commit changes then the version control system will figure out how to reconcile those, and if it gets stuck then it will ask you to resolve the conflicts manually. You can create branches to work on specific features, and when you're done with the feature and testing then you integrate the branch back into the main trunk to move the changes over to the stable version. You can either fix bugs directly on the trunk, or make a different branch for each bug fix or group of fixes. You can make branches or tags for individual versions, so that you can always export a specific version. It will keep track of every change made to every file and who made the change and when.

http://en.wikipedia....Version_control

Subversion is probably the most popular centralized system, and Git is probably the most popular decentralized system.
Was This Post Helpful? 1
  • +
  • -

#5 jon.kiparsky  Icon User is online

  • Pancakes!
  • member icon


Reputation: 7807
  • View blog
  • Posts: 13,203
  • Joined: 19-March 11

Re: How to organize coding between 2 programmers?

Posted 14 April 2014 - 07:42 PM

I would add to Skydiver's suggestions that you would really like to communicate better about what you're working on. Particularly, you'd like to have some way to know what the other guy is going to be taking on next, or at least what's up for work next. That lets you stay out of each other's way. There are a number of ways to go about this, and the one you choose will depend to some extent on your circumstances and needs - you might have features scheduled for bid, or you might have a sort of kanban system where you're drawing features based on priority and a discipline of "avoinding pileup", or you might just get together in the morning and pull work for the day, or whatever - the point is, you'd like to avoid wasting time in merges as much as possible, because that is pointless timewasting. And with only two of you working, it should be possible to work in non-conflicting areas.

Another thought: From your description and tone, it sounds like you might not have an entirely productive and cooperative working relationship with your other party. That's something that you should try to work out. This is a delicate piece of work, but if they're not playing nice out of some sort of malice, no amount of process will really solve the problem.
You should approach this carefully, since it's a bit of a minefield, but I'd take a sort of conciliatory approach: "Hey, Bob, I notice that you seem sort of frustrated. Is there something that I'm doing that I need to change so we can smooth this out?" This usually puts people in the best mood to work with you, I've found. Among other things, it's very difficult for them to not respond to such a gracious enquiry with some concessions of their own.
Was This Post Helpful? 1
  • +
  • -

#6 Skydiver  Icon User is offline

  • Code herder
  • member icon

Reputation: 3590
  • View blog
  • Posts: 11,168
  • Joined: 05-May 12

Re: How to organize coding between 2 programmers?

Posted 15 April 2014 - 06:03 AM

Some people, management in particular, are averse to the idea of agile development, but it doesn't mean that you can't use some of the practices from agile. I mentioned pair programming above, but another concept to reinforce jon.kiparsky's very insightful post about communication is to consider holding a very informal "scrum" between the two of you. Take 5-15 minutes to talk about what you did yesterday, what you are planning on working on today, and any stumbling blocks you hit. It doesn't have to have the full ceremony of needing a scrum master. Just take time to communicate.
Was This Post Helpful? 1
  • +
  • -

Page 1 of 1