renovate 44.83.3 → 44.85.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/config/presets/forgejo/index.js +3 -2
- package/dist/config/presets/forgejo/index.js.map +1 -1
- package/dist/config/presets/gitea/index.js +10 -3
- package/dist/config/presets/gitea/index.js.map +1 -1
- package/dist/modules/manager/fingerprint.generated.js +1 -1
- package/dist/modules/manager/fingerprint.generated.js.map +1 -1
- package/dist/modules/manager/github-actions/extract.js +1 -33
- package/dist/modules/manager/github-actions/extract.js.map +1 -1
- package/dist/modules/manager/github-actions/{community.js → known-actions.js} +62 -5
- package/dist/modules/manager/github-actions/known-actions.js.map +1 -0
- package/dist/modules/manager/github-actions/schema.js +2 -2
- package/dist/modules/manager/github-actions/schema.js.map +1 -1
- package/dist/modules/platform/api.js +6 -6
- package/dist/modules/platform/forgejo/index.js +21 -587
- package/dist/modules/platform/forgejo/index.js.map +1 -1
- package/dist/modules/platform/gitea/gitea-helper.js +90 -74
- package/dist/modules/platform/gitea/gitea-helper.js.map +1 -1
- package/dist/modules/platform/gitea/index.js +561 -529
- package/dist/modules/platform/gitea/index.js.map +1 -1
- package/dist/modules/platform/gitea/labels.js +42 -0
- package/dist/modules/platform/gitea/labels.js.map +1 -0
- package/dist/modules/platform/gitea/pr-cache.js +66 -28
- package/dist/modules/platform/gitea/pr-cache.js.map +1 -1
- package/dist/modules/platform/gitea/schema.js +141 -5
- package/dist/modules/platform/gitea/schema.js.map +1 -1
- package/dist/modules/platform/gitea/utils.js +10 -8
- package/dist/modules/platform/gitea/utils.js.map +1 -1
- package/dist/util/cache/repository/types.d.ts +13 -8
- package/dist/util/http/forgejo.js +6 -35
- package/dist/util/http/forgejo.js.map +1 -1
- package/dist/workers/repository/update/pr/changelog/forgejo/index.js +1 -1
- package/dist/workers/repository/update/pr/changelog/forgejo/index.js.map +1 -1
- package/dist/workers/repository/update/pr/changelog/gitea/index.js +3 -3
- package/dist/workers/repository/update/pr/changelog/gitea/index.js.map +1 -1
- package/package.json +1 -1
- package/renovate-schema.json +2 -2
- package/dist/modules/manager/github-actions/community.js.map +0 -1
- package/dist/modules/platform/forgejo/forgejo-helper.js +0 -235
- package/dist/modules/platform/forgejo/forgejo-helper.js.map +0 -1
- package/dist/modules/platform/forgejo/pr-cache.js +0 -114
- package/dist/modules/platform/forgejo/pr-cache.js.map +0 -1
- package/dist/modules/platform/forgejo/schema.js +0 -149
- package/dist/modules/platform/forgejo/schema.js.map +0 -1
- package/dist/modules/platform/forgejo/utils.js +0 -115
- package/dist/modules/platform/forgejo/utils.js.map +0 -1
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
import { logger } from "../../../logger/index.js";
|
|
2
2
|
import { ExternalHostError } from "../../../types/errors/external-host-error.js";
|
|
3
3
|
import { PRESET_DEP_NOT_FOUND, PRESET_INVALID, fetchPreset, parsePreset } from "../util.js";
|
|
4
|
-
import { getRepoContents } from "../../../modules/platform/
|
|
4
|
+
import { getRepoContents } from "../../../modules/platform/gitea/gitea-helper.js";
|
|
5
|
+
import { forgejoHttp } from "../../../modules/platform/forgejo/index.js";
|
|
5
6
|
//#region lib/config/presets/forgejo/index.ts
|
|
6
7
|
const Endpoint = "https://code.forgejo.org/";
|
|
7
8
|
async function fetchJSONFile(repo, fileName, endpoint, tag) {
|
|
8
9
|
let res;
|
|
9
10
|
try {
|
|
10
|
-
res = await getRepoContents(repo, fileName, tag, { baseUrl: endpoint });
|
|
11
|
+
res = await getRepoContents(forgejoHttp, repo, fileName, tag, { baseUrl: endpoint });
|
|
11
12
|
} catch (err) {
|
|
12
13
|
if (err instanceof ExternalHostError) throw err;
|
|
13
14
|
logger.debug(`Preset file ${fileName} not found in ${repo}: ${err.message}`);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../../../lib/config/presets/forgejo/index.ts"],"sourcesContent":["import { logger } from '../../../logger/index.ts';\nimport {
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../../../../lib/config/presets/forgejo/index.ts"],"sourcesContent":["import { logger } from '../../../logger/index.ts';\nimport { forgejoHttp } from '../../../modules/platform/forgejo/index.ts';\nimport { getRepoContents } from '../../../modules/platform/gitea/gitea-helper.ts';\nimport type { RepoContents } from '../../../modules/platform/gitea/schema.ts';\nimport { ExternalHostError } from '../../../types/errors/external-host-error.ts';\nimport type { Nullish } from '../../../types/index.ts';\nimport type { Preset, PresetConfig } from '../types.ts';\nimport {\n PRESET_DEP_NOT_FOUND,\n PRESET_INVALID,\n fetchPreset,\n parsePreset,\n} from '../util.ts';\n\nexport const Endpoint = 'https://code.forgejo.org/';\n\nexport async function fetchJSONFile(\n repo: string,\n fileName: string,\n endpoint: string,\n tag?: string | null,\n): Promise<Nullish<Preset>> {\n let res: RepoContents;\n try {\n res = await getRepoContents(forgejoHttp, repo, fileName, tag, {\n baseUrl: endpoint,\n });\n } catch (err) {\n if (err instanceof ExternalHostError) {\n throw err;\n }\n logger.debug(\n `Preset file ${fileName} not found in ${repo}: ${err.message}`,\n );\n throw new Error(PRESET_DEP_NOT_FOUND);\n }\n\n let contentString: string;\n if (res.type === 'file') {\n contentString = res.contentString;\n } else {\n logger.debug(\n `Preset ${fileName} has unexpected type '${res.type}'. Only \\`file\\` is supported`,\n );\n throw new Error(PRESET_INVALID);\n }\n return parsePreset(contentString, fileName);\n}\n\nexport function getPresetFromEndpoint(\n repo: string,\n filePreset: string,\n presetPath?: string,\n endpoint = Endpoint,\n tag?: string,\n): Promise<Nullish<Preset>> {\n return fetchPreset({\n repo,\n filePreset,\n presetPath,\n endpoint,\n tag,\n fetch: fetchJSONFile,\n });\n}\n\nexport function getPreset({\n repo,\n presetName = 'default',\n presetPath,\n tag,\n}: PresetConfig): Promise<Nullish<Preset>> {\n return getPresetFromEndpoint(repo, presetName, presetPath, Endpoint, tag);\n}\n"],"mappings":";;;;;;AAcA,MAAa,WAAW;AAExB,eAAsB,cACpB,MACA,UACA,UACA,KAC0B;CAC1B,IAAI;CACJ,IAAI;EACF,MAAM,MAAM,gBAAgB,aAAa,MAAM,UAAU,KAAK,EAC5D,SAAS,SACX,CAAC;CACH,SAAS,KAAK;EACZ,IAAI,eAAe,mBACjB,MAAM;EAER,OAAO,MACL,eAAe,SAAS,gBAAgB,KAAK,IAAI,IAAI,SACvD;EACA,MAAM,IAAI,MAAM,oBAAoB;CACtC;CAEA,IAAI;CACJ,IAAI,IAAI,SAAS,QACf,gBAAgB,IAAI;MACf;EACL,OAAO,MACL,UAAU,SAAS,wBAAwB,IAAI,KAAK,8BACtD;EACA,MAAM,IAAI,MAAM,cAAc;CAChC;CACA,OAAO,YAAY,eAAe,QAAQ;AAC5C;AAEA,SAAgB,sBACd,MACA,YACA,YACA,WAAW,UACX,KAC0B;CAC1B,OAAO,YAAY;EACjB;EACA;EACA;EACA;EACA;EACA,OAAO;CACT,CAAC;AACH;AAEA,SAAgB,UAAU,EACxB,MACA,aAAa,WACb,YACA,OACyC;CACzC,OAAO,sBAAsB,MAAM,YAAY,YAAY,UAAU,GAAG;AAC1E"}
|
|
@@ -1,19 +1,26 @@
|
|
|
1
1
|
import { logger } from "../../../logger/index.js";
|
|
2
2
|
import { ExternalHostError } from "../../../types/errors/external-host-error.js";
|
|
3
|
-
import { PRESET_DEP_NOT_FOUND, fetchPreset, parsePreset } from "../util.js";
|
|
3
|
+
import { PRESET_DEP_NOT_FOUND, PRESET_INVALID, fetchPreset, parsePreset } from "../util.js";
|
|
4
4
|
import { getRepoContents } from "../../../modules/platform/gitea/gitea-helper.js";
|
|
5
|
+
import { giteaHttp } from "../../../modules/platform/gitea/index.js";
|
|
5
6
|
//#region lib/config/presets/gitea/index.ts
|
|
6
7
|
const Endpoint = "https://gitea.com/";
|
|
7
8
|
async function fetchJSONFile(repo, fileName, endpoint, tag) {
|
|
8
9
|
let res;
|
|
9
10
|
try {
|
|
10
|
-
res = await getRepoContents(repo, fileName, tag, { baseUrl: endpoint });
|
|
11
|
+
res = await getRepoContents(giteaHttp, repo, fileName, tag, { baseUrl: endpoint });
|
|
11
12
|
} catch (err) {
|
|
12
13
|
if (err instanceof ExternalHostError) throw err;
|
|
13
14
|
logger.debug(`Preset file ${fileName} not found in ${repo}: ${err.message}`);
|
|
14
15
|
throw new Error(PRESET_DEP_NOT_FOUND);
|
|
15
16
|
}
|
|
16
|
-
|
|
17
|
+
let contentString;
|
|
18
|
+
if (res.type === "file") contentString = res.contentString;
|
|
19
|
+
else {
|
|
20
|
+
logger.debug(`Preset ${fileName} has unexpected type '${res.type}'. Only \`file\` is supported`);
|
|
21
|
+
throw new Error(PRESET_INVALID);
|
|
22
|
+
}
|
|
23
|
+
return parsePreset(contentString, fileName);
|
|
17
24
|
}
|
|
18
25
|
function getPresetFromEndpoint(repo, filePreset, presetPath, endpoint = Endpoint, tag) {
|
|
19
26
|
return fetchPreset({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../../../lib/config/presets/gitea/index.ts"],"sourcesContent":["import { logger } from '../../../logger/index.ts';\nimport { getRepoContents } from '../../../modules/platform/gitea/gitea-helper.ts';\nimport type { RepoContents } from '../../../modules/platform/gitea/
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../../../../lib/config/presets/gitea/index.ts"],"sourcesContent":["import { logger } from '../../../logger/index.ts';\nimport { getRepoContents } from '../../../modules/platform/gitea/gitea-helper.ts';\nimport { giteaHttp } from '../../../modules/platform/gitea/index.ts';\nimport type { RepoContents } from '../../../modules/platform/gitea/schema.ts';\nimport { ExternalHostError } from '../../../types/errors/external-host-error.ts';\nimport type { Nullish } from '../../../types/index.ts';\nimport type { Preset, PresetConfig } from '../types.ts';\nimport {\n PRESET_DEP_NOT_FOUND,\n PRESET_INVALID,\n fetchPreset,\n parsePreset,\n} from '../util.ts';\n\nexport const Endpoint = 'https://gitea.com/';\n\nexport async function fetchJSONFile(\n repo: string,\n fileName: string,\n endpoint: string,\n tag?: string | null,\n): Promise<Nullish<Preset>> {\n let res: RepoContents;\n try {\n res = await getRepoContents(giteaHttp, repo, fileName, tag, {\n baseUrl: endpoint,\n });\n } catch (err) {\n if (err instanceof ExternalHostError) {\n throw err;\n }\n logger.debug(\n `Preset file ${fileName} not found in ${repo}: ${err.message}`,\n );\n throw new Error(PRESET_DEP_NOT_FOUND);\n }\n\n let contentString: string;\n if (res.type === 'file') {\n contentString = res.contentString;\n } else {\n logger.debug(\n `Preset ${fileName} has unexpected type '${res.type}'. Only \\`file\\` is supported`,\n );\n throw new Error(PRESET_INVALID);\n }\n return parsePreset(contentString, fileName);\n}\n\nexport function getPresetFromEndpoint(\n repo: string,\n filePreset: string,\n presetPath?: string,\n endpoint = Endpoint,\n tag?: string,\n): Promise<Nullish<Preset>> {\n return fetchPreset({\n repo,\n filePreset,\n presetPath,\n endpoint,\n tag,\n fetch: fetchJSONFile,\n });\n}\n\nexport function getPreset({\n repo,\n presetName = 'default',\n presetPath,\n tag,\n}: PresetConfig): Promise<Nullish<Preset>> {\n return getPresetFromEndpoint(repo, presetName, presetPath, Endpoint, tag);\n}\n"],"mappings":";;;;;;AAcA,MAAa,WAAW;AAExB,eAAsB,cACpB,MACA,UACA,UACA,KAC0B;CAC1B,IAAI;CACJ,IAAI;EACF,MAAM,MAAM,gBAAgB,WAAW,MAAM,UAAU,KAAK,EAC1D,SAAS,SACX,CAAC;CACH,SAAS,KAAK;EACZ,IAAI,eAAe,mBACjB,MAAM;EAER,OAAO,MACL,eAAe,SAAS,gBAAgB,KAAK,IAAI,IAAI,SACvD;EACA,MAAM,IAAI,MAAM,oBAAoB;CACtC;CAEA,IAAI;CACJ,IAAI,IAAI,SAAS,QACf,gBAAgB,IAAI;MACf;EACL,OAAO,MACL,UAAU,SAAS,wBAAwB,IAAI,KAAK,8BACtD;EACA,MAAM,IAAI,MAAM,cAAc;CAChC;CACA,OAAO,YAAY,eAAe,QAAQ;AAC5C;AAEA,SAAgB,sBACd,MACA,YACA,YACA,WAAW,UACX,KAC0B;CAC1B,OAAO,YAAY;EACjB;EACA;EACA;EACA;EACA;EACA,OAAO;CACT,CAAC;AACH;AAEA,SAAgB,UAAU,EACxB,MACA,aAAa,WACb,YACA,OACyC;CACzC,OAAO,sBAAsB,MAAM,YAAY,YAAY,UAAU,GAAG;AAC1E"}
|
|
@@ -43,7 +43,7 @@ hashMap.set("fleet", "4942d52e82f35c41e2d46cf76f426e2d91b350338cfc0bbcb97e8aaae2
|
|
|
43
43
|
hashMap.set("flux", "c67562b40cc7cd5e22b4c1ac642fc92ef46db79da9cea174e8aefcc20dde9811");
|
|
44
44
|
hashMap.set("fvm", "9b161df0f14bc6e536368952adf373e343630097121a913cea60ee284027fb90");
|
|
45
45
|
hashMap.set("git-submodules", "df8bb92b2906d8cddda2d4b302ee503f8002e3554d32d74cef2f584fe891f38f");
|
|
46
|
-
hashMap.set("github-actions", "
|
|
46
|
+
hashMap.set("github-actions", "7cd8723b0f55660f50698ad7eec1a6e9fb8262ce24124a19ddad05a3baedbb53");
|
|
47
47
|
hashMap.set("gitlabci", "a5e1e66ef461e1c1e71062f85f35a212417e23627f4b002810f9a98295d6e672");
|
|
48
48
|
hashMap.set("gitlabci-include", "8860a15ab516fde00694f9bd9bf56fce4addafe5a55b5ddb9a4ec477d301d351");
|
|
49
49
|
hashMap.set("glasskube", "93e7b9000a17efa15a1abaaf320b5af9169b1ecd828fc0c881d98570ef9d9e30");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fingerprint.generated.js","names":[],"sources":["../../../lib/modules/manager/fingerprint.generated.ts"],"sourcesContent":["export const hashMap = new Map<string, string>();\n\nhashMap.set('ansible','a52394a36ac5517f7330473c31d93aa05b2ce607c5e951b48f25a4693cd20a81');\nhashMap.set('ansible-galaxy','0a264d6be73953d801510fdeff271e4071c274339569c6dab4e2a128eaf4869f');\nhashMap.set('ant','2df5943cf0ed19a21b94df13729dbb925655548130caf37e3e22bebaed518e17');\nhashMap.set('apm','146e023bced69a0625adfac29148a5254d9457ad5a48931c7047299f6452cb43');\nhashMap.set('argocd','cff9cd22257bc460ae4b9936570bf0ed5585f280a55d26629deaeeb0bfee8eb5');\nhashMap.set('asdf','430eb99b58171700c8a59c78b9e648575e9b176b781d90dd10a710f7b69015bb');\nhashMap.set('azure-pipelines','6bf7782e8a02fc87dc5d84aab59e517c09df51fd23cf57805e62207dbd5efdb5');\nhashMap.set('batect','375d39b432013bedb1330cf40a2199dd822751b28578214f219e7bab98594b8d');\nhashMap.set('batect-wrapper','d999355511ea7f4053325a18b8cfc8d2b586c61e6760c35e557d383a673e3939');\nhashMap.set('bazel','ef00591c6f09069550ef97ff7ff5e387b9dd3df51cdecc9ef941169b19315396');\nhashMap.set('bazel-module','65e6cb3d6c0d9b3b1fda22388b6c72148c518cd06e8c434b46e4645384381bad');\nhashMap.set('bazelisk','a83328e3c5b4c3f5af2e425f680b4852c08ef5c6d035a248e09577136cf3b14d');\nhashMap.set('bicep','7246e0bfc06e0e28cbb03ac088c5591f648956b086e106aeb251fe5d628329db');\nhashMap.set('bitbucket-pipelines','59c0503494ab1442b127914503c01b97ac17b6742b19c632292d5aa24de115cd');\nhashMap.set('bitrise','478dfd316221fad7c29e177c70d1018d832fb2626b53308a5d0f1f0380e69f42');\nhashMap.set('buildkite','b8b404f53cd5d61c39153fddf93945e621471c4ac6aa9960c881cd868922bb4c');\nhashMap.set('buildpacks','6bef3cb04d66b5cfbb195adb4829bcbccae6408518706744d291bacf0610421f');\nhashMap.set('bun','3d40239b69d462ab843562ff8ee5bfacbc46d4976d38d0af17d037973f174e3e');\nhashMap.set('bun-version','df3ae8e4a5de1fa1b4544f3d7fc8117e80adb1e151c46d1ede54a4dbea6521e4');\nhashMap.set('bundler','9c5b8a2e7b84a545bbd6cc74c1fd9422f167da67c41bcc9bfb4cc2098b41de0c');\nhashMap.set('cake','9ebd8b481220b30a8860121d26184540a1a2fcc05ef780df9295dea39b386fad');\nhashMap.set('cargo','e8f43c68e874a9f3e684c2f3323b77a2799c49a1a538495ae75fb3a3bdd1f786');\nhashMap.set('cdnurl','9a81c8e3c6ad6c788498c99fc1067ffdfcd92a427c3afaf8c0130975d83131f2');\nhashMap.set('circleci','91cbeb33ea20f9838e2c81a1195eb806f0b38fa282bc3679f62552f20575ca85');\nhashMap.set('cloudbuild','f4e40388944652c8a19f8518771ac8d3f3c4ccf81ddef0e68b463aca833cb73c');\nhashMap.set('cocoapods','f832e2beef885bb3fd697ed9bb3e8cd742926bfec37ff41212edd2dbb4edb3ba');\nhashMap.set('composer','3906e56e8decf5d5e51cccdb46d2ce4eb4ff8efc8b0596b859f0f7210e13ed45');\nhashMap.set('conan','1cfe3887dba15d974fbbad3c0f49b7b745a6bad194ff95f067976ce3ae47d2bf');\nhashMap.set('copier','d70688a4a74d7239229a69eb1e3c5af19da0a38d12b9324c92ff86776fa0dec7');\nhashMap.set('cpanfile','07813fec3f3c2197056500e9266a0553b9774c02f2c74d5ca2e213188c7c12d3');\nhashMap.set('crossplane','5c26b1201a1a51454ffb94d829e223a76a781569bf79cdb1e47087c30233ec40');\nhashMap.set('crow','eb9a5f9f95041855dded67bcce3dd54724f690995ed6268d272e8a666ff28fd0');\nhashMap.set('deno','bdb28fcfdc032e3ea75d2569213fef207fd18bcaa46a6e4ea933150e49df24bf');\nhashMap.set('deps-edn','7b6ac92be04b44fdf1da8755550a6417bb294908158119c8fff10adeb05048d2');\nhashMap.set('devbox','abca7468e2363c04b7e4b85bfdbc75e11ed38e9d3b84b9ccc6d1a4c34a8fc1fb');\nhashMap.set('devcontainer','24320ed1cb6191d04cb8b2707214d82c08c682597aed1d84f250aa00ad1632ec');\nhashMap.set('docker-compose','a9c27711356fbda8dd14f21e046936e1e43f18c5528325b468d89937f76fe1e7');\nhashMap.set('dockerfile','a83e9e93f31576697d45fd60a0b44f7d14a610752e695a62507624ab2dbb2162');\nhashMap.set('droneci','e2039bb37c2d63c53027b188d1f0faa7c8923dcbfe6cf3851fba8d4e9f43a358');\nhashMap.set('fleet','4942d52e82f35c41e2d46cf76f426e2d91b350338cfc0bbcb97e8aaae2a1ac0b');\nhashMap.set('flux','c67562b40cc7cd5e22b4c1ac642fc92ef46db79da9cea174e8aefcc20dde9811');\nhashMap.set('fvm','9b161df0f14bc6e536368952adf373e343630097121a913cea60ee284027fb90');\nhashMap.set('git-submodules','df8bb92b2906d8cddda2d4b302ee503f8002e3554d32d74cef2f584fe891f38f');\nhashMap.set('github-actions','fcd3a1e7a07c1fd4cdc07f2fd818fdbb0012af97d35b1b9d448970067564084b');\nhashMap.set('gitlabci','a5e1e66ef461e1c1e71062f85f35a212417e23627f4b002810f9a98295d6e672');\nhashMap.set('gitlabci-include','8860a15ab516fde00694f9bd9bf56fce4addafe5a55b5ddb9a4ec477d301d351');\nhashMap.set('glasskube','93e7b9000a17efa15a1abaaf320b5af9169b1ecd828fc0c881d98570ef9d9e30');\nhashMap.set('gleam','a3bd05c4814eb57872d39979a40342a8ee23e61a85e2ab25e84346e8215dadc1');\nhashMap.set('gomod','1ed58f0af452a6776ae1899466851bab659f8287c90cff96619068d8184048d5');\nhashMap.set('gradle','ef9db616bf60e9a3623fff0e41df274a457333a37f37c24f3841a3ca3a531449');\nhashMap.set('gradle-wrapper','77f7e75be2597b847fc821ff8ff5bb4b3e37ab3cc4e780e22ce75e0342becac8');\nhashMap.set('haskell-cabal','f158b7725e3143dfd2950e3de0bbccc2a61cd7eba87f7a54c5057e01252348e2');\nhashMap.set('helm-requirements','7ee9dace4c036dfe113c0c0e46369d8b83a739caa831660142ca98d3236a180a');\nhashMap.set('helm-values','01069e887d4f3b55ca62a3c0dc66d8620264e1426207be9eb240a10c1ad5e412');\nhashMap.set('helmfile','0084e0b81794d57ee7937a76f652a7f06be49fe045a22715773153486e1b4849');\nhashMap.set('helmsman','951deeb3355da751ef39c9e932b26ea749450e32e75759e4b5fc29359e100b37');\nhashMap.set('helmv3','b9be11ed173f52808328e1d180289aa0a005ad64bb6261ad3e2e0269a18ec18f');\nhashMap.set('hermit','0fb25b7766c3a264fbb765ff75b1542b24136c4c9f933696d4a5aecfed637071');\nhashMap.set('homeassistant-manifest','05043c6db870cffbb6f8f3e351c025e3de227eaae0b24134b796aec46f84b65f');\nhashMap.set('homebrew','9c64a4f1475b1c2052372e566c9190f32ae8acd1c54313031d55ae8772388367');\nhashMap.set('html','81fa6c2bf2b868596584a48b949645207a2aa3081951ed99183ee50b70b77d5f');\nhashMap.set('jenkins','7bfb09418a132e052579196633bac78ac947cf93f1e70748ea1b3da929874b87');\nhashMap.set('jsonnet-bundler','06d163b939b258e1e2847a12a1249cb7d68d77c7bcf13c6d1a0a916744eba5cc');\nhashMap.set('kotlin-script','95ebc844c040ca047321b207d525220e29774a2a1fe06f9639e8353c66908564');\nhashMap.set('kubernetes','321e7d77fb3600dd4c00a86eaa1294927e7f92300b74fa2977d813dcaa3bb4de');\nhashMap.set('kustomize','558fcfe5b20f1eb4aba0d3c755a060bb4561611e99db7000786ce4edcd3f7894');\nhashMap.set('leiningen','a7295160ce901e08e12be75cb3aaf6b9a199de811eb60b618feb773f7c552bba');\nhashMap.set('maven','c110b99291c2a5bc82cf7a69330275e9bbd7dc8ba3e9e987611dfcffbe002d8d');\nhashMap.set('maven-wrapper','db967206d960b12d7c58d78132808d3c412087ababf5c59444262782e4434c6a');\nhashMap.set('meteor','4636a47ba4dcfff19fe662572ef7a40d17146be3c966e00ef437e1fc8de92776');\nhashMap.set('mint','248fe4f1ea5c985921c286785792c97e06fc41f402b2d45df82f6aecd17f710e');\nhashMap.set('mise','8a27fa2867ae2b0635c1bf06506b32f740f691f36cbab92ff0decf3dd0484345');\nhashMap.set('mix','473bb870c00b270faae93c4614873f644ad516f762acf07f773b12a7b8e01d19');\nhashMap.set('nix','a9d4ae3f9f01abb71dc9ebc12a9cd8bec237ad9d2dabfbf4f5ffd59e56c9a612');\nhashMap.set('nodenv','ac652c28481b001f7471f4183eac07b45d98ecbe83efc275830b0a1b2e0459b8');\nhashMap.set('npm','c73858631143d9627d5cc615a874c3d74edd643161e33380b615dda7c8f1bbed');\nhashMap.set('nuget','136bc3226e77b8fe65940454dc2c858fde86c2e0da6dbbdf71a5269ab137caee');\nhashMap.set('nvm','3eb77c7b0acf6d64753de78fad2499b352719853aa6872878c40675d14152322');\nhashMap.set('ocb','032b216684c14b0954e0bb019513a2aca3faaee5748587acb668d377d7c891ca');\nhashMap.set('osgi','d6567a733ef3983112b46fdccd7ceebfcd48411104e0c6b6e714d4310db48024');\nhashMap.set('pep621','36591cbca53de57a1160d8794af950c87e048f3dda2b1b155354c409a0217acc');\nhashMap.set('pep723','b96683163de63ed93207ec0538066705b1e58a1cd5b8bd11c63fc28b26bddba1');\nhashMap.set('pip-compile','ad43905a365c677315d2dcba725aef9b82c677d6ff30ee358f890f10faeb035f');\nhashMap.set('pip_requirements','953af0f3b41c2c1027327a8b1f37675c72892a8b03fdfbc3862ab63a1c3c72bf');\nhashMap.set('pip_setup','df18fba2bdcf48f3ca12a8f7e5cd28df31e2368d5528127277038ef4206eca79');\nhashMap.set('pipenv','fc2fd2e06753fada34958eb190c6d9236271b81a8a4cf1a354937a209cef06a9');\nhashMap.set('pixi','eb3a49c742d7de368b631c0b4fc5ae1a011b5ce85752e6bdf870f24c3e548bc5');\nhashMap.set('poetry','33dfbd8bddcf2aca101be8c869cca7ba8d33a7224c7b86296718814fde8241cb');\nhashMap.set('pre-commit','a8fa968d6308947c8a6eedd799ea449e548e918971acdc250b627e86a446dc23');\nhashMap.set('proto','412053d4550026b4ace490b46e970915b87ec1abf0b0a0c6c8c58ccf1fc16843');\nhashMap.set('pub','d0c11bb1076c7b84a3f30458d8747d5cdfd0126cc52a8d8218ab77c46287219b');\nhashMap.set('puppet','ba58ab689e44acc8f61c3569ab8b40fde01b8a9d3aad712708e2a419e57d8b45');\nhashMap.set('pyenv','9ede8becc97774f9040b40f4472d3e933534b596e04c360bfe0f3c6f95f25182');\nhashMap.set('quadlet','e1fc88a4e14cd595e89bb3d79b4adf2add3ce5eb80f75276e712c32598cca53d');\nhashMap.set('renovate-config','ca60beee2e3b871ea1216fa9df9a501f7ed355fe7da29e12509e56a124a78e69');\nhashMap.set('ruby-version','2db2140d9eee8c555e729a4de0396fa2d78846d3149890ee12fa515bd654be97');\nhashMap.set('runtime-version','b582b168c0cc595e39010feb10f4b97a82683eb269e9598216fbb11cc186e160');\nhashMap.set('rust-toolchain','6ace53db02874d73620d2d872291839820a512a9529c42d174358c692e5db720');\nhashMap.set('sbt','2bb0c98d231bbd6c9043127bfc566a954e7e04fc8654b119c14438a63371e4a7');\nhashMap.set('scalafmt','9d36159b56835e96498af026a1fb0543200db0581681ef95ec54988f411e180f');\nhashMap.set('setup-cfg','4a3a7c812d34739c07685691e7e64c7d3127f9d7d4aff99dc45a25df97ed9745');\nhashMap.set('smithy','9641b91d065ffb63be0dd888139a0402dba41e550f8b44c592db9daf52109100');\nhashMap.set('sveltos','60dd75bb53ace31217211100d622fdb65068c6162758b6ae7103a6ce8bdc9f90');\nhashMap.set('swift','5ebd875ee7a541b4725f6263789ea9a7c77a4b7c40b2119f894e67b588cfa672');\nhashMap.set('tekton','33948f5bdf7553909fa63744adb26da97ddf366e9499bccab1250879570267c9');\nhashMap.set('terraform','d1d5e54517e6075035b4c03de3419f09008c661587ad16a7d8bada4150a92f6f');\nhashMap.set('terraform-version','ec8f786b9731d47f2c2fe0307caf64d7ddd83046fe7ff1f7d8423239f8b0f2aa');\nhashMap.set('terragrunt','ffcbaa67dd65f064d43f8c121c1006115eab1879c4bd38de263b9b90a009c118');\nhashMap.set('terragrunt-version','eea6087b33717d22ede2fc68c2f64df8390b75abe82110ed831a180648feb51d');\nhashMap.set('tflint-plugin','31247d37bc80aae17039bfa21bd989c5717730c5ef10cf2a6f09841576d012ec');\nhashMap.set('travis','04c94f72622003195c8ea8147c8fbd93003f444ec807ce33f2ada2384282db83');\nhashMap.set('typst','d080a79fbd961c6e21fcc505d544b7e0ff2126142acb1dcabdf6abbcd9339248');\nhashMap.set('unity3d','f13e25e115e3443f4e16cf31578acffa78fb1a5e23339680a92d8d6de6052920');\nhashMap.set('velaci','fda00ddb7cc23e9a37e0a8a253151df0a6930b4276d3e4f78cc54b9ac09af7de');\nhashMap.set('vendir','59e860a89a35f58760296ecc076310f672a0211740dcebca20e38b04dc0c5553');\nhashMap.set('woodpecker','6110d3bec33aaeb3511d4bbfa896cec3c8e02fb04a6cff50c9ba81061c851045');\nhashMap.set('xcodegen','dad511d88a9ce1dbdde8b9731f3da7f2bdaa4ca8a083294ee58d56da62ab1683');\nhashMap.set('jsonata','416bcf61144b276b3112814c6e6d261aa29608f46fbb0516c471d35c16f8f0d7');\nhashMap.set('regex','20be5247fdc164173871a051acb0527da017d0c155c653d7563601f55e7b3ff5');"],"mappings":";AAAA,MAAa,0BAAU,IAAI,IAAoB;AAE/C,QAAQ,IAAI,WAAU,kEAAkE;AACxF,QAAQ,IAAI,kBAAiB,kEAAkE;AAC/F,QAAQ,IAAI,OAAM,kEAAkE;AACpF,QAAQ,IAAI,OAAM,kEAAkE;AACpF,QAAQ,IAAI,UAAS,kEAAkE;AACvF,QAAQ,IAAI,QAAO,kEAAkE;AACrF,QAAQ,IAAI,mBAAkB,kEAAkE;AAChG,QAAQ,IAAI,UAAS,kEAAkE;AACvF,QAAQ,IAAI,kBAAiB,kEAAkE;AAC/F,QAAQ,IAAI,SAAQ,kEAAkE;AACtF,QAAQ,IAAI,gBAAe,kEAAkE;AAC7F,QAAQ,IAAI,YAAW,kEAAkE;AACzF,QAAQ,IAAI,SAAQ,kEAAkE;AACtF,QAAQ,IAAI,uBAAsB,kEAAkE;AACpG,QAAQ,IAAI,WAAU,kEAAkE;AACxF,QAAQ,IAAI,aAAY,kEAAkE;AAC1F,QAAQ,IAAI,cAAa,kEAAkE;AAC3F,QAAQ,IAAI,OAAM,kEAAkE;AACpF,QAAQ,IAAI,eAAc,kEAAkE;AAC5F,QAAQ,IAAI,WAAU,kEAAkE;AACxF,QAAQ,IAAI,QAAO,kEAAkE;AACrF,QAAQ,IAAI,SAAQ,kEAAkE;AACtF,Q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AI,WAAU,kEAAkE;AACxF,QAAQ,IAAI,mBAAkB,kEAAkE;AAChG,QAAQ,IAAI,gBAAe,kEAAkE;AAC7F,QAAQ,IAAI,mBAAkB,kEAAkE;AAChG,QAAQ,IAAI,kBAAiB,kEAAkE;AAC/F,QAAQ,IAAI,OAAM,kEAAkE;AACpF,QAAQ,IAAI,YAAW,kEAAkE;AACzF,QAAQ,IAAI,aAAY,kEAAkE;AAC1F,QAAQ,IAAI,UAAS,kEAAkE;AACvF,QAAQ,IAAI,WAAU,kEAAkE;AACxF,QAAQ,IAAI,SAAQ,kEAAkE;AACtF,QAAQ,IAAI,UAAS,kEAAkE;AACvF,QAAQ,IAAI,aAAY,kEAAkE;AAC1F,QAAQ,IAAI,qBAAoB,kEAAkE;AAClG,QAAQ,IAAI,cAAa,kEAAkE;AAC3F,QAAQ,IAAI,sBAAqB,kEAAkE;AACnG,QAAQ,IAAI,iBAAgB,kEAAkE;AAC9F,QAAQ,IAAI,UAAS,kEAAkE;AACvF,QAAQ,IAAI,SAAQ,kEAAkE;AACtF,QAAQ,IAAI,WAAU,kEAAkE;AACxF,QAAQ,IAAI,UAAS,kEAAkE;AACvF,QAAQ,IAAI,UAAS,kEAAkE;AACvF,QAAQ,IAAI,cAAa,kEAAkE;AAC3F,QAAQ,IAAI,YAAW,kEAAkE;AACzF,QAAQ,IAAI,WAAU,kEAAkE;AACxF,QAAQ,IAAI,SAAQ,kEAAkE"}
|
|
1
|
+
{"version":3,"file":"fingerprint.generated.js","names":[],"sources":["../../../lib/modules/manager/fingerprint.generated.ts"],"sourcesContent":["export const hashMap = new Map<string, string>();\n\nhashMap.set('ansible','a52394a36ac5517f7330473c31d93aa05b2ce607c5e951b48f25a4693cd20a81');\nhashMap.set('ansible-galaxy','0a264d6be73953d801510fdeff271e4071c274339569c6dab4e2a128eaf4869f');\nhashMap.set('ant','2df5943cf0ed19a21b94df13729dbb925655548130caf37e3e22bebaed518e17');\nhashMap.set('apm','146e023bced69a0625adfac29148a5254d9457ad5a48931c7047299f6452cb43');\nhashMap.set('argocd','cff9cd22257bc460ae4b9936570bf0ed5585f280a55d26629deaeeb0bfee8eb5');\nhashMap.set('asdf','430eb99b58171700c8a59c78b9e648575e9b176b781d90dd10a710f7b69015bb');\nhashMap.set('azure-pipelines','6bf7782e8a02fc87dc5d84aab59e517c09df51fd23cf57805e62207dbd5efdb5');\nhashMap.set('batect','375d39b432013bedb1330cf40a2199dd822751b28578214f219e7bab98594b8d');\nhashMap.set('batect-wrapper','d999355511ea7f4053325a18b8cfc8d2b586c61e6760c35e557d383a673e3939');\nhashMap.set('bazel','ef00591c6f09069550ef97ff7ff5e387b9dd3df51cdecc9ef941169b19315396');\nhashMap.set('bazel-module','65e6cb3d6c0d9b3b1fda22388b6c72148c518cd06e8c434b46e4645384381bad');\nhashMap.set('bazelisk','a83328e3c5b4c3f5af2e425f680b4852c08ef5c6d035a248e09577136cf3b14d');\nhashMap.set('bicep','7246e0bfc06e0e28cbb03ac088c5591f648956b086e106aeb251fe5d628329db');\nhashMap.set('bitbucket-pipelines','59c0503494ab1442b127914503c01b97ac17b6742b19c632292d5aa24de115cd');\nhashMap.set('bitrise','478dfd316221fad7c29e177c70d1018d832fb2626b53308a5d0f1f0380e69f42');\nhashMap.set('buildkite','b8b404f53cd5d61c39153fddf93945e621471c4ac6aa9960c881cd868922bb4c');\nhashMap.set('buildpacks','6bef3cb04d66b5cfbb195adb4829bcbccae6408518706744d291bacf0610421f');\nhashMap.set('bun','3d40239b69d462ab843562ff8ee5bfacbc46d4976d38d0af17d037973f174e3e');\nhashMap.set('bun-version','df3ae8e4a5de1fa1b4544f3d7fc8117e80adb1e151c46d1ede54a4dbea6521e4');\nhashMap.set('bundler','9c5b8a2e7b84a545bbd6cc74c1fd9422f167da67c41bcc9bfb4cc2098b41de0c');\nhashMap.set('cake','9ebd8b481220b30a8860121d26184540a1a2fcc05ef780df9295dea39b386fad');\nhashMap.set('cargo','e8f43c68e874a9f3e684c2f3323b77a2799c49a1a538495ae75fb3a3bdd1f786');\nhashMap.set('cdnurl','9a81c8e3c6ad6c788498c99fc1067ffdfcd92a427c3afaf8c0130975d83131f2');\nhashMap.set('circleci','91cbeb33ea20f9838e2c81a1195eb806f0b38fa282bc3679f62552f20575ca85');\nhashMap.set('cloudbuild','f4e40388944652c8a19f8518771ac8d3f3c4ccf81ddef0e68b463aca833cb73c');\nhashMap.set('cocoapods','f832e2beef885bb3fd697ed9bb3e8cd742926bfec37ff41212edd2dbb4edb3ba');\nhashMap.set('composer','3906e56e8decf5d5e51cccdb46d2ce4eb4ff8efc8b0596b859f0f7210e13ed45');\nhashMap.set('conan','1cfe3887dba15d974fbbad3c0f49b7b745a6bad194ff95f067976ce3ae47d2bf');\nhashMap.set('copier','d70688a4a74d7239229a69eb1e3c5af19da0a38d12b9324c92ff86776fa0dec7');\nhashMap.set('cpanfile','07813fec3f3c2197056500e9266a0553b9774c02f2c74d5ca2e213188c7c12d3');\nhashMap.set('crossplane','5c26b1201a1a51454ffb94d829e223a76a781569bf79cdb1e47087c30233ec40');\nhashMap.set('crow','eb9a5f9f95041855dded67bcce3dd54724f690995ed6268d272e8a666ff28fd0');\nhashMap.set('deno','bdb28fcfdc032e3ea75d2569213fef207fd18bcaa46a6e4ea933150e49df24bf');\nhashMap.set('deps-edn','7b6ac92be04b44fdf1da8755550a6417bb294908158119c8fff10adeb05048d2');\nhashMap.set('devbox','abca7468e2363c04b7e4b85bfdbc75e11ed38e9d3b84b9ccc6d1a4c34a8fc1fb');\nhashMap.set('devcontainer','24320ed1cb6191d04cb8b2707214d82c08c682597aed1d84f250aa00ad1632ec');\nhashMap.set('docker-compose','a9c27711356fbda8dd14f21e046936e1e43f18c5528325b468d89937f76fe1e7');\nhashMap.set('dockerfile','a83e9e93f31576697d45fd60a0b44f7d14a610752e695a62507624ab2dbb2162');\nhashMap.set('droneci','e2039bb37c2d63c53027b188d1f0faa7c8923dcbfe6cf3851fba8d4e9f43a358');\nhashMap.set('fleet','4942d52e82f35c41e2d46cf76f426e2d91b350338cfc0bbcb97e8aaae2a1ac0b');\nhashMap.set('flux','c67562b40cc7cd5e22b4c1ac642fc92ef46db79da9cea174e8aefcc20dde9811');\nhashMap.set('fvm','9b161df0f14bc6e536368952adf373e343630097121a913cea60ee284027fb90');\nhashMap.set('git-submodules','df8bb92b2906d8cddda2d4b302ee503f8002e3554d32d74cef2f584fe891f38f');\nhashMap.set('github-actions','7cd8723b0f55660f50698ad7eec1a6e9fb8262ce24124a19ddad05a3baedbb53');\nhashMap.set('gitlabci','a5e1e66ef461e1c1e71062f85f35a212417e23627f4b002810f9a98295d6e672');\nhashMap.set('gitlabci-include','8860a15ab516fde00694f9bd9bf56fce4addafe5a55b5ddb9a4ec477d301d351');\nhashMap.set('glasskube','93e7b9000a17efa15a1abaaf320b5af9169b1ecd828fc0c881d98570ef9d9e30');\nhashMap.set('gleam','a3bd05c4814eb57872d39979a40342a8ee23e61a85e2ab25e84346e8215dadc1');\nhashMap.set('gomod','1ed58f0af452a6776ae1899466851bab659f8287c90cff96619068d8184048d5');\nhashMap.set('gradle','ef9db616bf60e9a3623fff0e41df274a457333a37f37c24f3841a3ca3a531449');\nhashMap.set('gradle-wrapper','77f7e75be2597b847fc821ff8ff5bb4b3e37ab3cc4e780e22ce75e0342becac8');\nhashMap.set('haskell-cabal','f158b7725e3143dfd2950e3de0bbccc2a61cd7eba87f7a54c5057e01252348e2');\nhashMap.set('helm-requirements','7ee9dace4c036dfe113c0c0e46369d8b83a739caa831660142ca98d3236a180a');\nhashMap.set('helm-values','01069e887d4f3b55ca62a3c0dc66d8620264e1426207be9eb240a10c1ad5e412');\nhashMap.set('helmfile','0084e0b81794d57ee7937a76f652a7f06be49fe045a22715773153486e1b4849');\nhashMap.set('helmsman','951deeb3355da751ef39c9e932b26ea749450e32e75759e4b5fc29359e100b37');\nhashMap.set('helmv3','b9be11ed173f52808328e1d180289aa0a005ad64bb6261ad3e2e0269a18ec18f');\nhashMap.set('hermit','0fb25b7766c3a264fbb765ff75b1542b24136c4c9f933696d4a5aecfed637071');\nhashMap.set('homeassistant-manifest','05043c6db870cffbb6f8f3e351c025e3de227eaae0b24134b796aec46f84b65f');\nhashMap.set('homebrew','9c64a4f1475b1c2052372e566c9190f32ae8acd1c54313031d55ae8772388367');\nhashMap.set('html','81fa6c2bf2b868596584a48b949645207a2aa3081951ed99183ee50b70b77d5f');\nhashMap.set('jenkins','7bfb09418a132e052579196633bac78ac947cf93f1e70748ea1b3da929874b87');\nhashMap.set('jsonnet-bundler','06d163b939b258e1e2847a12a1249cb7d68d77c7bcf13c6d1a0a916744eba5cc');\nhashMap.set('kotlin-script','95ebc844c040ca047321b207d525220e29774a2a1fe06f9639e8353c66908564');\nhashMap.set('kubernetes','321e7d77fb3600dd4c00a86eaa1294927e7f92300b74fa2977d813dcaa3bb4de');\nhashMap.set('kustomize','558fcfe5b20f1eb4aba0d3c755a060bb4561611e99db7000786ce4edcd3f7894');\nhashMap.set('leiningen','a7295160ce901e08e12be75cb3aaf6b9a199de811eb60b618feb773f7c552bba');\nhashMap.set('maven','c110b99291c2a5bc82cf7a69330275e9bbd7dc8ba3e9e987611dfcffbe002d8d');\nhashMap.set('maven-wrapper','db967206d960b12d7c58d78132808d3c412087ababf5c59444262782e4434c6a');\nhashMap.set('meteor','4636a47ba4dcfff19fe662572ef7a40d17146be3c966e00ef437e1fc8de92776');\nhashMap.set('mint','248fe4f1ea5c985921c286785792c97e06fc41f402b2d45df82f6aecd17f710e');\nhashMap.set('mise','8a27fa2867ae2b0635c1bf06506b32f740f691f36cbab92ff0decf3dd0484345');\nhashMap.set('mix','473bb870c00b270faae93c4614873f644ad516f762acf07f773b12a7b8e01d19');\nhashMap.set('nix','a9d4ae3f9f01abb71dc9ebc12a9cd8bec237ad9d2dabfbf4f5ffd59e56c9a612');\nhashMap.set('nodenv','ac652c28481b001f7471f4183eac07b45d98ecbe83efc275830b0a1b2e0459b8');\nhashMap.set('npm','c73858631143d9627d5cc615a874c3d74edd643161e33380b615dda7c8f1bbed');\nhashMap.set('nuget','136bc3226e77b8fe65940454dc2c858fde86c2e0da6dbbdf71a5269ab137caee');\nhashMap.set('nvm','3eb77c7b0acf6d64753de78fad2499b352719853aa6872878c40675d14152322');\nhashMap.set('ocb','032b216684c14b0954e0bb019513a2aca3faaee5748587acb668d377d7c891ca');\nhashMap.set('osgi','d6567a733ef3983112b46fdccd7ceebfcd48411104e0c6b6e714d4310db48024');\nhashMap.set('pep621','36591cbca53de57a1160d8794af950c87e048f3dda2b1b155354c409a0217acc');\nhashMap.set('pep723','b96683163de63ed93207ec0538066705b1e58a1cd5b8bd11c63fc28b26bddba1');\nhashMap.set('pip-compile','ad43905a365c677315d2dcba725aef9b82c677d6ff30ee358f890f10faeb035f');\nhashMap.set('pip_requirements','953af0f3b41c2c1027327a8b1f37675c72892a8b03fdfbc3862ab63a1c3c72bf');\nhashMap.set('pip_setup','df18fba2bdcf48f3ca12a8f7e5cd28df31e2368d5528127277038ef4206eca79');\nhashMap.set('pipenv','fc2fd2e06753fada34958eb190c6d9236271b81a8a4cf1a354937a209cef06a9');\nhashMap.set('pixi','eb3a49c742d7de368b631c0b4fc5ae1a011b5ce85752e6bdf870f24c3e548bc5');\nhashMap.set('poetry','33dfbd8bddcf2aca101be8c869cca7ba8d33a7224c7b86296718814fde8241cb');\nhashMap.set('pre-commit','a8fa968d6308947c8a6eedd799ea449e548e918971acdc250b627e86a446dc23');\nhashMap.set('proto','412053d4550026b4ace490b46e970915b87ec1abf0b0a0c6c8c58ccf1fc16843');\nhashMap.set('pub','d0c11bb1076c7b84a3f30458d8747d5cdfd0126cc52a8d8218ab77c46287219b');\nhashMap.set('puppet','ba58ab689e44acc8f61c3569ab8b40fde01b8a9d3aad712708e2a419e57d8b45');\nhashMap.set('pyenv','9ede8becc97774f9040b40f4472d3e933534b596e04c360bfe0f3c6f95f25182');\nhashMap.set('quadlet','e1fc88a4e14cd595e89bb3d79b4adf2add3ce5eb80f75276e712c32598cca53d');\nhashMap.set('renovate-config','ca60beee2e3b871ea1216fa9df9a501f7ed355fe7da29e12509e56a124a78e69');\nhashMap.set('ruby-version','2db2140d9eee8c555e729a4de0396fa2d78846d3149890ee12fa515bd654be97');\nhashMap.set('runtime-version','b582b168c0cc595e39010feb10f4b97a82683eb269e9598216fbb11cc186e160');\nhashMap.set('rust-toolchain','6ace53db02874d73620d2d872291839820a512a9529c42d174358c692e5db720');\nhashMap.set('sbt','2bb0c98d231bbd6c9043127bfc566a954e7e04fc8654b119c14438a63371e4a7');\nhashMap.set('scalafmt','9d36159b56835e96498af026a1fb0543200db0581681ef95ec54988f411e180f');\nhashMap.set('setup-cfg','4a3a7c812d34739c07685691e7e64c7d3127f9d7d4aff99dc45a25df97ed9745');\nhashMap.set('smithy','9641b91d065ffb63be0dd888139a0402dba41e550f8b44c592db9daf52109100');\nhashMap.set('sveltos','60dd75bb53ace31217211100d622fdb65068c6162758b6ae7103a6ce8bdc9f90');\nhashMap.set('swift','5ebd875ee7a541b4725f6263789ea9a7c77a4b7c40b2119f894e67b588cfa672');\nhashMap.set('tekton','33948f5bdf7553909fa63744adb26da97ddf366e9499bccab1250879570267c9');\nhashMap.set('terraform','d1d5e54517e6075035b4c03de3419f09008c661587ad16a7d8bada4150a92f6f');\nhashMap.set('terraform-version','ec8f786b9731d47f2c2fe0307caf64d7ddd83046fe7ff1f7d8423239f8b0f2aa');\nhashMap.set('terragrunt','ffcbaa67dd65f064d43f8c121c1006115eab1879c4bd38de263b9b90a009c118');\nhashMap.set('terragrunt-version','eea6087b33717d22ede2fc68c2f64df8390b75abe82110ed831a180648feb51d');\nhashMap.set('tflint-plugin','31247d37bc80aae17039bfa21bd989c5717730c5ef10cf2a6f09841576d012ec');\nhashMap.set('travis','04c94f72622003195c8ea8147c8fbd93003f444ec807ce33f2ada2384282db83');\nhashMap.set('typst','d080a79fbd961c6e21fcc505d544b7e0ff2126142acb1dcabdf6abbcd9339248');\nhashMap.set('unity3d','f13e25e115e3443f4e16cf31578acffa78fb1a5e23339680a92d8d6de6052920');\nhashMap.set('velaci','fda00ddb7cc23e9a37e0a8a253151df0a6930b4276d3e4f78cc54b9ac09af7de');\nhashMap.set('vendir','59e860a89a35f58760296ecc076310f672a0211740dcebca20e38b04dc0c5553');\nhashMap.set('woodpecker','6110d3bec33aaeb3511d4bbfa896cec3c8e02fb04a6cff50c9ba81061c851045');\nhashMap.set('xcodegen','dad511d88a9ce1dbdde8b9731f3da7f2bdaa4ca8a083294ee58d56da62ab1683');\nhashMap.set('jsonata','416bcf61144b276b3112814c6e6d261aa29608f46fbb0516c471d35c16f8f0d7');\nhashMap.set('regex','20be5247fdc164173871a051acb0527da017d0c155c653d7563601f55e7b3ff5');"],"mappings":";AAAA,MAAa,0BAAU,IAAI,IAAoB;AAE/C,QAAQ,IAAI,WAAU,kEAAkE;AACxF,QAAQ,IAAI,kBAAiB,kEAAkE;AAC/F,QAAQ,IAAI,OAAM,kEAAkE;AACpF,QAAQ,IAAI,OAAM,kEAAkE;AACpF,QAAQ,IAAI,UAAS,kEAAkE;AACvF,QAAQ,IAAI,QAAO,kEAAkE;AACrF,QAAQ,IAAI,mBAAkB,kEAAkE;AAChG,QAAQ,IAAI,UAAS,kEAAkE;AACvF,QAAQ,IAAI,kBAAiB,kEAAkE;AAC/F,QAAQ,IAAI,SAAQ,kEAAkE;AACtF,QAAQ,IAAI,gBAAe,kEAAkE;AAC7F,QAAQ,IAAI,YAAW,kEAAkE;AACzF,QAAQ,IAAI,SAAQ,kEAAkE;AACtF,QAAQ,IAAI,uBAAsB,kEAAkE;AACpG,QAAQ,IAAI,WAAU,kEAAkE;AACxF,QAAQ,IAAI,aAAY,kEAAkE;AAC1F,QAAQ,IAAI,cAAa,kEAAkE;AAC3F,QAAQ,IAAI,OAAM,kEAAkE;AACpF,QAAQ,IAAI,eAAc,kEAAkE;AAC5F,QAAQ,IAAI,WAAU,kEAAkE;AACxF,QAAQ,IAAI,QAAO,kEAAkE;AACrF,QAAQ,IAAI,SAAQ,kEAAkE;AACt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,IAAI,WAAU,kEAAkE;AACxF,QAAQ,IAAI,mBAAkB,kEAAkE;AAChG,QAAQ,IAAI,gBAAe,kEAAkE;AAC7F,QAAQ,IAAI,mBAAkB,kEAAkE;AAChG,QAAQ,IAAI,kBAAiB,kEAAkE;AAC/F,QAAQ,IAAI,OAAM,kEAAkE;AACpF,QAAQ,IAAI,YAAW,kEAAkE;AACzF,QAAQ,IAAI,aAAY,kEAAkE;AAC1F,QAAQ,IAAI,UAAS,kEAAkE;AACvF,QAAQ,IAAI,WAAU,kEAAkE;AACxF,QAAQ,IAAI,SAAQ,kEAAkE;AACtF,QAAQ,IAAI,UAAS,kEAAkE;AACvF,QAAQ,IAAI,aAAY,kEAAkE;AAC1F,QAAQ,IAAI,qBAAoB,kEAAkE;AAClG,QAAQ,IAAI,cAAa,kEAAkE;AAC3F,QAAQ,IAAI,sBAAqB,kEAAkE;AACnG,QAAQ,IAAI,iBAAgB,kEAAkE;AAC9F,QAAQ,IAAI,UAAS,kEAAkE;AACvF,QAAQ,IAAI,SAAQ,kEAAkE;AACtF,QAAQ,IAAI,WAAU,kEAAkE;AACxF,QAAQ,IAAI,UAAS,kEAAkE;AACvF,QAAQ,IAAI,UAAS,kEAAkE;AACvF,QAAQ,IAAI,cAAa,kEAAkE;AAC3F,QAAQ,IAAI,YAAW,kEAAkE;AACzF,QAAQ,IAAI,WAAU,kEAAkE;AACxF,QAAQ,IAAI,SAAQ,kEAAkE"}
|
|
@@ -5,15 +5,12 @@ import { logger, withMeta } from "../../../logger/index.js";
|
|
|
5
5
|
import { parseUrl } from "../../../util/url.js";
|
|
6
6
|
import { detectPlatform } from "../../../util/common.js";
|
|
7
7
|
import { readLocalFile } from "../../../util/fs/index.js";
|
|
8
|
-
import "../../versioning/npm/index.js";
|
|
9
8
|
import { api } from "../../versioning/docker/index.js";
|
|
10
9
|
import { id } from "../../versioning/exact/index.js";
|
|
11
10
|
import { id as id$1 } from "../../versioning/github-actions/index.js";
|
|
12
|
-
import { id as id$2 } from "../../versioning/node/index.js";
|
|
13
11
|
import { ForgejoTagsDatasource } from "../../datasource/forgejo-tags/index.js";
|
|
14
12
|
import { GiteaTagsDatasource } from "../../datasource/gitea-tags/index.js";
|
|
15
13
|
import { GithubDigestDatasource } from "../../datasource/github-digest/index.js";
|
|
16
|
-
import { GithubReleasesDatasource } from "../../datasource/github-releases/index.js";
|
|
17
14
|
import { GithubRunnersDatasource } from "../../datasource/github-runners/index.js";
|
|
18
15
|
import { GithubTagsDatasource } from "../../datasource/github-tags/index.js";
|
|
19
16
|
import { getDep } from "../dockerfile/extract.js";
|
|
@@ -136,40 +133,11 @@ function extractRunner(runner) {
|
|
|
136
133
|
if (!api.isValid(currentValue)) dependency.skipReason = "invalid-version";
|
|
137
134
|
return dependency;
|
|
138
135
|
}
|
|
139
|
-
const versionedActions = {
|
|
140
|
-
go: "npm",
|
|
141
|
-
node: id$2,
|
|
142
|
-
python: "npm"
|
|
143
|
-
};
|
|
144
|
-
function extractVersionedAction(step) {
|
|
145
|
-
for (const [action, versioning] of Object.entries(versionedActions)) {
|
|
146
|
-
const actionName = `actions/setup-${action}`;
|
|
147
|
-
if (step.uses !== actionName && !step.uses?.startsWith(`${actionName}@`)) continue;
|
|
148
|
-
const fieldName = `${action}-version`;
|
|
149
|
-
const currentValue = step.with?.[fieldName];
|
|
150
|
-
if (!currentValue) return null;
|
|
151
|
-
return {
|
|
152
|
-
datasource: GithubReleasesDatasource.id,
|
|
153
|
-
depName: action,
|
|
154
|
-
packageName: `actions/${action}-versions`,
|
|
155
|
-
versioning,
|
|
156
|
-
extractVersion: "^(?<version>\\d+\\.\\d+\\.\\d+)(-\\d+)?$",
|
|
157
|
-
currentValue,
|
|
158
|
-
depType: "uses-with"
|
|
159
|
-
};
|
|
160
|
-
}
|
|
161
|
-
return null;
|
|
162
|
-
}
|
|
163
136
|
function extractSteps(steps) {
|
|
164
137
|
const deps = [];
|
|
165
138
|
for (const step of steps) {
|
|
166
139
|
const res = CommunityActions.safeParse(step);
|
|
167
|
-
if (res.success)
|
|
168
|
-
deps.push(...res.data);
|
|
169
|
-
continue;
|
|
170
|
-
}
|
|
171
|
-
const versionedDep = extractVersionedAction(step);
|
|
172
|
-
if (versionedDep) deps.push(versionedDep);
|
|
140
|
+
if (res.success) deps.push(...res.data);
|
|
173
141
|
}
|
|
174
142
|
return deps;
|
|
175
143
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"extract.js","names":["githubActionsVersioning.id","exactVersioning.id","nodeVersioning.id","memCache.get"],"sources":["../../../../lib/modules/manager/github-actions/extract.ts"],"sourcesContent":["import is from '@sindresorhus/is';\nimport { GlobalConfig } from '../../../config/global.ts';\nimport { logger, withMeta } from '../../../logger/index.ts';\nimport * as memCache from '../../../util/cache/memory/index.ts';\nimport { detectPlatform } from '../../../util/common.ts';\nimport { readLocalFile } from '../../../util/fs/index.ts';\nimport { newlineRegex, regEx } from '../../../util/regex.ts';\nimport { parseUrl } from '../../../util/url.ts';\nimport { ForgejoTagsDatasource } from '../../datasource/forgejo-tags/index.ts';\nimport { GiteaTagsDatasource } from '../../datasource/gitea-tags/index.ts';\nimport { GithubDigestDatasource } from '../../datasource/github-digest/index.ts';\nimport { GithubReleasesDatasource } from '../../datasource/github-releases/index.ts';\nimport { GithubRunnersDatasource } from '../../datasource/github-runners/index.ts';\nimport { GithubTagsDatasource } from '../../datasource/github-tags/index.ts';\nimport * as dockerVersioning from '../../versioning/docker/index.ts';\nimport * as exactVersioning from '../../versioning/exact/index.ts';\nimport * as githubActionsVersioning from '../../versioning/github-actions/index.ts';\nimport * as nodeVersioning from '../../versioning/node/index.ts';\nimport * as npmVersioning from '../../versioning/npm/index.ts';\nimport { getDep } from '../dockerfile/extract.ts';\nimport type {\n ExtractConfig,\n PackageDependency,\n PackageFileContent,\n} from '../types.ts';\nimport { actionsLockFile, isLockfileManaged } from './common.ts';\nimport { isSha, isShortSha, parseUsesLine, versionLikeRe } from './parse.ts';\nimport type { UsesStep } from './schema.ts';\nimport { ActionsLockfile, CommunityActions, Workflow } from './schema.ts';\nimport type {\n DockerReference,\n LockfileState,\n RepositoryReference,\n} from './types.ts';\n\n// detects if we run against a Github Enterprise Server and adds the URL to the beginning of the registryURLs for looking up Actions\n// This reflects the behavior of how GitHub looks up Actions\n// First on the Enterprise Server, then on GitHub.com\nfunction detectCustomGitHubRegistryUrlsForActions(): PackageDependency {\n const endpoint = GlobalConfig.get('endpoint');\n const registryUrls = ['https://github.com'];\n if (endpoint && GlobalConfig.get('platform') === 'github') {\n const parsedEndpoint = parseUrl(endpoint);\n if (!parsedEndpoint) {\n logger.warn({ endpoint }, 'Failed to parse endpoint url');\n return {};\n }\n\n if (\n parsedEndpoint.host !== 'github.com' &&\n parsedEndpoint.host !== 'api.github.com'\n ) {\n registryUrls.unshift(\n `${parsedEndpoint.protocol}//${parsedEndpoint.host}`,\n );\n return { registryUrls };\n }\n }\n return {};\n}\n\nfunction extractDockerAction(\n actionRef: DockerReference,\n config: ExtractConfig,\n): PackageDependency {\n const dep = getDep(actionRef.originalRef, true, config.registryAliases);\n dep.depType = 'docker';\n dep.replaceString = actionRef.originalRef;\n return dep;\n}\n\nconst reusableWorkflowPathRe = regEx(/^\\.github\\/workflows\\/[^/]+\\.ya?ml$/);\n\nfunction extractRepositoryAction(\n actionRef: RepositoryReference,\n parsed: ReturnType<typeof parseUsesLine> & object,\n customRegistryUrlsPackageDependency: PackageDependency,\n): PackageDependency {\n const {\n replaceString: valueString,\n quote,\n commentData,\n commentPrecedingWhitespace,\n } = parsed;\n const {\n owner,\n repo,\n path: subPath,\n ref,\n hostname,\n isExplicitHostname,\n } = actionRef;\n\n const registryUrl = isExplicitHostname ? `https://${hostname}/` : '';\n const packageName = `${owner}/${repo}`;\n const depName = `${registryUrl}${packageName}`;\n const pathSuffix = subPath ? `/${subPath}` : '';\n const commentWs = commentPrecedingWhitespace || ' ';\n const isReusableWorkflow = !!subPath && reusableWorkflowPathRe.test(subPath);\n\n const dep: PackageDependency = {\n depName,\n commitMessageTopic: '{{{depName}}} action',\n versioning: githubActionsVersioning.id,\n depType: isReusableWorkflow ? 'workflow' : 'action',\n replaceString: valueString,\n autoReplaceStringTemplate: `${quote}{{depName}}${pathSuffix}@{{#if newDigest}}{{newDigest}}${quote}{{#if newValue}}${commentWs}# {{newValue}}{{/if}}{{/if}}{{#unless newDigest}}{{newValue}}${quote}{{/unless}}`,\n ...(isExplicitHostname\n ? detectDatasource(registryUrl)\n : customRegistryUrlsPackageDependency),\n };\n\n if (packageName !== depName) {\n dep.packageName = packageName;\n }\n\n // Extend replaceString to include relevant comment portions:\n // - Pinned version or ref: include only up to the matched token (truncate trailing text)\n // - Ratchet exclude: include the full comment to preserve the marker\n const pinComment =\n commentData.pinnedVersion ??\n (isSha(ref) || isShortSha(ref) ? commentData.ref : undefined);\n if (\n pinComment &&\n !is.undefined(commentData.index) &&\n !is.undefined(commentData.matchedString)\n ) {\n const cleanComment = parsed.commentString.slice(1);\n const matchEndIndex = commentData.index + commentData.matchedString.length;\n const commentSuffix = cleanComment.slice(0, matchEndIndex);\n dep.replaceString = `${valueString}${commentPrecedingWhitespace}#${commentSuffix}`;\n } else if (commentData.ratchetExclude) {\n dep.replaceString =\n valueString + commentPrecedingWhitespace + parsed.commentString;\n }\n\n if (isSha(ref)) {\n dep.currentValue = commentData.pinnedVersion ?? commentData.ref;\n dep.currentDigest = ref;\n } else if (isShortSha(ref)) {\n dep.currentValue = commentData.pinnedVersion ?? commentData.ref;\n dep.currentDigestShort = ref;\n } else {\n dep.currentValue = ref;\n }\n\n if (!dep.currentValue) {\n dep.enabled = false;\n dep.skipReason = 'unversioned-reference';\n }\n\n const isVersionLike =\n dep.currentValue && versionLikeRe.test(dep.currentValue);\n if (!dep.datasource && dep.currentValue && !isVersionLike) {\n dep.datasource = GithubDigestDatasource.id;\n dep.versioning = exactVersioning.id;\n }\n\n dep.datasource ??= GithubTagsDatasource.id;\n\n return dep;\n}\n\nfunction extractWithRegex(\n content: string,\n config: ExtractConfig,\n): PackageDependency[] {\n const customRegistryUrlsPackageDependency =\n detectCustomGitHubRegistryUrlsForActions();\n logger.trace('github-actions.extractWithRegex()');\n const deps: PackageDependency[] = [];\n\n for (const line of content.split(newlineRegex)) {\n if (line.trim().startsWith('#')) {\n continue;\n }\n\n const parsed = parseUsesLine(line);\n if (!parsed?.actionRef) {\n continue;\n }\n\n const { actionRef } = parsed;\n\n if (actionRef.kind === 'docker') {\n deps.push(extractDockerAction(actionRef, config));\n continue;\n }\n\n if (actionRef.kind === 'repository') {\n deps.push(\n extractRepositoryAction(\n actionRef,\n parsed,\n customRegistryUrlsPackageDependency,\n ),\n );\n }\n }\n\n return deps;\n}\n\nfunction detectDatasource(registryUrl: string): PackageDependency {\n const platform = detectPlatform(registryUrl);\n\n switch (platform) {\n case 'forgejo':\n return {\n registryUrls: [registryUrl],\n datasource: ForgejoTagsDatasource.id,\n };\n case 'gitea':\n return {\n registryUrls: [registryUrl],\n datasource: GiteaTagsDatasource.id,\n };\n case 'github':\n return { registryUrls: [registryUrl] };\n }\n\n return {\n skipReason: 'unsupported-url',\n };\n}\n\nconst runnerVersionRegex = regEx(\n /^\\s*(?<depName>[a-zA-Z]+)-(?<currentValue>[^\\s]+)/,\n);\n\nfunction extractRunner(runner: string): PackageDependency | null {\n const runnerVersionGroups = runnerVersionRegex.exec(runner)?.groups;\n if (!runnerVersionGroups) {\n return null;\n }\n\n const { depName, currentValue } = runnerVersionGroups;\n\n if (!GithubRunnersDatasource.isValidRunner(depName, currentValue)) {\n return null;\n }\n\n const dependency: PackageDependency = {\n depName,\n currentValue,\n replaceString: `${depName}-${currentValue}`,\n depType: 'github-runner',\n datasource: GithubRunnersDatasource.id,\n autoReplaceStringTemplate: '{{depName}}-{{newValue}}',\n };\n\n if (!dockerVersioning.api.isValid(currentValue)) {\n dependency.skipReason = 'invalid-version';\n }\n\n return dependency;\n}\n\n// For official https://github.com/actions\nconst versionedActions: Record<string, string> = {\n go: npmVersioning.id,\n node: nodeVersioning.id,\n python: npmVersioning.id,\n\n // Not covered yet because they use different datasources/packageNames:\n // - dotnet\n // - java\n};\n\nfunction extractVersionedAction(step: UsesStep): PackageDependency | null {\n for (const [action, versioning] of Object.entries(versionedActions)) {\n const actionName = `actions/setup-${action}`;\n if (step.uses !== actionName && !step.uses?.startsWith(`${actionName}@`)) {\n continue;\n }\n\n const fieldName = `${action}-version`;\n const currentValue = step.with?.[fieldName];\n if (!currentValue) {\n return null;\n }\n\n return {\n datasource: GithubReleasesDatasource.id,\n depName: action,\n packageName: `actions/${action}-versions`,\n versioning,\n extractVersion: '^(?<version>\\\\d+\\\\.\\\\d+\\\\.\\\\d+)(-\\\\d+)?$',\n currentValue,\n depType: 'uses-with',\n };\n }\n return null;\n}\n\nfunction extractSteps(steps: UsesStep[]): PackageDependency[] {\n const deps: PackageDependency[] = [];\n\n for (const step of steps) {\n const res = CommunityActions.safeParse(step);\n if (res.success) {\n deps.push(...res.data);\n continue;\n }\n\n const versionedDep = extractVersionedAction(step);\n if (versionedDep) {\n deps.push(versionedDep);\n }\n }\n\n return deps;\n}\n\nfunction extractWithYAMLParser(\n content: string,\n packageFile: string,\n config: ExtractConfig,\n): PackageDependency[] {\n logger.trace('github-actions.extractWithYAMLParser()');\n\n const obj = withMeta({ packageFile }, () => Workflow.parse(content));\n if (!obj) {\n return [];\n }\n\n if ('runs' in obj && obj.runs.steps) {\n return extractSteps(obj.runs.steps);\n }\n\n if (!('jobs' in obj)) {\n return [];\n }\n\n const deps: PackageDependency[] = [];\n\n for (const job of Object.values(obj.jobs)) {\n if (job.container) {\n const dep = getDep(job.container, true, config.registryAliases);\n if (dep) {\n dep.depType = 'container';\n deps.push(dep);\n }\n }\n\n for (const service of job.services) {\n const dep = getDep(service, true, config.registryAliases);\n if (dep) {\n dep.depType = 'service';\n deps.push(dep);\n }\n }\n\n for (const runner of job['runs-on']) {\n const dep = extractRunner(runner);\n if (dep) {\n deps.push(dep);\n }\n }\n\n deps.push(...extractSteps(job.steps));\n }\n\n return deps;\n}\n\nasync function readLockfile(): Promise<LockfileState> {\n const content = await readLocalFile(actionsLockFile, 'utf8');\n if (!content) {\n return { type: 'missing' };\n }\n\n const parsed = ActionsLockfile.safeParse(content);\n if (!parsed.success) {\n // `updateActionsLockfile` warns about this once per branch, so stay quiet\n logger.debug(`Failed to parse ${actionsLockFile}`);\n return { type: 'unparseable' };\n }\n\n return { type: 'parsed', onboardedWorkflows: parsed.data.workflows };\n}\n\n/**\n * A repository has a single lock file, but can have any number of package files, so read and parse it only once.\n */\nfunction getLockfile(): Promise<LockfileState> {\n const cacheKey = `github-actions:${actionsLockFile}`;\n const cached = memCache.get<Promise<LockfileState> | undefined>(cacheKey);\n if (cached !== undefined) {\n return cached;\n }\n\n const result = readLockfile();\n memCache.set(cacheKey, result);\n return result;\n}\n\n/**\n * Whether `gh actions-lock` owns the digests in this file.\n *\n * It rewrites the workflows it manages back to plain refs when regenerating, so an inline digest pin would be stripped straight back out.\n */\nasync function isManagedByLockfile(packageFile: string): Promise<boolean> {\n const lockfile = await getLockfile();\n\n switch (lockfile.type) {\n case 'missing':\n return false;\n case 'unparseable':\n // The tool refuses to regenerate a lock file which it cannot parse, so treat everything as managed: pinning inline here would raise a PR which pins the digests the tool owns and leaves the lock file stale.\n return true;\n case 'parsed':\n return isLockfileManaged(packageFile, lockfile.onboardedWorkflows);\n }\n}\n\nexport async function extractPackageFile(\n content: string,\n packageFile: string,\n config: ExtractConfig = {}, // TODO: enforce ExtractConfig\n): Promise<PackageFileContent | null> {\n logger.trace(`github-actions.extractPackageFile(${packageFile})`);\n\n const deps = [\n ...extractWithRegex(content, config),\n ...extractWithYAMLParser(content, packageFile, config),\n ];\n\n if (!deps.length) {\n return null;\n }\n\n const res: PackageFileContent = { deps };\n\n if (await isManagedByLockfile(packageFile)) {\n // Deliberately no `lockFiles`: nothing here goes through `updateArtifacts`, and `matchFileNames` also tests `lockFiles`, so declaring it would make a negated rule such as `!.github/workflows/release.yml` match every workflow through the lock file path.\n for (const dep of deps) {\n // The lock file only records `OWNER/REPO@REF` pins, so a `docker://` image in a `uses:` is still ours to pin.\n if (dep.depType === 'action' || dep.depType === 'workflow') {\n dep.digestManagedExternally = true;\n }\n }\n }\n\n return res;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAsCA,SAAS,2CAA8D;CACrE,MAAM,WAAW,aAAa,IAAI,UAAU;CAC5C,MAAM,eAAe,CAAC,oBAAoB;CAC1C,IAAI,YAAY,aAAa,IAAI,UAAU,MAAM,UAAU;EACzD,MAAM,iBAAiB,SAAS,QAAQ;EACxC,IAAI,CAAC,gBAAgB;GACnB,OAAO,KAAK,EAAE,SAAS,GAAG,8BAA8B;GACxD,OAAO,CAAC;EACV;EAEA,IACE,eAAe,SAAS,gBACxB,eAAe,SAAS,kBACxB;GACA,aAAa,QACX,GAAG,eAAe,SAAS,IAAI,eAAe,MAChD;GACA,OAAO,EAAE,aAAa;EACxB;CACF;CACA,OAAO,CAAC;AACV;AAEA,SAAS,oBACP,WACA,QACmB;CACnB,MAAM,MAAM,OAAO,UAAU,aAAa,MAAM,OAAO,eAAe;CACtE,IAAI,UAAU;CACd,IAAI,gBAAgB,UAAU;CAC9B,OAAO;AACT;AAEA,MAAM,yBAAyB,MAAM,qCAAqC;AAE1E,SAAS,wBACP,WACA,QACA,qCACmB;CACnB,MAAM,EACJ,eAAe,aACf,OACA,aACA,+BACE;CACJ,MAAM,EACJ,OACA,MACA,MAAM,SACN,KACA,UACA,uBACE;CAEJ,MAAM,cAAc,qBAAqB,WAAW,SAAS,KAAK;CAClE,MAAM,cAAc,GAAG,MAAM,GAAG;CAChC,MAAM,UAAU,GAAG,cAAc;CACjC,MAAM,aAAa,UAAU,IAAI,YAAY;CAC7C,MAAM,YAAY,8BAA8B;CAChD,MAAM,qBAAqB,CAAC,CAAC,WAAW,uBAAuB,KAAK,OAAO;CAE3E,MAAM,MAAyB;EAC7B;EACA,oBAAoB;EACpB,YAAYA;EACZ,SAAS,qBAAqB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AA0B;CAAA;CAKpC,OAAO;AACT"}
|
|
1
|
+
{"version":3,"file":"extract.js","names":["githubActionsVersioning.id","exactVersioning.id","memCache.get"],"sources":["../../../../lib/modules/manager/github-actions/extract.ts"],"sourcesContent":["import is from '@sindresorhus/is';\nimport { GlobalConfig } from '../../../config/global.ts';\nimport { logger, withMeta } from '../../../logger/index.ts';\nimport * as memCache from '../../../util/cache/memory/index.ts';\nimport { detectPlatform } from '../../../util/common.ts';\nimport { readLocalFile } from '../../../util/fs/index.ts';\nimport { newlineRegex, regEx } from '../../../util/regex.ts';\nimport { parseUrl } from '../../../util/url.ts';\nimport { ForgejoTagsDatasource } from '../../datasource/forgejo-tags/index.ts';\nimport { GiteaTagsDatasource } from '../../datasource/gitea-tags/index.ts';\nimport { GithubDigestDatasource } from '../../datasource/github-digest/index.ts';\nimport { GithubRunnersDatasource } from '../../datasource/github-runners/index.ts';\nimport { GithubTagsDatasource } from '../../datasource/github-tags/index.ts';\nimport * as dockerVersioning from '../../versioning/docker/index.ts';\nimport * as exactVersioning from '../../versioning/exact/index.ts';\nimport * as githubActionsVersioning from '../../versioning/github-actions/index.ts';\nimport { getDep } from '../dockerfile/extract.ts';\nimport type {\n ExtractConfig,\n PackageDependency,\n PackageFileContent,\n} from '../types.ts';\nimport { actionsLockFile, isLockfileManaged } from './common.ts';\nimport { isSha, isShortSha, parseUsesLine, versionLikeRe } from './parse.ts';\nimport type { UsesStep } from './schema.ts';\nimport { ActionsLockfile, CommunityActions, Workflow } from './schema.ts';\nimport type {\n DockerReference,\n LockfileState,\n RepositoryReference,\n} from './types.ts';\n\n// detects if we run against a Github Enterprise Server and adds the URL to the beginning of the registryURLs for looking up Actions\n// This reflects the behavior of how GitHub looks up Actions\n// First on the Enterprise Server, then on GitHub.com\nfunction detectCustomGitHubRegistryUrlsForActions(): PackageDependency {\n const endpoint = GlobalConfig.get('endpoint');\n const registryUrls = ['https://github.com'];\n if (endpoint && GlobalConfig.get('platform') === 'github') {\n const parsedEndpoint = parseUrl(endpoint);\n if (!parsedEndpoint) {\n logger.warn({ endpoint }, 'Failed to parse endpoint url');\n return {};\n }\n\n if (\n parsedEndpoint.host !== 'github.com' &&\n parsedEndpoint.host !== 'api.github.com'\n ) {\n registryUrls.unshift(\n `${parsedEndpoint.protocol}//${parsedEndpoint.host}`,\n );\n return { registryUrls };\n }\n }\n return {};\n}\n\nfunction extractDockerAction(\n actionRef: DockerReference,\n config: ExtractConfig,\n): PackageDependency {\n const dep = getDep(actionRef.originalRef, true, config.registryAliases);\n dep.depType = 'docker';\n dep.replaceString = actionRef.originalRef;\n return dep;\n}\n\nconst reusableWorkflowPathRe = regEx(/^\\.github\\/workflows\\/[^/]+\\.ya?ml$/);\n\nfunction extractRepositoryAction(\n actionRef: RepositoryReference,\n parsed: ReturnType<typeof parseUsesLine> & object,\n customRegistryUrlsPackageDependency: PackageDependency,\n): PackageDependency {\n const {\n replaceString: valueString,\n quote,\n commentData,\n commentPrecedingWhitespace,\n } = parsed;\n const {\n owner,\n repo,\n path: subPath,\n ref,\n hostname,\n isExplicitHostname,\n } = actionRef;\n\n const registryUrl = isExplicitHostname ? `https://${hostname}/` : '';\n const packageName = `${owner}/${repo}`;\n const depName = `${registryUrl}${packageName}`;\n const pathSuffix = subPath ? `/${subPath}` : '';\n const commentWs = commentPrecedingWhitespace || ' ';\n const isReusableWorkflow = !!subPath && reusableWorkflowPathRe.test(subPath);\n\n const dep: PackageDependency = {\n depName,\n commitMessageTopic: '{{{depName}}} action',\n versioning: githubActionsVersioning.id,\n depType: isReusableWorkflow ? 'workflow' : 'action',\n replaceString: valueString,\n autoReplaceStringTemplate: `${quote}{{depName}}${pathSuffix}@{{#if newDigest}}{{newDigest}}${quote}{{#if newValue}}${commentWs}# {{newValue}}{{/if}}{{/if}}{{#unless newDigest}}{{newValue}}${quote}{{/unless}}`,\n ...(isExplicitHostname\n ? detectDatasource(registryUrl)\n : customRegistryUrlsPackageDependency),\n };\n\n if (packageName !== depName) {\n dep.packageName = packageName;\n }\n\n // Extend replaceString to include relevant comment portions:\n // - Pinned version or ref: include only up to the matched token (truncate trailing text)\n // - Ratchet exclude: include the full comment to preserve the marker\n const pinComment =\n commentData.pinnedVersion ??\n (isSha(ref) || isShortSha(ref) ? commentData.ref : undefined);\n if (\n pinComment &&\n !is.undefined(commentData.index) &&\n !is.undefined(commentData.matchedString)\n ) {\n const cleanComment = parsed.commentString.slice(1);\n const matchEndIndex = commentData.index + commentData.matchedString.length;\n const commentSuffix = cleanComment.slice(0, matchEndIndex);\n dep.replaceString = `${valueString}${commentPrecedingWhitespace}#${commentSuffix}`;\n } else if (commentData.ratchetExclude) {\n dep.replaceString =\n valueString + commentPrecedingWhitespace + parsed.commentString;\n }\n\n if (isSha(ref)) {\n dep.currentValue = commentData.pinnedVersion ?? commentData.ref;\n dep.currentDigest = ref;\n } else if (isShortSha(ref)) {\n dep.currentValue = commentData.pinnedVersion ?? commentData.ref;\n dep.currentDigestShort = ref;\n } else {\n dep.currentValue = ref;\n }\n\n if (!dep.currentValue) {\n dep.enabled = false;\n dep.skipReason = 'unversioned-reference';\n }\n\n const isVersionLike =\n dep.currentValue && versionLikeRe.test(dep.currentValue);\n if (!dep.datasource && dep.currentValue && !isVersionLike) {\n dep.datasource = GithubDigestDatasource.id;\n dep.versioning = exactVersioning.id;\n }\n\n dep.datasource ??= GithubTagsDatasource.id;\n\n return dep;\n}\n\nfunction extractWithRegex(\n content: string,\n config: ExtractConfig,\n): PackageDependency[] {\n const customRegistryUrlsPackageDependency =\n detectCustomGitHubRegistryUrlsForActions();\n logger.trace('github-actions.extractWithRegex()');\n const deps: PackageDependency[] = [];\n\n for (const line of content.split(newlineRegex)) {\n if (line.trim().startsWith('#')) {\n continue;\n }\n\n const parsed = parseUsesLine(line);\n if (!parsed?.actionRef) {\n continue;\n }\n\n const { actionRef } = parsed;\n\n if (actionRef.kind === 'docker') {\n deps.push(extractDockerAction(actionRef, config));\n continue;\n }\n\n if (actionRef.kind === 'repository') {\n deps.push(\n extractRepositoryAction(\n actionRef,\n parsed,\n customRegistryUrlsPackageDependency,\n ),\n );\n }\n }\n\n return deps;\n}\n\nfunction detectDatasource(registryUrl: string): PackageDependency {\n const platform = detectPlatform(registryUrl);\n\n switch (platform) {\n case 'forgejo':\n return {\n registryUrls: [registryUrl],\n datasource: ForgejoTagsDatasource.id,\n };\n case 'gitea':\n return {\n registryUrls: [registryUrl],\n datasource: GiteaTagsDatasource.id,\n };\n case 'github':\n return { registryUrls: [registryUrl] };\n }\n\n return {\n skipReason: 'unsupported-url',\n };\n}\n\nconst runnerVersionRegex = regEx(\n /^\\s*(?<depName>[a-zA-Z]+)-(?<currentValue>[^\\s]+)/,\n);\n\nfunction extractRunner(runner: string): PackageDependency | null {\n const runnerVersionGroups = runnerVersionRegex.exec(runner)?.groups;\n if (!runnerVersionGroups) {\n return null;\n }\n\n const { depName, currentValue } = runnerVersionGroups;\n\n if (!GithubRunnersDatasource.isValidRunner(depName, currentValue)) {\n return null;\n }\n\n const dependency: PackageDependency = {\n depName,\n currentValue,\n replaceString: `${depName}-${currentValue}`,\n depType: 'github-runner',\n datasource: GithubRunnersDatasource.id,\n autoReplaceStringTemplate: '{{depName}}-{{newValue}}',\n };\n\n if (!dockerVersioning.api.isValid(currentValue)) {\n dependency.skipReason = 'invalid-version';\n }\n\n return dependency;\n}\n\nfunction extractSteps(steps: UsesStep[]): PackageDependency[] {\n const deps: PackageDependency[] = [];\n\n for (const step of steps) {\n const res = CommunityActions.safeParse(step);\n if (res.success) {\n deps.push(...res.data);\n }\n }\n\n return deps;\n}\n\nfunction extractWithYAMLParser(\n content: string,\n packageFile: string,\n config: ExtractConfig,\n): PackageDependency[] {\n logger.trace('github-actions.extractWithYAMLParser()');\n\n const obj = withMeta({ packageFile }, () => Workflow.parse(content));\n if (!obj) {\n return [];\n }\n\n if ('runs' in obj && obj.runs.steps) {\n return extractSteps(obj.runs.steps);\n }\n\n if (!('jobs' in obj)) {\n return [];\n }\n\n const deps: PackageDependency[] = [];\n\n for (const job of Object.values(obj.jobs)) {\n if (job.container) {\n const dep = getDep(job.container, true, config.registryAliases);\n if (dep) {\n dep.depType = 'container';\n deps.push(dep);\n }\n }\n\n for (const service of job.services) {\n const dep = getDep(service, true, config.registryAliases);\n if (dep) {\n dep.depType = 'service';\n deps.push(dep);\n }\n }\n\n for (const runner of job['runs-on']) {\n const dep = extractRunner(runner);\n if (dep) {\n deps.push(dep);\n }\n }\n\n deps.push(...extractSteps(job.steps));\n }\n\n return deps;\n}\n\nasync function readLockfile(): Promise<LockfileState> {\n const content = await readLocalFile(actionsLockFile, 'utf8');\n if (!content) {\n return { type: 'missing' };\n }\n\n const parsed = ActionsLockfile.safeParse(content);\n if (!parsed.success) {\n // `updateActionsLockfile` warns about this once per branch, so stay quiet\n logger.debug(`Failed to parse ${actionsLockFile}`);\n return { type: 'unparseable' };\n }\n\n return { type: 'parsed', onboardedWorkflows: parsed.data.workflows };\n}\n\n/**\n * A repository has a single lock file, but can have any number of package files, so read and parse it only once.\n */\nfunction getLockfile(): Promise<LockfileState> {\n const cacheKey = `github-actions:${actionsLockFile}`;\n const cached = memCache.get<Promise<LockfileState> | undefined>(cacheKey);\n if (cached !== undefined) {\n return cached;\n }\n\n const result = readLockfile();\n memCache.set(cacheKey, result);\n return result;\n}\n\n/**\n * Whether `gh actions-lock` owns the digests in this file.\n *\n * It rewrites the workflows it manages back to plain refs when regenerating, so an inline digest pin would be stripped straight back out.\n */\nasync function isManagedByLockfile(packageFile: string): Promise<boolean> {\n const lockfile = await getLockfile();\n\n switch (lockfile.type) {\n case 'missing':\n return false;\n case 'unparseable':\n // The tool refuses to regenerate a lock file which it cannot parse, so treat everything as managed: pinning inline here would raise a PR which pins the digests the tool owns and leaves the lock file stale.\n return true;\n case 'parsed':\n return isLockfileManaged(packageFile, lockfile.onboardedWorkflows);\n }\n}\n\nexport async function extractPackageFile(\n content: string,\n packageFile: string,\n config: ExtractConfig = {}, // TODO: enforce ExtractConfig\n): Promise<PackageFileContent | null> {\n logger.trace(`github-actions.extractPackageFile(${packageFile})`);\n\n const deps = [\n ...extractWithRegex(content, config),\n ...extractWithYAMLParser(content, packageFile, config),\n ];\n\n if (!deps.length) {\n return null;\n }\n\n const res: PackageFileContent = { deps };\n\n if (await isManagedByLockfile(packageFile)) {\n // Deliberately no `lockFiles`: nothing here goes through `updateArtifacts`, and `matchFileNames` also tests `lockFiles`, so declaring it would make a negated rule such as `!.github/workflows/release.yml` match every workflow through the lock file path.\n for (const dep of deps) {\n // The lock file only records `OWNER/REPO@REF` pins, so a `docker://` image in a `uses:` is still ours to pin.\n if (dep.depType === 'action' || dep.depType === 'workflow') {\n dep.digestManagedExternally = true;\n }\n }\n }\n\n return res;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAmCA,SAAS,2CAA8D;CACrE,MAAM,WAAW,aAAa,IAAI,UAAU;CAC5C,MAAM,eAAe,CAAC,oBAAoB;CAC1C,IAAI,YAAY,aAAa,IAAI,UAAU,MAAM,UAAU;EACzD,MAAM,iBAAiB,SAAS,QAAQ;EACxC,IAAI,CAAC,gBAAgB;GACnB,OAAO,KAAK,EAAE,SAAS,GAAG,8BAA8B;GACxD,OAAO,CAAC;EACV;EAEA,IACE,eAAe,SAAS,gBACxB,eAAe,SAAS,kBACxB;GACA,aAAa,QACX,GAAG,eAAe,SAAS,IAAI,eAAe,MAChD;GACA,OAAO,EAAE,aAAa;EACxB;CACF;CACA,OAAO,CAAC;AACV;AAEA,SAAS,oBACP,WACA,QACmB;CACnB,MAAM,MAAM,OAAO,UAAU,aAAa,MAAM,OAAO,eAAe;CACtE,IAAI,UAAU;CACd,IAAI,gBAAgB,UAAU;CAC9B,OAAO;AACT;AAEA,MAAM,yBAAyB,MAAM,qCAAqC;AAE1E,SAAS,wBACP,WACA,QACA,qCACmB;CACnB,MAAM,EACJ,eAAe,aACf,OACA,aACA,+BACE;CACJ,MAAM,EACJ,OACA,MACA,MAAM,SACN,KACA,UACA,uBACE;CAEJ,MAAM,c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,UAAU;CAG3B,MAAM,SAAS,gBAAgB,UAAU,OAAO;CAChD,IAAI,CAAC,OAAO,SAAS;EAEnB,OAAO,MAAM,mBAAmB,iBAAiB;EACjD,OAAO,EAAE,MAAM,cAAc;CAC/B;CAEA,OAAO;EAAE,MAAM;EAAU,oBAAoB,OAAO,KAAK;CAAU;AACrE;;;;AAKA,SAAS,cAAsC;CAC7C,MAAM,WAAW,kBAAkB;CACnC,MAAM,SAASC,IAAiD,QAAQ;CACxE,IAAI,WAAW,KAAA,GACb,OAAO;CAGT,MAAM,SAAS,aAAa;CAC5B,IAAa,UAAU,MAAM;CAC7B,OAAO;AACT;;;;;;AAOA,eAAe,oBAAoB,aAAuC;CACxE,MAAM,WAAW,MAAM,YAAY;CAEnC,QAAQ,SAAS,MAAjB;EACE,KAAK,WACH,OAAO;EACT,KAAK,eAEH,OAAO;EACT,KAAK,UACH,OAAO,kBAAkB,aAAa,SAAS,kBAAkB;CACrE;AACF;AAEA,eAAsB,mBACpB,SACA,aACA,SAAwB,CAAC,GACW;CACpC,OAAO,MAAM,qCAAqC,YAAY,EAAE;CAEhE,MAAM,OAAO,CACX,GAAG,iBAAiB,SAAS,MAAM,GACnC,GAAG,sBAAsB,SAAS,aAAa,MAAM,CACvD;CAEA,IAAI,CAAC,KAAK,QACR,OAAO;CAGT,MAAM,MAA0B,EAAE,KAAK;CAEvC,IAAI,MAAM,oBAAoB,WAAW,GAElC;OAAA,MAAM,OAAO,MAEhB,IAAI,IAAI,YAAY,YAAY,IAAI,YAAY,YAC9C,IAAI,0BAA0B;CAAA;CAKpC,OAAO;AACT"}
|
|
@@ -1,16 +1,19 @@
|
|
|
1
1
|
import { regEx } from "../../../util/regex.js";
|
|
2
2
|
import "../../versioning/npm/index.js";
|
|
3
3
|
import { id } from "../../versioning/conda/index.js";
|
|
4
|
+
import { id as id$1 } from "../../versioning/node/index.js";
|
|
4
5
|
import { DockerDatasource } from "../../datasource/docker/index.js";
|
|
6
|
+
import { DotnetVersionDatasource } from "../../datasource/dotnet-version/index.js";
|
|
5
7
|
import { GithubReleaseAttachmentsDatasource } from "../../datasource/github-release-attachments/index.js";
|
|
6
8
|
import { GithubReleasesDatasource } from "../../datasource/github-releases/index.js";
|
|
9
|
+
import { JavaVersionDatasource } from "../../datasource/java-version/index.js";
|
|
7
10
|
import { NodeVersionDatasource } from "../../datasource/node-version/index.js";
|
|
8
11
|
import { NpmDatasource } from "../../datasource/npm/index.js";
|
|
9
12
|
import { PypiDatasource } from "../../datasource/pypi/index.js";
|
|
10
13
|
import { RubyVersionDatasource } from "../../datasource/ruby-version/index.js";
|
|
11
14
|
import { RustVersionDatasource } from "../../datasource/rust-version/index.js";
|
|
12
15
|
import { z } from "zod/v4";
|
|
13
|
-
//#region lib/modules/manager/github-actions/
|
|
16
|
+
//#region lib/modules/manager/github-actions/known-actions.ts
|
|
14
17
|
function actionSchema(name, { withSchema, ...cfg }) {
|
|
15
18
|
return z.object({
|
|
16
19
|
uses: matchAction(name),
|
|
@@ -53,6 +56,7 @@ function valSchema(key, isInvalid) {
|
|
|
53
56
|
return z.object({ [key]: z.string().optional() }).transform((val) => [parseValue(val[key], isInvalid)]);
|
|
54
57
|
}
|
|
55
58
|
const VersionVal = valSchema("version");
|
|
59
|
+
const actionsVersionsExtractVersion = "^(?<version>\\d+\\.\\d+\\.\\d+)(-\\d+)?$";
|
|
56
60
|
const InstallBinaryWith = z.object({
|
|
57
61
|
repo: z.string(),
|
|
58
62
|
tag: z.string()
|
|
@@ -101,6 +105,24 @@ const PnpmSetupWith = z.object({
|
|
|
101
105
|
version: z.string().optional(),
|
|
102
106
|
runtime: z.string().optional()
|
|
103
107
|
}).transform(({ version, runtime }) => [parseValue(version), ...parsePnpmRuntime(runtime)]);
|
|
108
|
+
const supportedJavaDistributions = /* @__PURE__ */ new Set(["temurin", "adopt"]);
|
|
109
|
+
const SetupJavaWith = z.object({
|
|
110
|
+
distribution: z.string().optional(),
|
|
111
|
+
"java-version": z.string().optional(),
|
|
112
|
+
"java-package": z.string().optional()
|
|
113
|
+
}).transform(({ distribution, "java-version": version, "java-package": javaPackage }) => {
|
|
114
|
+
const packageName = javaPackage?.startsWith("jre") ? "java-jre" : "java-jdk";
|
|
115
|
+
if (!distribution || !supportedJavaDistributions.has(distribution.toLowerCase())) return [{
|
|
116
|
+
packageName,
|
|
117
|
+
depType: "uses-with",
|
|
118
|
+
skipStage: "extract",
|
|
119
|
+
skipReason: "unsupported"
|
|
120
|
+
}];
|
|
121
|
+
return [{
|
|
122
|
+
packageName,
|
|
123
|
+
...parseValue(version)
|
|
124
|
+
}];
|
|
125
|
+
});
|
|
104
126
|
const renovateGithubActionDefaultImage = "ghcr.io/renovatebot/renovate";
|
|
105
127
|
const RenovateGithubActionWith = z.object({
|
|
106
128
|
"renovate-version": z.string().optional(),
|
|
@@ -114,9 +136,44 @@ const RenovateGithubActionWith = z.object({
|
|
|
114
136
|
}];
|
|
115
137
|
});
|
|
116
138
|
/**
|
|
117
|
-
* Community
|
|
139
|
+
* Community-maintained and first-party (GitHub's own `actions/*`) Actions
|
|
140
|
+
* with known version input schemas.
|
|
118
141
|
*/
|
|
119
|
-
const
|
|
142
|
+
const knownActions = {
|
|
143
|
+
"actions/setup-dotnet": {
|
|
144
|
+
datasource: DotnetVersionDatasource.id,
|
|
145
|
+
packageName: "dotnet-sdk",
|
|
146
|
+
withSchema: valSchema("dotnet-version", (val) => val.includes("\n"))
|
|
147
|
+
},
|
|
148
|
+
"actions/setup-go": {
|
|
149
|
+
datasource: GithubReleasesDatasource.id,
|
|
150
|
+
depName: "go",
|
|
151
|
+
packageName: "actions/go-versions",
|
|
152
|
+
versioning: "npm",
|
|
153
|
+
extractVersion: actionsVersionsExtractVersion,
|
|
154
|
+
withSchema: valSchema("go-version")
|
|
155
|
+
},
|
|
156
|
+
"actions/setup-java": {
|
|
157
|
+
datasource: JavaVersionDatasource.id,
|
|
158
|
+
packageName: "",
|
|
159
|
+
withSchema: SetupJavaWith
|
|
160
|
+
},
|
|
161
|
+
"actions/setup-node": {
|
|
162
|
+
datasource: GithubReleasesDatasource.id,
|
|
163
|
+
depName: "node",
|
|
164
|
+
packageName: "actions/node-versions",
|
|
165
|
+
versioning: id$1,
|
|
166
|
+
extractVersion: actionsVersionsExtractVersion,
|
|
167
|
+
withSchema: valSchema("node-version")
|
|
168
|
+
},
|
|
169
|
+
"actions/setup-python": {
|
|
170
|
+
datasource: GithubReleasesDatasource.id,
|
|
171
|
+
depName: "python",
|
|
172
|
+
packageName: "actions/python-versions",
|
|
173
|
+
versioning: "npm",
|
|
174
|
+
extractVersion: actionsVersionsExtractVersion,
|
|
175
|
+
withSchema: valSchema("python-version")
|
|
176
|
+
},
|
|
120
177
|
"aquasecurity/setup-trivy": {
|
|
121
178
|
datasource: GithubReleasesDatasource.id,
|
|
122
179
|
packageName: "aquasecurity/trivy"
|
|
@@ -248,6 +305,6 @@ const communityActions = {
|
|
|
248
305
|
}
|
|
249
306
|
};
|
|
250
307
|
//#endregion
|
|
251
|
-
export { actionSchema,
|
|
308
|
+
export { actionSchema, knownActions };
|
|
252
309
|
|
|
253
|
-
//# sourceMappingURL=
|
|
310
|
+
//# sourceMappingURL=known-actions.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"known-actions.js","names":["nodeVersioning.id","condaVersioning.id"],"sources":["../../../../lib/modules/manager/github-actions/known-actions.ts"],"sourcesContent":["import { z } from 'zod/v4';\n\nimport { regEx } from '../../../util/regex.ts';\nimport { DockerDatasource } from '../../datasource/docker/index.ts';\nimport { DotnetVersionDatasource } from '../../datasource/dotnet-version/index.ts';\nimport { GithubReleaseAttachmentsDatasource } from '../../datasource/github-release-attachments/index.ts';\nimport { GithubReleasesDatasource } from '../../datasource/github-releases/index.ts';\nimport { JavaVersionDatasource } from '../../datasource/java-version/index.ts';\nimport { NodeVersionDatasource } from '../../datasource/node-version/index.ts';\nimport { NpmDatasource } from '../../datasource/npm/index.ts';\nimport { PypiDatasource } from '../../datasource/pypi/index.ts';\nimport { RubyVersionDatasource } from '../../datasource/ruby-version/index.ts';\nimport { RustVersionDatasource } from '../../datasource/rust-version/index.ts';\nimport * as condaVersioning from '../../versioning/conda/index.ts';\nimport * as nodeVersioning from '../../versioning/node/index.ts';\nimport * as npmVersioning from '../../versioning/npm/index.ts';\nimport type { PackageDependency } from '../types.ts';\nimport type { ActionSchema, KnownActionConfig } from './types.ts';\n\nexport function actionSchema(\n name: string,\n { withSchema, ...cfg }: KnownActionConfig,\n): ActionSchema {\n return z\n .object({\n uses: matchAction(name),\n with: withSchema ?? VersionVal,\n })\n .transform(({ with: deps }) =>\n deps.map((dep) => {\n const merged = { ...cfg, ...dep };\n merged.depName ??= merged.packageName;\n return merged;\n }),\n );\n}\n\nfunction matchAction(action: string): z.ZodString {\n return z\n .string()\n .regex(regEx(`(?:https?://[^/]+/)?${RegExp.escape(action)}(?:@.+)?$`));\n}\n\nfunction parseValue(\n currentValue: string | undefined,\n isInvalid?: (val: string) => boolean,\n): PackageDependency {\n if (!currentValue) {\n return {\n skipStage: 'extract',\n skipReason: 'unspecified-version',\n depType: 'uses-with',\n };\n }\n if (isInvalid?.(currentValue) === true) {\n return {\n skipStage: 'extract',\n skipReason: 'invalid-version',\n depType: 'uses-with',\n currentValue,\n };\n }\n return { currentValue, depType: 'uses-with' };\n}\n\n/**\n * A single dependency, versioned by the given `with:` input.\n *\n * @param isInvalid should return `true` if the version is invalid and should be skipped\n */\nfunction valSchema(\n key: string,\n isInvalid?: (val: string) => boolean,\n): ActionSchema {\n return z\n .object({ [key]: z.string().optional() })\n .transform((val) => [parseValue(val[key], isInvalid)]);\n}\n\nconst VersionVal = valSchema('version');\n\n// Shared by the `actions/setup-{go,node,python}` entries below, whose\n// releases are published as `actions/{go,node,python}-versions` GitHub\n// releases, tagged like `20.11.0` or `20.11.0-1` (a build number suffix).\nconst actionsVersionsExtractVersion =\n '^(?<version>\\\\d+\\\\.\\\\d+\\\\.\\\\d+)(-\\\\d+)?$';\n\nconst InstallBinaryWith: ActionSchema = z\n .object({ repo: z.string(), tag: z.string() })\n .transform(({ repo, tag }) => [{ packageName: repo, ...parseValue(tag) }]);\n\nconst sha256Regex = regEx(/^[a-f0-9]{64}$/);\nconst MiseWith: ActionSchema = z\n .object({\n version: z.string().optional(),\n sha256: z.string().optional(),\n })\n .transform(({ version, sha256 }) => [\n {\n ...parseValue(version),\n ...(sha256 && sha256Regex.test(sha256) ? { currentDigest: sha256 } : {}),\n },\n ]);\n\n// Runtimes installable by `pnpm/setup`, keyed by the name used in its\n// `runtime:` input. `bun` and `deno` reuse the datasources of their respective\n// `setup-*` actions below.\nconst pnpmRuntimes: Record<string, PackageDependency | undefined> = {\n node: { datasource: NodeVersionDatasource.id, packageName: 'node' },\n bun: { datasource: NpmDatasource.id, packageName: 'bun' },\n deno: { datasource: NpmDatasource.id, packageName: 'deno' },\n};\n\nfunction parsePnpmRuntime(runtime: string | undefined): PackageDependency[] {\n if (!runtime) {\n return [];\n }\n\n // `<name>` or `<name>@<version>`, matching pnpm's `packageManager` field syntax\n const [name, version] = runtime.split('@');\n const cfg = pnpmRuntimes[name];\n if (!cfg) {\n return [\n {\n packageName: name || runtime,\n depType: 'uses-with',\n skipStage: 'extract',\n skipReason: 'invalid-name',\n },\n ];\n }\n\n return [{ ...cfg, ...parseValue(version) }];\n}\n\nconst PnpmSetupWith: ActionSchema = z\n .object({\n version: z.string().optional(),\n runtime: z.string().optional(),\n })\n .transform(({ version, runtime }) => [\n parseValue(version),\n ...parsePnpmRuntime(runtime),\n ]);\n\n// Distributions whose version numbering we can reliably track via the\n// java-version datasource (which sources releases from Adoptium/Eclipse\n// Temurin). Other distributions may not follow the same release cadence\n// or versioning, so we don't attempt to track them.\nconst supportedJavaDistributions = new Set(['temurin', 'adopt']);\n\nconst SetupJavaWith: ActionSchema = z\n .object({\n distribution: z.string().optional(),\n 'java-version': z.string().optional(),\n 'java-package': z.string().optional(),\n })\n .transform(\n ({\n distribution,\n 'java-version': version,\n 'java-package': javaPackage,\n }) => {\n const packageName = javaPackage?.startsWith('jre')\n ? 'java-jre'\n : 'java-jdk';\n\n if (\n !distribution ||\n !supportedJavaDistributions.has(distribution.toLowerCase())\n ) {\n return [\n {\n packageName,\n depType: 'uses-with',\n skipStage: 'extract',\n skipReason: 'unsupported',\n },\n ];\n }\n\n return [{ packageName, ...parseValue(version) }];\n },\n );\n\nconst renovateGithubActionDefaultImage = 'ghcr.io/renovatebot/renovate';\nconst RenovateGithubActionWith: ActionSchema = z\n .object({\n 'renovate-version': z.string().optional(),\n 'renovate-image': z.string().optional(),\n })\n .transform(({ 'renovate-version': version, 'renovate-image': image }) => {\n const [packageName, currentDigest] = (\n image ?? renovateGithubActionDefaultImage\n ).split('@');\n return [\n {\n packageName,\n ...(currentDigest ? { currentDigest } : {}),\n ...parseValue(version),\n },\n ];\n });\n\n/**\n * Community-maintained and first-party (GitHub's own `actions/*`) Actions\n * with known version input schemas.\n */\nexport const knownActions: Record<string, KnownActionConfig> = {\n // https://github.com/actions/setup-dotnet\n 'actions/setup-dotnet': {\n datasource: DotnetVersionDatasource.id,\n packageName: 'dotnet-sdk',\n withSchema: valSchema('dotnet-version', (val) => val.includes('\\n')),\n },\n // https://github.com/actions/setup-go\n 'actions/setup-go': {\n datasource: GithubReleasesDatasource.id,\n depName: 'go',\n packageName: 'actions/go-versions',\n versioning: npmVersioning.id,\n extractVersion: actionsVersionsExtractVersion,\n withSchema: valSchema('go-version'),\n },\n // https://github.com/actions/setup-java\n 'actions/setup-java': {\n datasource: JavaVersionDatasource.id,\n packageName: '', // determined from `distribution`/`java-package` inputs\n withSchema: SetupJavaWith,\n },\n // https://github.com/actions/setup-node\n 'actions/setup-node': {\n datasource: GithubReleasesDatasource.id,\n depName: 'node',\n packageName: 'actions/node-versions',\n versioning: nodeVersioning.id,\n extractVersion: actionsVersionsExtractVersion,\n withSchema: valSchema('node-version'),\n },\n // https://github.com/actions/setup-python\n 'actions/setup-python': {\n datasource: GithubReleasesDatasource.id,\n depName: 'python',\n packageName: 'actions/python-versions',\n versioning: npmVersioning.id,\n extractVersion: actionsVersionsExtractVersion,\n withSchema: valSchema('python-version'),\n },\n // https://github.com/aquasecurity/setup-trivy\n 'aquasecurity/setup-trivy': {\n datasource: GithubReleasesDatasource.id,\n packageName: 'aquasecurity/trivy',\n },\n // https://github.com/aquasecurity/trivy-action\n 'aquasecurity/trivy-action': {\n datasource: GithubReleasesDatasource.id,\n packageName: 'aquasecurity/trivy',\n },\n // https://github.com/astral-sh/setup-uv\n 'astral-sh/setup-uv': {\n datasource: GithubReleasesDatasource.id,\n versioning: npmVersioning.id,\n packageName: 'astral-sh/uv',\n },\n 'azure/setup-helm': {\n datasource: GithubReleasesDatasource.id,\n depName: 'helm',\n packageName: 'helm/helm',\n },\n // https://github.com/azure/setup-helm\n 'denoland/setup-deno': {\n datasource: NpmDatasource.id,\n packageName: 'deno',\n withSchema: valSchema('deno-version'),\n },\n // https://github.com/docker/setup-buildx-action\n 'docker/setup-buildx-action': {\n datasource: GithubReleasesDatasource.id,\n depName: 'buildx',\n packageName: 'docker/buildx',\n },\n // https://github.com/docker/setup-compose-action\n 'docker/setup-compose-action': {\n datasource: GithubReleasesDatasource.id,\n packageName: 'docker/compose',\n },\n // https://github.com/docker/setup-docker-action\n 'docker/setup-docker-action': {\n datasource: GithubReleasesDatasource.id,\n depName: 'docker',\n packageName: 'moby/moby',\n extractVersion: '^docker-(?<version>.+)$',\n },\n // https://github.com/dtolnay/rust-toolchain\n 'dtolnay/rust-toolchain': {\n datasource: RustVersionDatasource.id,\n packageName: 'rust',\n withSchema: valSchema('toolchain'),\n },\n // https://github.com/expo/expo-github-action\n 'expo/expo-github-action': {\n datasource: NpmDatasource.id,\n packageName: 'eas-cli',\n withSchema: valSchema('eas-version'),\n },\n 'golangci/golangci-lint-action': {\n datasource: GithubReleasesDatasource.id,\n packageName: 'golangci/golangci-lint',\n },\n // https://github.com/helm/chart-testing-action\n 'helm/chart-testing-action': {\n datasource: GithubReleasesDatasource.id,\n depName: 'chart-testing',\n packageName: 'helm/chart-testing',\n },\n 'jakebailey/pyright-action': {\n datasource: NpmDatasource.id,\n packageName: 'pyright',\n withSchema: valSchema('version', (val) => val === 'PATH'),\n },\n 'jaxxstorm/action-install-gh-release': {\n datasource: GithubReleasesDatasource.id,\n packageName: '', // determined from `repo` input\n withSchema: InstallBinaryWith,\n },\n 'jdx/mise-action': {\n datasource: GithubReleaseAttachmentsDatasource.id,\n packageName: 'jdx/mise',\n withSchema: MiseWith,\n },\n 'oven-sh/setup-bun': {\n datasource: NpmDatasource.id,\n packageName: 'bun',\n withSchema: valSchema('bun-version'),\n },\n 'pdm-project/setup-pdm': {\n datasource: PypiDatasource.id,\n packageName: 'pdm',\n },\n 'pnpm/action-setup': {\n datasource: NpmDatasource.id,\n packageName: 'pnpm',\n },\n 'pnpm/setup': {\n datasource: NpmDatasource.id,\n packageName: 'pnpm',\n withSchema: PnpmSetupWith,\n },\n 'prefix-dev/setup-pixi': {\n datasource: GithubReleasesDatasource.id,\n versioning: condaVersioning.id,\n packageName: 'prefix-dev/pixi',\n withSchema: valSchema('pixi-version'),\n },\n // https://github.com/pypa/hatch/tree/install\n 'pypa/hatch': {\n datasource: GithubReleasesDatasource.id,\n packageName: 'pypa/hatch',\n // Strip hatch- prefix from release tags\n extractVersion: '^hatch-(?<version>.+)$',\n },\n // https://github.com/renovatebot/github-action\n 'renovatebot/github-action': {\n datasource: DockerDatasource.id,\n packageName: '', // determined from `renovate-image` input, if set\n withSchema: RenovateGithubActionWith,\n },\n 'ruby/setup-ruby': {\n datasource: RubyVersionDatasource.id,\n packageName: 'ruby',\n withSchema: valSchema('ruby-version'),\n },\n 'sigoden/install-binary': {\n datasource: GithubReleasesDatasource.id,\n packageName: '', // determined from `repo` input\n withSchema: InstallBinaryWith,\n },\n 'sigstore/cosign-installer': {\n datasource: GithubReleasesDatasource.id,\n packageName: 'sigstore/cosign',\n withSchema: valSchema('cosign-release'),\n },\n 'UpCloudLtd/upcloud-cli-action': {\n datasource: GithubReleasesDatasource.id,\n packageName: 'UpCloudLtd/upcloud-cli',\n },\n 'zizmorcore/zizmor-action': {\n datasource: DockerDatasource.id,\n packageName: 'ghcr.io/zizmorcore/zizmor',\n },\n};\n"],"mappings":";;;;;;;;;;;;;;;;AAmBA,SAAgB,aACd,MACA,EAAE,YAAY,GAAG,OACH;CACd,OAAO,EACJ,OAAO;EACN,MAAM,YAAY,IAAI;EACtB,MAAM,cAAc;CACtB,CAAC,CAAC,CACD,WAAW,EAAE,MAAM,WAClB,KAAK,KAAK,QAAQ;EAChB,MAAM,SAAS;GAAE,GAAG;GAAK,GAAG;EAAI;EAChC,OAAO,YAAY,OAAO;EAC1B,OAAO;CACT,CAAC,CACH;AACJ;AAEA,SAAS,YAAY,QAA6B;CAChD,OAAO,EACJ,OAAO,CAAC,CACR,MAAM,MAAM,uBAAuB,OAAO,OAAO,MAAM,EAAE,UAAU,CAAC;AACzE;AAEA,SAAS,WACP,cACA,WACmB;CACnB,IAAI,CAAC,cACH,OAAO;EACL,WAAW;EACX,YAAY;EACZ,SAAS;CACX;CAEF,IAAI,YAAY,YAAY,MAAM,MAChC,OAAO;EACL,WAAW;EACX,YAAY;EACZ,SAAS;EACT;CACF;CAEF,OAAO;EAAE;EAAc,SAAS;CAAY;AAC9C;;;;;;AAOA,SAAS,UACP,KACA,WACc;CACd,OAAO,EACJ,OAAO,GAAG,MAAM,EAAE,OAAO,CAAC,CAAC,SAAS,EAAE,CAAC,CAAC,CACxC,WAAW,QAAQ,CAAC,WAAW,IAAI,MAAM,SAAS,CAAC,CAAC;AACzD;AAEA,MAAM,aAAa,UAAU,SAAS;AAKtC,MAAM,gCACJ;AAEF,MAAM,oBAAkC,EACrC,OAAO;CAAE,MAAM,EAAE,OAAO;CAAG,KAAK,EAAE,OAAO;AAAE,CAAC,CAAC,CAC7C,WAAW,EAAE,MAAM,UAAU,CAAC;CAAE,aAAa;CAAM,GAAG,WAAW,GAAG;AAAE,CAAC,CAAC;AAE3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EACvB,YAAY,yBAAyB;EACrC,YAAYC;EACZ,aAAa;EACb,YAAY,UAAU,cAAc;CACtC;CAEA,cAAc;EACZ,YAAY,yBAAyB;EACrC,aAAa;EAEb,gBAAgB;CAClB;CAEA,6BAA6B;EAC3B,YAAY,iBAAiB;EAC7B,aAAa;EACb,YAAY;CACd;CACA,mBAAmB;EACjB,YAAY,sBAAsB;EAClC,aAAa;EACb,YAAY,UAAU,cAAc;CACtC;CACA,0BAA0B;EACxB,YAAY,yBAAyB;EACrC,aAAa;EACb,YAAY;CACd;CACA,6BAA6B;EAC3B,YAAY,yBAAyB;EACrC,aAAa;EACb,YAAY,UAAU,gBAAgB;CACxC;CACA,iCAAiC;EAC/B,YAAY,yBAAyB;EACrC,aAAa;CACf;CACA,4BAA4B;EAC1B,YAAY,iBAAiB;EAC7B,aAAa;CACf;AACF"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { LooseArray, LooseRecord, Yaml, withDebugMessage } from "../../../util/schema-utils/index.js";
|
|
2
|
-
import { actionSchema,
|
|
2
|
+
import { actionSchema, knownActions } from "./known-actions.js";
|
|
3
3
|
import { z } from "zod/v4";
|
|
4
4
|
//#region lib/modules/manager/github-actions/schema.ts
|
|
5
5
|
const UsesStep = z.object({
|
|
@@ -32,7 +32,7 @@ const Workflow = Yaml.pipe(z.union([
|
|
|
32
32
|
* TODO #45191: pin to a version of the schema, once it is v1
|
|
33
33
|
*/
|
|
34
34
|
const ActionsLockfile = Yaml.pipe(z.object({ workflows: z.record(z.string(), z.unknown()) }));
|
|
35
|
-
const CommunityActions = z.union(Object.entries(
|
|
35
|
+
const CommunityActions = z.union(Object.entries(knownActions).map(([name, cfg]) => actionSchema(name, cfg)));
|
|
36
36
|
//#endregion
|
|
37
37
|
export { ActionsLockfile, CommunityActions, Workflow };
|
|
38
38
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema.js","names":[],"sources":["../../../../lib/modules/manager/github-actions/schema.ts"],"sourcesContent":["import { z } from 'zod/v4';\nimport {\n LooseArray,\n LooseRecord,\n Yaml,\n withDebugMessage,\n} from '../../../util/schema-utils/index.ts';\nimport { actionSchema,
|
|
1
|
+
{"version":3,"file":"schema.js","names":[],"sources":["../../../../lib/modules/manager/github-actions/schema.ts"],"sourcesContent":["import { z } from 'zod/v4';\nimport {\n LooseArray,\n LooseRecord,\n Yaml,\n withDebugMessage,\n} from '../../../util/schema-utils/index.ts';\nimport { actionSchema, knownActions } from './known-actions.ts';\nimport type { ActionSchema } from './types.ts';\n\nconst UsesStep = z.object({\n uses: z.string(),\n with: LooseRecord(\n z.union([z.string(), z.number().transform((s) => s.toString())]),\n ),\n});\nexport type UsesStep = z.infer<typeof UsesStep>;\n\n// A `parallel:` group flattens its (recursively resolved) sub-steps into leaf steps.\n// See: https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#example-running-steps-in-parallel\nconst ParallelStep: z.ZodType<UsesStep[]> = z\n .object({ parallel: LooseArray(z.lazy(() => Step)) })\n .transform(({ parallel }) => parallel.flat());\n\n// A step resolves to a flat list of `uses:` steps: a normal step yields itself,\n// a `parallel:` group yields its flattened sub-steps.\nconst Step: z.ZodType<UsesStep[]> = z.union([\n UsesStep.transform((step) => [step]),\n ParallelStep,\n]);\n\n// Flatten the per-element `UsesStep[]` groups into a single `UsesStep[]`.\nconst Steps = LooseArray(Step).transform((groups) => groups.flat());\n\nconst WorkFlowJobs = z.object({\n jobs: LooseRecord(\n z.object({\n container: z\n .union([\n z.string(),\n z.object({ image: z.string() }).transform((v) => v.image),\n ])\n .optional()\n .catch(undefined),\n services: LooseRecord(\n z.union([\n z.object({ image: z.string() }).transform((v) => v.image),\n z.string(),\n ]),\n )\n .catch({})\n .transform((services) => Object.values(services)),\n 'runs-on': z\n .union([z.string().transform((v) => [v]), z.array(z.string())])\n .catch([]),\n steps: Steps.catch([]),\n }),\n ),\n});\n\nconst Actions = z.object({\n runs: z.object({\n using: z.string(),\n steps: Steps.optional().catch([]),\n }),\n});\nexport const Workflow = Yaml.pipe(\n z.union([WorkFlowJobs, Actions, z.null()]),\n).catch(withDebugMessage(null, 'Does not match schema'));\n\n/**\n * The `actions.lock` schema is owned by the `gh actions-lock` CLI, and is still unstable, so don't rely on the structure too heavily.\n *\n * `workflows` is deliberately required: if the tool renames or reshapes it, we want the parse to fail so that we stop touching the lockfile, rather than silently treating every workflow as un-onboarded.\n *\n * TODO #45191: pin to a version of the schema, once it is v1\n */\nexport const ActionsLockfile = Yaml.pipe(\n z.object({\n workflows: z.record(z.string(), z.unknown()),\n }),\n);\nexport type ActionsLockfile = z.infer<typeof ActionsLockfile>;\n\nexport const CommunityActions = z.union(\n Object.entries(knownActions).map(([name, cfg]) =>\n actionSchema(name, cfg),\n ) as [ActionSchema, ActionSchema, ...ActionSchema[]],\n);\n"],"mappings":";;;;AAUA,MAAM,WAAW,EAAE,OAAO;CACxB,MAAM,EAAE,OAAO;CACf,MAAM,YACJ,EAAE,MAAM,CAAC,EAAE,OAAO,GAAG,EAAE,OAAO,CAAC,CAAC,WAAW,MAAM,EAAE,SAAS,CAAC,CAAC,CAAC,CACjE;AACF,CAAC;AAKD,MAAM,eAAsC,EACzC,OAAO,EAAE,UAAU,WAAW,EAAE,WAAW,IAAI,CAAC,EAAE,CAAC,CAAC,CACpD,WAAW,EAAE,eAAe,SAAS,KAAK,CAAC;AAI9C,MAAM,OAA8B,EAAE,MAAM,CAC1C,SAAS,WAAW,SAAS,CAAC,IAAI,CAAC,GACnC,YACF,CAAC;AAGD,MAAM,QAAQ,WAAW,IAAI,CAAC,CAAC,WAAW,WAAW,OAAO,KAAK,CAAC;AAElE,MAAM,eAAe,EAAE,OAAO,EAC5B,MAAM,YACJ,EAAE,OAAO;CACP,WAAW,EACR,MAAM,CACL,EAAE,OAAO,GACT,EAAE,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,CAAC,CAAC,CAAC,WAAW,MAAM,EAAE,KAAK,CAC1D,CAAC,CAAC,CACD,SAAS,CAAC,CACV,MAAM,KAAA,CAAS;CAClB,UAAU,YACR,EAAE,MAAM,CACN,EAAE,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,CAAC,CAAC,CAAC,WAAW,MAAM,EAAE,KAAK,GACxD,EAAE,OAAO,CACX,CAAC,CACH,CAAC,CACE,MAAM,CAAC,CAAC,CAAC,CACT,WAAW,aAAa,OAAO,OAAO,QAAQ,CAAC;CAClD,WAAW,EACR,MAAM,CAAC,EAAE,OAAO,CAAC,CAAC,WAAW,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,CAC9D,MAAM,CAAC,CAAC;CACX,OAAO,MAAM,MAAM,CAAC,CAAC;AACvB,CAAC,CACH,EACF,CAAC;AAED,MAAM,UAAU,EAAE,OAAO,EACvB,MAAM,EAAE,OAAO;CACb,OAAO,EAAE,OAAO;CAChB,OAAO,MAAM,SAAS,CAAC,CAAC,MAAM,CAAC,CAAC;AAClC,CAAC,EACH,CAAC;AACD,MAAa,WAAW,KAAK,KAC3B,EAAE,MAAM;CAAC;CAAc;CAAS,EAAE,KAAK;AAAC,CAAC,CAC3C,CAAC,CAAC,MAAM,iBAAiB,MAAM,uBAAuB,CAAC;;;;;;;;AASvD,MAAa,kBAAkB,KAAK,KAClC,EAAE,OAAO,EACP,WAAW,EAAE,OAAO,EAAE,OAAO,GAAG,EAAE,QAAQ,CAAC,EAC7C,CAAC,CACH;AAGA,MAAa,mBAAmB,EAAE,MAChC,OAAO,QAAQ,YAAY,CAAC,CAAC,KAAK,CAAC,MAAM,SACvC,aAAa,MAAM,GAAG,CACxB,CACF"}
|
|
@@ -4,9 +4,9 @@ import { bitbucket_exports, id as id$2 } from "./bitbucket/index.js";
|
|
|
4
4
|
import { gitlab_exports, id as id$3 } from "./gitlab/index.js";
|
|
5
5
|
import { azure_exports, id as id$4 } from "./azure/index.js";
|
|
6
6
|
import { codecommit_exports, id as id$5 } from "./codecommit/index.js";
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
7
|
+
import { gitea_exports, id as id$6 } from "./gitea/index.js";
|
|
8
|
+
import { forgejo_exports, id as id$7 } from "./forgejo/index.js";
|
|
9
|
+
import { gerrit_exports, id as id$8 } from "./gerrit/index.js";
|
|
10
10
|
import { id as id$9, local_exports } from "./local/index.js";
|
|
11
11
|
import { id as id$10, scm_manager_exports } from "./scm-manager/index.js";
|
|
12
12
|
//#region lib/modules/platform/api.ts
|
|
@@ -15,9 +15,9 @@ api.set(id$4, azure_exports);
|
|
|
15
15
|
api.set(id$2, bitbucket_exports);
|
|
16
16
|
api.set(id$1, bitbucket_server_exports);
|
|
17
17
|
api.set(id$5, codecommit_exports);
|
|
18
|
-
api.set(id$
|
|
19
|
-
api.set(id$
|
|
20
|
-
api.set(id$
|
|
18
|
+
api.set(id$7, forgejo_exports);
|
|
19
|
+
api.set(id$8, gerrit_exports);
|
|
20
|
+
api.set(id$6, gitea_exports);
|
|
21
21
|
api.set(id, github_exports);
|
|
22
22
|
api.set(id$3, gitlab_exports);
|
|
23
23
|
api.set(id$9, local_exports);
|