function initMessageManager() {
        return lib.i18n.getAcceptLanguages()
          .then((languages) => {
            if (!hterm.messageManager) {
              hterm.messageManager = new lib.MessageManager(languages);
            }
          })
          .then(() => {
            // If OS detection fails, then we'll still set the value to
            // something.  The OS logic in hterm tends to be best effort
            // anyways.
            const initOs = (os) => { hterm.os = os; };
            return lib.f.getOs().then(initOs).catch(initOs);
          });
      }
The hterm init function, registered with lib.registerInit().

This is called during lib.init().

@return {!Promise<void>}