Ever Wonder What a Failing Hard Drive Sounds Like?03 Nov 2013
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:
- Navigate to your working omni folder, i.e. ~/android/omni
- Run 'repo status' to see the list of projects you were working on and their locations
- Navigate to the location of the repo you want to repush
- Type 'git log' and note the commit hash (sha1) you want
- Navigate back to your working omni folder
- 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
- Navigate to the directory
- Type 'git cherry-pick <sha1_noted_before>'
- 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!