Surfacing ycmd server PID to user scripts

To get the PID, call function youcompleteme#ServerPid().
Printing server PID in YcmDebugInfo