Repository: electron-userland/electron-builder
File: packages/builder-util-runtime/src/publishOptions.ts (TypeScript)

Code before:
   */
  readonly private?: boolean | null

  /**
   * The channel.
   * @default latest
   */
  readonly channel?: string | null

  /**
   * The type of release. By default `draft` release will be created.
   *
   * Also you can set release type using environment variable. If `EP_DRAFT`is set to `true` — `draft`, if `EP_PRE_RELEASE`is set to `true` — `prerelease`.
   * @default draft
   */
  releaseType?: "draft" | "prerelease" | "release" | null
}

/** @private */
export function githubUrl(options: GithubOptions, defaultHost = "github.com") {
  return `${options.protocol || "https"}://${options.host || defaultHost}`
}

export function githubTagPrefix(options: GithubOptions) {
  if (options.tagNamePrefix) return options.tagNamePrefix
  if (options.vPrefixedTagName ?? true) return 'v'
  return ''
}

/**
 * [GitLab](https://docs.gitlab.com/ee/user/project/releases/) options.
 *
 * GitLab [personal access token](https://docs.gitlab.com/ee/user/profile/personal_access_tokens.html) is required for private repositories. You can generate one by going to your GitLab profile settings.
 * Define `GITLAB_TOKEN` environment variable.
 */
export interface GitlabOptions extends PublishConfiguration {
  /**
   * The provider. Must be `gitlab`.
   */
  readonly provider: "gitlab"

  /**
   * The GitLab project ID or namespace/project-name.
   */
  readonly projectId: string | number

  /**
   * The host (including the port if needed).
   * @default gitlab.com
   */
  readonly host?: string | null

Review comment (suggestion):
Since we're creating a new prop that basically is duplicating `tagNamePrefix`, what are your thoughts on marking `@deprecated please use #tagNamePrefix` to the `vPrefixedTagName` prop?

Also, for if-statements, please use multi-line
```
if (options.tagNamePRefix) {
   return options.tagNamePrefix
}
```

Code after:
   * Whether to use private github auto-update provider if `GH_TOKEN` environment variable is defined. See [Private GitHub Update Repo](./auto-update.md#private-github-update-repo).
   */
  readonly private?: boolean | null

  /**
   * The channel.
   * @default latest
   */
  readonly channel?: string | null

  /**
   * The type of release. By default `draft` release will be created.
   *
   * Also you can set release type using environment variable. If `EP_DRAFT`is set to `true` — `draft`, if `EP_PRE_RELEASE`is set to `true` — `prerelease`.
   * @default draft
   */
  releaseType?: "draft" | "prerelease" | "release" | null
}

/** @private */
export function githubUrl(options: GithubOptions, defaultHost = "github.com") {
  return `${options.protocol || "https"}://${options.host || defaultHost}`
}

export function githubTagPrefix(options: GithubOptions) {
  if (options.tagNamePrefix) {
    return options.tagNamePrefix
  }
  if (options.vPrefixedTagName ?? true) {
    return 'v'
  }
  return ''
}

/**
 * [GitLab](https://docs.gitlab.com/ee/user/project/releases/) options.
 *
 * GitLab [personal access token](https://docs.gitlab.com/ee/user/profile/personal_access_tokens.html) is required for private repositories. You can generate one by going to your GitLab profile settings.
 * Define `GITLAB_TOKEN` environment variable.
 */
export interface GitlabOptions extends PublishConfiguration {
  /**
   * The provider. Must be `gitlab`.
   */
  readonly provider: "gitlab"

  /**
   * The GitLab project ID or namespace/project-name.
   */
  readonly projectId: string | number