views:

74

answers:

2

I was just looking through my system and have a lot of old projects that have multiple backups and versions (yes I know, it's before I started using source control properly ;) )

The thing is, some of these apps are used everyday by my company and many may have a lot of code that may be useful to other projects.

So I am wanting to go through each one and delete all the rubbish that will never get used. Do like a final build and put all useful projects into one repositry under version control to allow easy updates etc.

All that is simple yeah but then there are a couple of the LARGE projects that the code is real ugly which I would like to refactor and also start building a library of bits that are useful.

What would be a good strategy for this? What do you do to store reusable code that you can recall?

+2  A: 

I'd start by inserting the newest edition of each in source-control.

This is going to be a laborious process, but getting it into a 'standard' state will help a lot.

Refactoring can happen afterwards.

warren
+2  A: 

I would just stick them all in a repository and forget about them until they needed work/changes - then spend time on them. If they are dormant there is no reason to wake them up...

Work on them (to improve them) when they are modified for defect fixes, features, etc.

If you really want to create a "re-use library" then identify the things you want to provide and look through your code to find useful code, classes, etc. Unless you have real buy-in from people it might be a wasted effort for the company (but it is very useful for those involved - for the experience)

You can also use this as an exercise to incorporate daily (or at least automated) build framework.

Tim