Skip to content

Commit

Permalink
fix: Only use GitHub releases to update Bazelisk (#29847)
Browse files Browse the repository at this point in the history
  • Loading branch information
mark-thm committed Jun 25, 2024
1 parent 23794fc commit f70cbc6
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
8 changes: 4 additions & 4 deletions lib/modules/manager/bazelisk/extract.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ describe('modules/manager/bazelisk/extract', () => {
expect(res.deps).toEqual([
{
currentValue: '5.2.0',
datasource: 'github-tags',
datasource: 'github-releases',
depName: 'bazel',
packageName: 'bazelbuild/bazel',
},
Expand All @@ -19,7 +19,7 @@ describe('modules/manager/bazelisk/extract', () => {
expect(res.deps).toEqual([
{
currentValue: '5.2',
datasource: 'github-tags',
datasource: 'github-releases',
depName: 'bazel',
packageName: 'bazelbuild/bazel',
},
Expand All @@ -31,7 +31,7 @@ describe('modules/manager/bazelisk/extract', () => {
expect(res.deps).toEqual([
{
currentValue: 'latestn',
datasource: 'github-tags',
datasource: 'github-releases',
depName: 'bazel',
packageName: 'bazelbuild/bazel',
},
Expand All @@ -43,7 +43,7 @@ describe('modules/manager/bazelisk/extract', () => {
expect(res.deps).toEqual([
{
currentValue: '5.2.0',
datasource: 'github-tags',
datasource: 'github-releases',
depName: 'bazel',
packageName: 'bazelbuild/bazel',
},
Expand Down
4 changes: 2 additions & 2 deletions lib/modules/manager/bazelisk/extract.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import { GithubTagsDatasource } from '../../datasource/github-tags';
import { GithubReleasesDatasource } from '../../datasource/github-releases';
import type { PackageDependency, PackageFileContent } from '../types';

export function extractPackageFile(content: string): PackageFileContent {
const dep: PackageDependency = {
depName: 'bazel',
currentValue: content.split('\n', 2)[0].trim(),
datasource: GithubTagsDatasource.id,
datasource: GithubReleasesDatasource.id,
packageName: 'bazelbuild/bazel',
};
return { deps: [dep] };
Expand Down
4 changes: 2 additions & 2 deletions lib/modules/manager/bazelisk/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import type { Category } from '../../../constants';
import { GithubTagsDatasource } from '../../datasource/github-tags';
import { GithubReleasesDatasource } from '../../datasource/github-releases';
import * as semverVersioning from '../../versioning/semver';

export { extractPackageFile } from './extract';
Expand All @@ -12,4 +12,4 @@ export const defaultConfig = {

export const categories: Category[] = ['bazel'];

export const supportedDatasources = [GithubTagsDatasource.id];
export const supportedDatasources = [GithubReleasesDatasource.id];

0 comments on commit f70cbc6

Please sign in to comment.