Add confirmation dialog to checkoutHead

There have been a few reports of files mysteriously going back to the
last version in the tree. My theory is that it is because of people
fat-fingering the Undo command because the default keyboard mapping is
too similar. This will at least prevent most accidental data loss.
Add config option for checkoutHead confirmation

Per the discussion with @kevinsawicki in #3168, I have added a config
option `editor.confirmCheckoutHead` that defaults to `true`. When the
`editor:checkout-head-revision` command is executed, a confirmation
dialog now shows that states which file is to be reverted and asks the
user to "Revert" or "Cancel". If the config option is set to `false`,
the old behavior, simply reverting without prompting, is used.

I also added tests to ensure that the confirmation dialog is displayed
or not in the right configurations.
Add a step to revert unsaved changes

I took the key part from PR #3183 and added it to the post-confirmation
flow.
Only focus when the component is mounted
Add `will-insert-text` and `did-insert-text` to `insertText()`
::getModel() returns the editor
Sometimes there might not be a selection.
Need to return a range when the text is inserted
Remove duplicate getModel()
preventDefault -> cancel()
Fix specs
Revert "Sometimes there might not be a selection."

This reverts commit a73e6e5bd07e07f38ee5295a33d919a92e2e2635.
Merge pull request #3241 from atom/bo-add-will-insert

Add will-insert-event with cancel() function
Upgrade autocomplete to fix #3242
Shim ReactEditorView::mini property
Handle 'focus' events in ReactEditorView and transfer to the component

Fixes #3234
Use wmic to kill child processes
Remove comment about killing process
Kill parent process after children on Windows
Return undefined from BufferedProcess::kill