whereEndoEphemeralState = (platform, env, info) => {
  if (env.XDG_RUNTIME_DIR !== undefined) {
    return `${env.XDG_RUNTIME_DIR}/endo`;
  } else if (platform === 'win32') {
    return `${whereHomeWindows(env, info)}\\Temp\\Endo`;
  }
  const temp = env.TMPDIR !== undefined ? env.TMPDIR : info.temp;
  const user = env.USER !== undefined ? env.USER : info.user;
  return `${temp}/endo-${user}`;
}
Returns the most suitable location for storing state that ideally does not
persist between restarts or reboots, specifically PID files.

@type {typeof import('./types.js').whereEndoEphemeralState}