Ever Wonder What a Failing Hard Drive Sounds Like?


More to the point, that's the sound of a HDD failure on a third party server we were using for our Gerrit instance. We were able to restore to a backup but it was not as recent as we would have liked. So if you have submitted, unmerged changes since October 18, and still have them locally, here is what you can do:

  1. Navigate to your working omni folder, i.e. ~/android/omni
  2. Run 'repo status' to see the list of projects you were working on and their locations
  3. Navigate to the location of the repo you want to repush
  4. Type 'git log' and note the commit hash (sha1) you want
  5. Navigate back to your working omni folder
  6. Type 'repo start <branchName> <directoryOfPackageChanged>'
    (NOTE: it is important to use relative path names to where you are in your repo)

    • EXAMPLE: repo start bootAnimation vendor/omni
  7. Navigate to the directory
  8. Type 'git cherry-pick <sha1_noted_before>'
  9. Now type 'repo upload'

You should be good to go. We have already put plans and hardware in place to ensure this does not happen again, and Gerrit should return within the next hour or so once DNS changes propogate. Now here's to making more bacon!