views:

215

answers:

12

I work at a small company and we have 2 (possibly 3) developers (myself being one). Although our assignments don't often overlap, I do see that we occasionally write similar, if not the same code. There is also an atmosphere of competition that I think can drive us to write better code, but is dangerous because it sometimes forces one (or both) of us to go dark in hopes to impress the higher-ups with our "cool new code".

Any suggestions (as a manager or developer) on what is a way to encourage developers to work together and to share code and responsibilities?

A: 

I think you should setup goal as a team to be competitive but together.

Daok
A: 

Pair programming is a great way and the best way I know hands down to foster collective ownership of code, information and knowledge transfer and peer review.

Xian
+5  A: 

A good way is to do weekly/bi-weekly code reviews. This gives your programmers a chance to talk about new things that are in place, spreads knowledge of the codebase around, and lets developers say "hey, that looks like something I'm going to need soon."

Informal code reviews tend to work well -- treat them as a show and tell and they help a lot.

Cody Brocious
+1  A: 

Since it looks like Pair Programming won't work for you, having a daily meeting (SCRUM-like) where you discuss the past days challenges and stuff. SHould help improve the information flow as developers do like to brag a little bit. :)

Craig
+1  A: 

Peer code reviews help share the knowledge of what code is out their in your codebase and hopefully prevent duplication

cagcowboy
And it's even better if the reviews are done face-to-face, rather than offline and through a tool...
Xavier Nodet
+2  A: 

VSTS Team System and Agile Scrum Methodoolgy will work better for this :)

Jobi Joy
A: 

Agile Scrums is a great call, I would also reccomend the book "The Five Dysfunctions of a Team" it's not about development, but it's about getting a great team to work together.

Sara Chipps
+1  A: 

I think you should try to get them to believe in the product you are working on and get some team-spirit into the whole thing. Short meetings, once a week, where you talk about what you are going to get done. Appreceate the work your co-workers are doing. After a while, they will appreceate yours too.

And maybe some off-work activity would be helpful to get to know each other better. I work in a similar environment and we sometimes all go out for a beer. Sure, there is some competition, but we all go on pretty well with each other and there is not the sense of trying to be the best in the team. We work together.

Matthias
+1  A: 
  1. Use a code repository. All code must be checked in every day so you can each see what the others are doing.

  2. Have a "Helper" project. Before anyone writes some "cool code" they should look in the Helper project to see if it's already available.

  3. Have a short "heads up" first thing every morning. Each developer talks about what they did yesterday and what they are going to do today.
nzpcmad
A: 

We have a very similar environment and sharing is very much encouraged. What we usually do when we identify some piece of code that can be shared -- usually done through an informal peer review of existing code or identified through a quick meeting or two.

For example, we had a developer create a simple task system that could be used to manage to-dos. We isolated the code and create an application block. This application block can now be easily snapped into any project.

We have created application blocks for things like auditing, attachments, user, roles, parameters and so on. The developer who create the application block is ultimately responsible for it's maintenance. It works pretty well in environment of somewhat lazy programmers who don't want to reinvent the wheel every time!

I think ultimately the key is communication between developers.

mattruma
A: 

More than anything you need to become friends. Then all that other stuff will just disappear.

Christopher Mahan
A: 

Just go for a beer and discuss the stuff :) Competition in this team will help nobody! Try to learn from your colleges, let them learn from you and do not challenge them!

MADMap