Steps to deploy a new version from development

  1. Make sure you are on the develop branch and are up to date with what is on the remote git/TFS server
  2. Branch from develop into release-X.Y.Z where X.Y.Z is the to-be-released version number
  3. Update version number and release date in code and verify version history
  4. Merge the release branch back into develop and push develop to the remote origin
  5. Back-up the existing version on the production server. Open \\SERVER in Explorer. Right-click on the NVCC directory and select "Send to" -> "Compressed (zip) folder". After the "Compressing..." dialog finishes, change the resulting filename NVCC.zip to NVCC_N.N.N_YYYYMMDD where N.N.N is the previous version number and YYYYMMDD is the current date in four-digit year, month, day format (without delimiters). (e.g. NVCC_1.6.2_20160916.zip)
  6. Deployment. Change back to the release branch and publish to production.
  7. If any changes were needed to be able to publish, commit these changes to the release branch and then merge these changes back into develop (see above step for details). Hopefully, this step should not be necessary.
  8. Merge the release branch into master
  9. Tag the master branch with a tag of the format vX.Y.Z. Give it the commit message "Version X.Y.Z"
  10. Push the master branch to the remote origin, including the new tag.
  11. Change back to develop branch to guard against inadvertent commits to the master branch.
  12. Delete the release branch since it has been completely merged into both develop and master
  13. Notify users of updated version. Include the most recent changes that are listed in News.cshtml. (what protocol?)

Steps to re-deploy the current release

  1. Checkout the master branch of the repository
  2. Verify the checkout is clean and up-to-date
  3. Deployment

Steps to rollback to a previous release

  1. Make sure you have the most recent updates from the central repository

  2. Determine the tag corresponding to the version you want to rollback to. A list of all the tagged versions can be gotten with

    or more detail (including tag date and message) with

  3. Checkout the appropriate tag based on its short tag name

    You will get a message like

     Note: checking out 'v1.6.0'.
    
     You are in 'detached HEAD' state. You can look around, make experimental
     changes and commit them, and you can discard any commits you make in this
     state without impacting any branches by performing another checkout.
    
     If you want to create a new branch to retain commits you create, you may
     do so (now or later) by using -b with the checkout command again. Example:
    
       git checkout -b <new-branch-name>
    
     HEAD is now at 12ade2d... Merge branch 'release-1.6.0'
    

    with tags, SHA's and messages appropriate to your release

  4. Deployment

  5. Return your working directory to a usable state (develop or whatever branch you were working on)

Steps to create a hotfix

A hotfix differs from a regular release in that it is an urgent, typically small change to the tool. It specifically is not to include any of the development that has been done (and merged into develop) since the last release. Typically, the decision that a hotfix is needed is made even before any code that will go into the hotfix is written. A hotfix starts from master, and its changes will go both into master for production and develop so that they are not lost in later version.

  1. Make sure you have a clean repository; stash active changes on your active branch, if any
  2. Checkout the master branch of the repository
  3. Verify the checkout is clean and up-to-date
  4. Branch from master into hotfix-X.Y.Z where X.Y.Z is the to-be-released version number. Typically, this will just be an increment of Z
  5. Make whatever changes are needed to fix the problem that this hotfix is meant to solve. Commit these changes to the hotfix branch.
  6. Update version number and release date in code and verify version history
  7. Merge the hotfix branch back into develop and push develop to the remote origin
  8. Deployment. Change back to the hotfix branch and publish to production.
  9. If any changes were needed to be able to publish, commit these changes to the hotfix branch and then merge these changes back into develop (see above step for details). Hopefully, this step should not be necessary.
  10. Merge the hotfix branch into master
  11. Tag the master branch with a tag of the format vX.Y.Z. Give it the commit message "Version X.Y.Z"
  12. Push the master branch to the remote origin, including the new tag.
  13. Change back to develop branch to guard against inadvertent commits to the master branch.
  14. Delete the hotfix branch since it has been completely merged into both develop and master
  15. Notify users of updated version. Include the most recent changes that are listed in News.cshtml. (what protocol?)