diff --git a/packages/nx/src/command-line/release/utils/github.ts b/packages/nx/src/command-line/release/utils/github.ts index 3b484dc289375..1de5e4578cf74 100644 --- a/packages/nx/src/command-line/release/utils/github.ts +++ b/packages/nx/src/command-line/release/utils/github.ts @@ -29,6 +29,7 @@ interface GithubRequestConfig { token: string | null; } +// https://docs.github.com/en/rest/releases/releases?apiVersion=2022-11-28#create-a-release--parameters interface GithubRelease { id?: string; tag_name: string; @@ -37,6 +38,7 @@ interface GithubRelease { body?: string; draft?: boolean; prerelease?: boolean; + make_latest?: 'legacy' | boolean; } export interface GithubRepoData { @@ -310,6 +312,8 @@ async function syncGithubRelease( name: release.version, body: release.body, prerelease: release.prerelease, + // legacy specifies that the latest release should be determined based on the release creation date and higher semantic version. + make_latest: 'legacy', }; try {