title: Git merge feature branches on deploy with Rails
body: <p>I am looking for a simple way to merge feature branches into my development branch on deployment, while still keeping them separate in my repository.</p>
  
  <p>I am deploying my develop branch to my staging server, but want to prevent issues from multiple developers pushing many feature branches in the development branch which would make it difficult to create releases with certain features.</p>
  
  <p>Ideally, I have the following branches:</p>
  
  <p>develop
  feature1
  feature2</p>
  
  <p>On deployment, the following is done:</p>
  
  <p>Merge: develop + feature1 + feature2 (though keep these branches separate identities in the repository)
   and then deploy to the staging server</p>
  
  <p>I am using Capistrano, and figured I may be able to maintain a separate staging branch, and dynamically merge and push these branches based on a file that holds the feature branch names, but I am not sure of an elegant way to accomplish this with Capistrano. </p>