What is the correct way to deal with similar but independent features?
- by Koviko
Let's say we have a feature request come in and we begin work on it, which we'll call feature-1. It introduces some new logic to the application, which we'll call logic-A and logic-B. A programmer branches from the release branch and begins work on the feature.
Soon after, we get another feature request, which we'll call feature-2. It will implement logic-A and logic-C into the application. The logic A being implemented by this feature is the same logic-A as was implemented in feature-1.
Let's also say that given logic-B, logic-A might be implemented slightly differently than it would have been given logic-C, and also differently given both logic-B and logic-C (eg. with only one feature, the code would be less flexible than with both).
How should this situation be handled?
Concrete Example (to help with any confusion in my wording)
feature-1 is a feed from programmers.stackexchange.com.
feature-2 is a feed from gaming.stackexchange.com.
logic-A is the implementation of a feed at all (assuming the application currently has no feeds), which links to the content as well and gives related information.
logic-B is that the feed's source is from programmers.stackexchange.com.
Adds to logic-A that the related programming language is displayed.
logic-C is that the feed's source is from gaming.stackexchange.com.
Adds to logic-A that the related game's name and box art is displayed.