public function getCliConfigFile() {
    $file = NULL;
    if (DIRECTORY_SEPARATOR == '\\') {
      $user = $_SERVER['USERNAME'];
      $home_dir = $_SERVER['USERPROFILE'];
    }
    else {
      $user = posix_getpwuid(posix_getuid());
      $home_dir = $user['dir'];
    }

    if (strstr(getenv('SHELL'), 'zsh')) {
      $file = $home_dir . '/.zshrc';
    }
    elseif (file_exists($home_dir . '/.bash_profile')) {
      $file = $home_dir . '/.bash_profile';
    }
    elseif (file_exists($home_dir . '/.bashrc')) {
      $file = $home_dir . '/.bashrc';
    }
    elseif (file_exists($home_dir . '/.profile')) {
      $file = $home_dir . '/.profile';
    }
    elseif (file_exists($home_dir . '/.functions')) {
      $file = $home_dir . '/.functions';
    }

    return $file;
  }