Skip to content

Commit

Permalink
Merge branch 'renovatebot:main' into feat/replacement-part-auto-replace
Browse files Browse the repository at this point in the history
  • Loading branch information
t-kulmburg authored Nov 9, 2022
2 parents 2d4767d + fb56b1f commit 79365b8
Show file tree
Hide file tree
Showing 144 changed files with 1,039 additions and 550 deletions.
2 changes: 1 addition & 1 deletion .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM containerbase/node:18.12.0@sha256:dab36a9935ce28f0e2cdf25083a3d810fff98877832f13a239a1e30714829b12
FROM containerbase/node:18.12.1@sha256:fe459c9670594c2beb3dfbbd23c51905e6f85c865735f88265790d47bc569a9e

USER root

Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@18fe527fa8b29f134bb91f32f1a5dc5abb15ed7f # tag=v2.1.30
uses: github/codeql-action/init@c3b6fce4ee2ca25bc1066aa3bf73962fda0e8898 # tag=v2.1.31
with:
languages: javascript

Expand All @@ -40,7 +40,7 @@ jobs:
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@18fe527fa8b29f134bb91f32f1a5dc5abb15ed7f # tag=v2.1.30
uses: github/codeql-action/autobuild@c3b6fce4ee2ca25bc1066aa3bf73962fda0e8898 # tag=v2.1.31

# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl
Expand All @@ -54,4 +54,4 @@ jobs:
# make release

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@18fe527fa8b29f134bb91f32f1a5dc5abb15ed7f # tag=v2.1.30
uses: github/codeql-action/analyze@c3b6fce4ee2ca25bc1066aa3bf73962fda0e8898 # tag=v2.1.31
18 changes: 18 additions & 0 deletions data/azure-pipelines-tasks.json
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,8 @@
"1.131.0"
],
"archivefiles": [
"2.213.0",
"2.211.1",
"2.211.0",
"2.206.0",
"2.201.2",
Expand Down Expand Up @@ -1323,6 +1325,7 @@
"3.0.0"
],
"azurermwebappdeployment": [
"3.213.0",
"3.208.0",
"3.198.0",
"3.195.1",
Expand Down Expand Up @@ -1373,6 +1376,7 @@
"3.4.2",
"3.4.1",
"3.4.0",
"4.213.0",
"4.212.0",
"4.208.1",
"4.208.0",
Expand Down Expand Up @@ -2544,6 +2548,7 @@
"0.148.0"
],
"downloadpackage": [
"0.213.0",
"0.210.0",
"0.208.1",
"0.208.0",
Expand Down Expand Up @@ -2751,6 +2756,8 @@
"0.0.1"
],
"extractfiles": [
"1.213.0",
"1.211.1",
"1.211.0",
"1.200.0",
"1.198.0",
Expand Down Expand Up @@ -4172,6 +4179,7 @@
"1.0.0"
],
"nodetool": [
"0.213.0",
"0.211.0",
"0.210.1",
"0.210.0",
Expand Down Expand Up @@ -4273,6 +4281,7 @@
"0.2.25",
"0.2.24",
"0.2.23",
"1.213.0",
"1.208.1",
"1.208.0",
"1.202.0",
Expand Down Expand Up @@ -5114,6 +5123,7 @@
"0.135.0"
],
"pythonscript": [
"0.213.0",
"0.200.0",
"0.198.0",
"0.182.0",
Expand Down Expand Up @@ -5396,6 +5406,7 @@
"1.0.0"
],
"ssh": [
"0.213.0",
"0.207.1",
"0.207.0",
"0.200.0",
Expand Down Expand Up @@ -5620,6 +5631,7 @@
"1.0.0"
],
"usenode": [
"1.213.0",
"1.210.0",
"1.208.1",
"1.208.0",
Expand Down Expand Up @@ -5664,6 +5676,8 @@
"1.0.0"
],
"usepythonversion": [
"0.213.1",
"0.213.0",
"0.206.0",
"0.205.0",
"0.200.0",
Expand Down Expand Up @@ -5696,6 +5710,7 @@
"0.134.2"
],
"userubyversion": [
"0.213.0",
"0.200.0",
"0.198.0",
"0.193.0",
Expand Down Expand Up @@ -5948,6 +5963,7 @@
"2.1.0"
],
"xamarinandroid": [
"1.213.0",
"1.212.0",
"1.208.0",
"1.200.0",
Expand Down Expand Up @@ -5987,6 +6003,7 @@
"1.135.0"
],
"xamarinios": [
"2.213.0",
"2.200.1",
"2.200.0",
"2.198.0",
Expand Down Expand Up @@ -6027,6 +6044,7 @@
"1.135.0"
],
"xcode": [
"5.213.0",
"5.200.0",
"5.198.1",
"5.198.0",
Expand Down
5 changes: 5 additions & 0 deletions data/debian-distro-info.json
Original file line number Diff line number Diff line change
Expand Up @@ -129,5 +129,10 @@
"codename": "Trixie",
"series": "trixie",
"created": "2023-08-01"
},
"v14": {
"codename": "Forky",
"series": "forky",
"created": "2025-08-01"
}
}
2 changes: 1 addition & 1 deletion data/node-js-schedule.json
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@
"lts": "2022-10-25",
"maintenance": "2023-10-18",
"end": "2025-04-30",
"codename": ""
"codename": "Hydrogen"
},
"v19": {
"start": "2022-10-18",
Expand Down
6 changes: 3 additions & 3 deletions data/ubuntu-distro-info.json
Original file line number Diff line number Diff line change
Expand Up @@ -274,10 +274,10 @@
"eol": "2023-07-20"
},
"v23.04": {
"codename": "L L",
"series": "l-series",
"codename": "Lunar Lobster",
"series": "lunar",
"created": "2022-10-20",
"release": "2023-04-27",
"release": "2023-04-20",
"eol": "2024-01-25"
}
}
2 changes: 1 addition & 1 deletion docs/usage/docker.md
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,7 @@ To get access to the token a custom Renovate Docker image is needed that include
The Dockerfile to create such an image can look like this:
```Dockerfile
FROM renovate/renovate:34.9.1
FROM renovate/renovate:34.20.0
# Include the "Docker tip" which you can find here https://cloud.google.com/sdk/docs/install
# under "Installation" for "Debian/Ubuntu"
RUN ...
Expand Down
31 changes: 16 additions & 15 deletions lib/constants/programming-language.ts
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
// eslint-disable-next-line typescript-enum/no-enum
export enum ProgrammingLanguage {
Dart = 'dart',
Docker = 'docker',
Elixir = 'elixir',
Golang = 'golang',
Java = 'java',
JavaScript = 'js',
NET = 'dotnet',
NodeJS = 'node',
PHP = 'php',
Python = 'python',
Ruby = 'ruby',
Rust = 'rust',
}
export const programmingLanguages = [
'dart',
'docker',
'elixir',
'golang',
'java',
'js',
'dotnet',
'node',
'php',
'python',
'ruby',
'rust',
] as const;

export type ProgrammingLanguage = typeof programmingLanguages[number];
4 changes: 2 additions & 2 deletions lib/modules/datasource/crate/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { GlobalConfig } from '../../../config/global';
import type { RepoGlobalConfig } from '../../../config/types';
import { EXTERNAL_HOST_ERROR } from '../../../constants/error-messages';
import * as memCache from '../../../util/cache/memory';
import { RegistryFlavor, RegistryInfo } from './types';
import type { RegistryInfo } from './types';
import { CrateDatasource } from '.';

jest.mock('simple-git');
Expand Down Expand Up @@ -361,7 +361,7 @@ describe('modules/datasource/crate/index', () => {
const info: RegistryInfo = {
rawUrl: 'https://example.com',
url: new URL('https://example.com'),
flavor: RegistryFlavor.Cloudsmith,
flavor: 'cloudsmith',
};
const crateDatasource = new CrateDatasource();
await expect(
Expand Down
18 changes: 9 additions & 9 deletions lib/modules/datasource/crate/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import { parseUrl } from '../../../util/url';
import * as cargoVersioning from '../../versioning/cargo';
import { Datasource } from '../datasource';
import type { GetReleasesConfig, Release, ReleaseResult } from '../types';
import {
import type {
CrateMetadata,
CrateRecord,
RegistryFlavor,
Expand Down Expand Up @@ -125,7 +125,7 @@ export class CrateDatasource extends Datasource {
info: RegistryInfo,
packageName: string
): Promise<CrateMetadata | null> {
if (info.flavor !== RegistryFlavor.CratesIo) {
if (info.flavor !== 'crates.io') {
return null;
}

Expand Down Expand Up @@ -165,7 +165,7 @@ export class CrateDatasource extends Datasource {
return readCacheFile(path, 'utf8');
}

if (info.flavor === RegistryFlavor.CratesIo) {
if (info.flavor === 'crates.io') {
const crateUrl =
CrateDatasource.CRATES_IO_BASE_URL +
CrateDatasource.getIndexSuffix(packageName.toLowerCase()).join('/');
Expand All @@ -187,9 +187,9 @@ export class CrateDatasource extends Datasource {
packageName: string
): string {
switch (info.flavor) {
case RegistryFlavor.CratesIo:
case 'crates.io':
return `https://crates.io/crates/${packageName}`;
case RegistryFlavor.Cloudsmith: {
case 'cloudsmith': {
// input: https://dl.cloudsmith.io/basic/$org/$repo/cargo/index.git
const tokens = info.url.pathname.split('/');
const org = tokens[2];
Expand Down Expand Up @@ -238,11 +238,11 @@ export class CrateDatasource extends Datasource {

let flavor: RegistryFlavor;
if (url.hostname === 'crates.io') {
flavor = RegistryFlavor.CratesIo;
flavor = 'crates.io';
} else if (url.hostname === 'dl.cloudsmith.io') {
flavor = RegistryFlavor.Cloudsmith;
flavor = 'cloudsmith';
} else {
flavor = RegistryFlavor.Other;
flavor = 'other';
}

const registry: RegistryInfo = {
Expand All @@ -251,7 +251,7 @@ export class CrateDatasource extends Datasource {
url,
};

if (flavor !== RegistryFlavor.CratesIo) {
if (flavor !== 'crates.io') {
if (!GlobalConfig.get('allowCustomCrateRegistries')) {
logger.warn(
'crate datasource: allowCustomCrateRegistries=true is required for registries other than crates.io, bailing out'
Expand Down
10 changes: 4 additions & 6 deletions lib/modules/datasource/crate/types.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,12 @@
// eslint-disable-next-line typescript-enum/no-enum
export enum RegistryFlavor {
export type RegistryFlavor =
/** https://crates.io, supports rawgit access */
CratesIo,
| 'crates.io'

/** https://cloudsmith.io, needs git clone */
Cloudsmith,
| 'cloudsmith'

/** unknown, assuming private git repository */
Other,
}
| 'other';

export interface RegistryInfo {
flavor: RegistryFlavor;
Expand Down
4 changes: 2 additions & 2 deletions lib/modules/datasource/go/base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ export class BaseGoDatasource {
logger.trace({ goModule }, 'go-source header prefix not match');
return null;
}
logger.debug({ goModule, goSourceUrl }, 'Go lookup source url');
logger.debug(`Go lookup source url ${goSourceUrl} for module ${goModule}`);
return this.detectDatasource(goSourceUrl, goModule);
}

Expand Down Expand Up @@ -186,7 +186,7 @@ export class BaseGoDatasource {
return null;
}

logger.debug({ goModule, goImportURL }, 'Go lookup import url');
logger.debug(`Go module: ${goModule} lookup import url ${goImportURL}`);
// get server base url from import url
const parsedUrl = URL.parse(goImportURL);

Expand Down
8 changes: 3 additions & 5 deletions lib/modules/datasource/go/common.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,9 @@ import { getSourceUrl as gitlabSourceUrl } from '../gitlab-tags/util';

import type { DataSource } from './types';

// eslint-disable-next-line typescript-enum/no-enum
export enum GoproxyFallback {
WhenNotFoundOrGone = ',',
Always = '|',
}
export type GoproxyFallback =
| ',' // WhenNotFoundOrGone
| '|'; // Always

export function getSourceUrl(
dataSource?: DataSource | null
Expand Down
11 changes: 3 additions & 8 deletions lib/modules/datasource/go/releases-goproxy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { newlineRegex, regEx } from '../../../util/regex';
import { Datasource } from '../datasource';
import type { GetReleasesConfig, Release, ReleaseResult } from '../types';
import { BaseGoDatasource } from './base';
import { GoproxyFallback, getSourceUrl } from './common';
import { getSourceUrl } from './common';
import { GoDirectDatasource } from './releases-direct';
import type { GoproxyItem, VersionInfo } from './types';

Expand Down Expand Up @@ -84,9 +84,7 @@ export class GoProxyDatasource extends Datasource {
} catch (err) {
const statusCode = err?.response?.statusCode;
const canFallback =
fallback === GoproxyFallback.Always
? true
: statusCode === 404 || statusCode === 410;
fallback === '|' ? true : statusCode === 404 || statusCode === 410;
const msg = canFallback
? 'Goproxy error: trying next URL provided with GOPROXY'
: 'Goproxy error: skipping other URLs provided with GOPROXY';
Expand Down Expand Up @@ -128,10 +126,7 @@ export class GoProxyDatasource extends Datasource {
.map((s) => s.split(/(?=,|\|)/)) // TODO: #12872 lookahead
.map(([url, separator]) => ({
url,
fallback:
separator === ','
? GoproxyFallback.WhenNotFoundOrGone
: GoproxyFallback.Always,
fallback: separator === ',' ? ',' : '|',
}));

parsedGoproxy[input] = result;
Expand Down
Loading

0 comments on commit 79365b8

Please sign in to comment.