I was trying to flash a new ROM, but can't get it to boot. Usually, I would have just booted into my recovery and restored my last backup. But I can't do that now as my power button is broken and it is impossible to select the "backup and recover" option after booting into the recovery.
Unfortunately send key events via ADB in recovery mode is impossible, otherwise navigating through the recovery options menu would have been easy.
But fortunately, my version of CWM supports the soft keys on my phone. The 'search' button substituted as the selection button (usually the job of the power button). Using that, I was able to navigate into the backup and restore menu and restore my phone.
Hope this helps someone in the future.
You can compile your own version of ClockWorkMod. While I haven't done it myself, I know that each phone port of CWM has different key layouts, so it should be a simple question to a developer who has ported CWM to their phone. Find out the keycodes for the rest of the keys on your phone, then remap the keys in the source of CWM.
Alternatively, you can write a script that runs when you boot into CWM. You can tell the script backup, restore, install a new Rom, etc. See this forum for a push in the right direction.
@vr3690, it is very much possible. You just gotta study the events.
Here's something that's gonna help: http://forum.xda-developers.com/showthread.php?t=1875094