renovate 40.42.4 → 40.43.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/options/index.js +1 -0
- package/dist/config/options/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/maven/extract.d.ts +1 -1
- package/dist/modules/manager/maven/extract.js +82 -24
- package/dist/modules/manager/maven/extract.js.map +1 -1
- package/dist/modules/manager/maven/index.d.ts +0 -1
- package/dist/modules/manager/maven/index.js +2 -4
- package/dist/modules/manager/maven/index.js.map +1 -1
- package/dist/modules/manager/maven/update.js +15 -0
- package/dist/modules/manager/maven/update.js.map +1 -1
- package/dist/modules/platform/gerrit/client.d.ts +5 -6
- package/dist/modules/platform/gerrit/client.js +51 -36
- package/dist/modules/platform/gerrit/client.js.map +1 -1
- package/dist/modules/platform/gerrit/index.d.ts +4 -3
- package/dist/modules/platform/gerrit/index.js +101 -41
- package/dist/modules/platform/gerrit/index.js.map +1 -1
- package/dist/modules/platform/gerrit/scm.d.ts +1 -1
- package/dist/modules/platform/gerrit/scm.js +56 -34
- package/dist/modules/platform/gerrit/scm.js.map +1 -1
- package/dist/modules/platform/gerrit/types.d.ts +23 -12
- package/dist/modules/platform/gerrit/types.js.map +1 -1
- package/dist/modules/platform/gerrit/utils.d.ts +8 -4
- package/dist/modules/platform/gerrit/utils.js +24 -12
- package/dist/modules/platform/gerrit/utils.js.map +1 -1
- package/package.json +4 -4
- package/renovate-schema.json +1 -2
@@ -17,20 +17,27 @@ function configureScm(repo, login) {
|
|
17
17
|
}
|
18
18
|
class GerritScm extends default_scm_1.DefaultGitScm {
|
19
19
|
async branchExists(branchName) {
|
20
|
-
const searchConfig = {
|
21
|
-
|
22
|
-
|
23
|
-
|
20
|
+
const searchConfig = {
|
21
|
+
state: 'open',
|
22
|
+
branchName,
|
23
|
+
limit: 1,
|
24
|
+
refreshCache: true,
|
25
|
+
};
|
26
|
+
const change = (await client_1.client.findChanges(repository, searchConfig)).pop();
|
24
27
|
if (change) {
|
25
28
|
return true;
|
26
29
|
}
|
27
30
|
return git.branchExists(branchName);
|
28
31
|
}
|
29
32
|
async getBranchCommit(branchName) {
|
30
|
-
const searchConfig = {
|
31
|
-
|
32
|
-
|
33
|
-
|
33
|
+
const searchConfig = {
|
34
|
+
state: 'open',
|
35
|
+
branchName,
|
36
|
+
limit: 1,
|
37
|
+
refreshCache: true,
|
38
|
+
requestDetails: ['CURRENT_REVISION'],
|
39
|
+
};
|
40
|
+
const change = (await client_1.client.findChanges(repository, searchConfig)).pop();
|
34
41
|
if (change) {
|
35
42
|
return change.current_revision;
|
36
43
|
}
|
@@ -41,13 +48,14 @@ class GerritScm extends default_scm_1.DefaultGitScm {
|
|
41
48
|
state: 'open',
|
42
49
|
branchName,
|
43
50
|
targetBranch: baseBranch,
|
51
|
+
limit: 1,
|
52
|
+
refreshCache: true,
|
53
|
+
requestDetails: ['CURRENT_REVISION', 'CURRENT_ACTIONS'],
|
44
54
|
};
|
45
|
-
const change = await client_1.client
|
46
|
-
.findChanges(repository, searchConfig, true)
|
47
|
-
.then((res) => res.pop());
|
55
|
+
const change = (await client_1.client.findChanges(repository, searchConfig)).pop();
|
48
56
|
if (change) {
|
49
|
-
const
|
50
|
-
return
|
57
|
+
const currentRevision = change.revisions[change.current_revision];
|
58
|
+
return currentRevision.actions.rebase.enabled === true;
|
51
59
|
}
|
52
60
|
return true;
|
53
61
|
}
|
@@ -56,6 +64,7 @@ class GerritScm extends default_scm_1.DefaultGitScm {
|
|
56
64
|
state: 'open',
|
57
65
|
branchName: branch,
|
58
66
|
targetBranch: baseBranch,
|
67
|
+
limit: 1,
|
59
68
|
};
|
60
69
|
const change = (await client_1.client.findChanges(repository, searchConfig)).pop();
|
61
70
|
if (change) {
|
@@ -67,14 +76,19 @@ class GerritScm extends default_scm_1.DefaultGitScm {
|
|
67
76
|
return true;
|
68
77
|
}
|
69
78
|
}
|
70
|
-
async isBranchModified(branchName) {
|
71
|
-
const searchConfig = {
|
72
|
-
|
73
|
-
|
74
|
-
|
79
|
+
async isBranchModified(branchName, baseBranch) {
|
80
|
+
const searchConfig = {
|
81
|
+
state: 'open',
|
82
|
+
branchName,
|
83
|
+
targetBranch: baseBranch,
|
84
|
+
limit: 1,
|
85
|
+
refreshCache: true,
|
86
|
+
requestDetails: ['CURRENT_REVISION', 'DETAILED_ACCOUNTS'],
|
87
|
+
};
|
88
|
+
const change = (await client_1.client.findChanges(repository, searchConfig)).pop();
|
75
89
|
if (change) {
|
76
|
-
const
|
77
|
-
return
|
90
|
+
const currentRevision = change.revisions[change.current_revision];
|
91
|
+
return currentRevision.uploader.username !== username;
|
78
92
|
}
|
79
93
|
return false;
|
80
94
|
}
|
@@ -84,10 +98,11 @@ class GerritScm extends default_scm_1.DefaultGitScm {
|
|
84
98
|
state: 'open',
|
85
99
|
branchName: commit.branchName,
|
86
100
|
targetBranch: commit.baseBranch,
|
101
|
+
limit: 1,
|
102
|
+
refreshCache: true,
|
103
|
+
requestDetails: ['CURRENT_REVISION'],
|
87
104
|
};
|
88
|
-
const existingChange = await client_1.client
|
89
|
-
.findChanges(repository, searchConfig, true)
|
90
|
-
.then((res) => res.pop());
|
105
|
+
const existingChange = (await client_1.client.findChanges(repository, searchConfig)).pop();
|
91
106
|
let hasChanges = true;
|
92
107
|
const message = typeof commit.message === 'string' ? [commit.message] : commit.message;
|
93
108
|
// In Gerrit, the change subject/title is the first line of the commit message
|
@@ -96,17 +111,19 @@ class GerritScm extends default_scm_1.DefaultGitScm {
|
|
96
111
|
firstMessageLines[0] = commit.prTitle;
|
97
112
|
message[0] = firstMessageLines.join('\n');
|
98
113
|
}
|
114
|
+
const changeId = existingChange?.change_id ?? generateChangeId();
|
99
115
|
commit.message = [
|
100
116
|
...message,
|
101
|
-
`Renovate-Branch: ${commit.branchName}\nChange-Id: ${
|
117
|
+
`Renovate-Branch: ${commit.branchName}\nChange-Id: ${changeId}`,
|
102
118
|
];
|
103
119
|
const commitResult = await git.prepareCommit({ ...commit, force: true });
|
104
120
|
if (commitResult) {
|
105
121
|
const { commitSha } = commitResult;
|
106
|
-
if (existingChange
|
107
|
-
const
|
108
|
-
|
109
|
-
|
122
|
+
if (existingChange) {
|
123
|
+
const currentRevision = existingChange.revisions[existingChange.current_revision];
|
124
|
+
const fetchRefSpec = currentRevision.ref;
|
125
|
+
await git.fetchRevSpec(fetchRefSpec); // fetch current ChangeSet for git diff
|
126
|
+
hasChanges = await git.hasDiff('HEAD', 'FETCH_HEAD'); // avoid pushing empty patch sets
|
110
127
|
}
|
111
128
|
if (hasChanges || commit.force) {
|
112
129
|
const pushOptions = ['notify=NONE'];
|
@@ -123,18 +140,23 @@ class GerritScm extends default_scm_1.DefaultGitScm {
|
|
123
140
|
}
|
124
141
|
}
|
125
142
|
}
|
126
|
-
return null; //empty commit, no changes in this Gerrit
|
143
|
+
return null; // empty commit, no changes in this Gerrit Change
|
127
144
|
}
|
128
145
|
deleteBranch(branchName) {
|
129
146
|
return Promise.resolve();
|
130
147
|
}
|
131
148
|
async mergeToLocal(branchName) {
|
132
|
-
const searchConfig = {
|
133
|
-
|
134
|
-
|
135
|
-
|
149
|
+
const searchConfig = {
|
150
|
+
state: 'open',
|
151
|
+
branchName,
|
152
|
+
limit: 1,
|
153
|
+
refreshCache: true,
|
154
|
+
requestDetails: ['CURRENT_REVISION'],
|
155
|
+
};
|
156
|
+
const change = (await client_1.client.findChanges(repository, searchConfig)).pop();
|
136
157
|
if (change) {
|
137
|
-
|
158
|
+
const currentRevision = change.revisions[change.current_revision];
|
159
|
+
return super.mergeToLocal(currentRevision.ref);
|
138
160
|
}
|
139
161
|
return super.mergeToLocal(branchName);
|
140
162
|
}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"scm.js","sourceRoot":"","sources":["../../../../lib/modules/platform/gerrit/scm.ts"],"names":[],"mappings":";;;AAWA,oCAGC;;AAdD,mCAAoC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AAC,CAAC,gDAAgD;IAC/D,CAAC;IAEQ,YAAY,CAAC,UAAkB;QACtC,OAAO,OAAO,CAAC,OAAO,EAAE,CAAC;IAC3B,CAAC;IAEQ,KAAK,CAAC,YAAY,CAAC,UAAkB;QAC5C,MAAM,YAAY,GAAuB,EAAE,KAAK,EAAE,MAAM,EAAE,UAAU,EAAE,CAAC;QACvE,MAAM,MAAM,GAAG,MAAM,eAAM;aACxB,WAAW,CAAC,UAAU,EAAE,YAAY,EAAE,IAAI,CAAC;aAC3C,IAAI,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,GAAG,EAAE,CAAC,CAAC;QAC5B,IAAI,MAAM,EAAE,CAAC;YACX,OAAO,KAAK,CAAC,YAAY,CAAC,MAAM,CAAC,SAAS,CAAC,MAAM,CAAC,gBAAgB,CAAC,CAAC,GAAG,CAAC,CAAC;QAC3E,CAAC;QACD,OAAO,KAAK,CAAC,YAAY,CAAC,UAAU,CAAC,CAAC;IACxC,CAAC;CACF;AAnJD,8BAmJC;AAED;;;;GAIG;AACH,SAAS,gBAAgB;IACvB,OAAO,GAAG,GAAG,IAAA,WAAI,EAAC,IAAA,mBAAU,GAAE,EAAE,MAAM,CAAC,CAAC;AAC1C,CAAC","sourcesContent":["import { randomUUID } from 'crypto';\nimport { logger } from '../../../logger';\nimport * as git from '../../../util/git';\nimport type { CommitFilesConfig, LongCommitSha } from '../../../util/git/types';\nimport { hash } from '../../../util/hash';\nimport { DefaultGitScm } from '../default-scm';\nimport { client } from './client';\nimport type { GerritFindPRConfig } from './types';\n\nlet repository: string;\nlet username: string;\nexport function configureScm(repo: string, login: string): void {\n repository = repo;\n username = login;\n}\n\nexport class GerritScm extends DefaultGitScm {\n override async branchExists(branchName: string): Promise<boolean> {\n const searchConfig: GerritFindPRConfig = { state: 'open', branchName };\n const change = await client\n .findChanges(repository, searchConfig, true)\n .then((res) => res.pop());\n if (change) {\n return true;\n }\n return git.branchExists(branchName);\n }\n\n override async getBranchCommit(\n branchName: string,\n ): Promise<LongCommitSha | null> {\n const searchConfig: GerritFindPRConfig = { state: 'open', branchName };\n const change = await client\n .findChanges(repository, searchConfig, true)\n .then((res) => res.pop());\n if (change) {\n return change.current_revision as LongCommitSha;\n }\n return git.getBranchCommit(branchName);\n }\n\n override async isBranchBehindBase(\n branchName: string,\n baseBranch: string,\n ): Promise<boolean> {\n const searchConfig: GerritFindPRConfig = {\n state: 'open',\n branchName,\n targetBranch: baseBranch,\n };\n const change = await client\n .findChanges(repository, searchConfig, true)\n .then((res) => res.pop());\n if (change) {\n const currentGerritPatchset = change.revisions[change.current_revision];\n return currentGerritPatchset.actions?.rebase.enabled === true;\n }\n return true;\n }\n\n override async isBranchConflicted(\n baseBranch: string,\n branch: string,\n ): Promise<boolean> {\n const searchConfig: GerritFindPRConfig = {\n state: 'open',\n branchName: branch,\n targetBranch: baseBranch,\n };\n const change = (await client.findChanges(repository, searchConfig)).pop();\n if (change) {\n const mergeInfo = await client.getMergeableInfo(change);\n return !mergeInfo.mergeable;\n } else {\n logger.warn(\n { branch, baseBranch },\n 'There is no open change with this branch',\n );\n return true;\n }\n }\n\n override async isBranchModified(branchName: string): Promise<boolean> {\n const searchConfig: GerritFindPRConfig = { state: 'open', branchName };\n const change = await client\n .findChanges(repository, searchConfig, true)\n .then((res) => res.pop());\n if (change) {\n const currentGerritPatchset = change.revisions[change.current_revision];\n return currentGerritPatchset.uploader.username !== username;\n }\n return false;\n }\n\n override async commitAndPush(\n commit: CommitFilesConfig,\n ): Promise<LongCommitSha | null> {\n logger.debug(`commitAndPush(${commit.branchName})`);\n const searchConfig: GerritFindPRConfig = {\n state: 'open',\n branchName: commit.branchName,\n targetBranch: commit.baseBranch,\n };\n const existingChange = await client\n .findChanges(repository, searchConfig, true)\n .then((res) => res.pop());\n\n let hasChanges = true;\n const message =\n typeof commit.message === 'string' ? [commit.message] : commit.message;\n\n // In Gerrit, the change subject/title is the first line of the commit message\n if (commit.prTitle) {\n const firstMessageLines = message[0].split('\\n');\n firstMessageLines[0] = commit.prTitle;\n message[0] = firstMessageLines.join('\\n');\n }\n\n commit.message = [\n ...message,\n `Renovate-Branch: ${commit.branchName}\\nChange-Id: ${existingChange?.change_id ?? generateChangeId()}`,\n ];\n const commitResult = await git.prepareCommit({ ...commit, force: true });\n if (commitResult) {\n const { commitSha } = commitResult;\n if (existingChange?.revisions && existingChange.current_revision) {\n const fetchRefSpec =\n existingChange.revisions[existingChange.current_revision].ref;\n await git.fetchRevSpec(fetchRefSpec); //fetch current ChangeSet for git diff\n hasChanges = await git.hasDiff('HEAD', 'FETCH_HEAD'); //avoid empty patchsets\n }\n if (hasChanges || commit.force) {\n const pushOptions = ['notify=NONE'];\n if (commit.autoApprove) {\n pushOptions.push('label=Code-Review+2');\n }\n const pushResult = await git.pushCommit({\n sourceRef: commit.branchName,\n targetRef: `refs/for/${commit.baseBranch!}%${pushOptions.join(',')}`,\n files: commit.files,\n });\n if (pushResult) {\n return commitSha;\n }\n }\n }\n return null; //empty commit, no changes in this Gerrit-Change\n }\n\n override deleteBranch(branchName: string): Promise<void> {\n return Promise.resolve();\n }\n\n override async mergeToLocal(branchName: string): Promise<void> {\n const searchConfig: GerritFindPRConfig = { state: 'open', branchName };\n const change = await client\n .findChanges(repository, searchConfig, true)\n .then((res) => res.pop());\n if (change) {\n return super.mergeToLocal(change.revisions[change.current_revision].ref);\n }\n return super.mergeToLocal(branchName);\n }\n}\n\n/**\n * This function should generate a Gerrit Change-ID analogous to the commit hook. We avoid the commit hook cause of security concerns.\n * random=$( (whoami ; hostname ; date; cat $1 ; echo $RANDOM) | git hash-object --stdin) prefixed with an 'I'.\n * TODO: Gerrit don't accept longer Change-IDs (sha256), but what happens with this https://git-scm.com/docs/hash-function-transition/ ?\n */\nfunction generateChangeId(): string {\n return 'I' + hash(randomUUID(), 'sha1');\n}\n"]}
|
1
|
+
{"version":3,"file":"scm.js","sourceRoot":"","sources":["../../../../lib/modules/platform/gerrit/scm.ts"],"names":[],"mappings":";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C,UAAW,IAAI,WAAW,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE;oBACpE,KAAK,EAAE,MAAM,CAAC,KAAK;iBACpB,CAAC,CAAC;gBACH,IAAI,UAAU,EAAE,CAAC;oBACf,OAAO,SAAS,CAAC;gBACnB,CAAC;YACH,CAAC;QACH,CAAC;QACD,OAAO,IAAI,CAAC,CAAC,iDAAiD;IAChE,CAAC;IAEQ,YAAY,CAAC,UAAkB;QACtC,OAAO,OAAO,CAAC,OAAO,EAAE,CAAC;IAC3B,CAAC;IAEQ,KAAK,CAAC,YAAY,CAAC,UAAkB;QAC5C,MAAM,YAAY,GAAuB;YACvC,KAAK,EAAE,MAAM;YACb,UAAU;YACV,KAAK,EAAE,CAAC;YACR,YAAY,EAAE,IAAI;YAClB,cAAc,EAAE,CAAC,kBAAkB,CAAC;SACrC,CAAC;QACF,MAAM,MAAM,GAAG,CAAC,MAAM,eAAM,CAAC,WAAW,CAAC,UAAU,EAAE,YAAY,CAAC,CAAC,CAAC,GAAG,EAAE,CAAC;QAC1E,IAAI,MAAM,EAAE,CAAC;YACX,MAAM,eAAe,GAAG,MAAM,CAAC,SAAU,CAAC,MAAM,CAAC,gBAAiB,CAAC,CAAC;YACpE,OAAO,KAAK,CAAC,YAAY,CAAC,eAAe,CAAC,GAAG,CAAC,CAAC;QACjD,CAAC;QACD,OAAO,KAAK,CAAC,YAAY,CAAC,UAAU,CAAC,CAAC;IACxC,CAAC;CACF;AA9KD,8BA8KC;AAED;;;;GAIG;AACH,SAAS,gBAAgB;IACvB,OAAO,GAAG,GAAG,IAAA,WAAI,EAAC,IAAA,mBAAU,GAAE,EAAE,MAAM,CAAC,CAAC;AAC1C,CAAC","sourcesContent":["import { randomUUID } from 'crypto';\nimport { logger } from '../../../logger';\nimport * as git from '../../../util/git';\nimport type { CommitFilesConfig, LongCommitSha } from '../../../util/git/types';\nimport { hash } from '../../../util/hash';\nimport { DefaultGitScm } from '../default-scm';\nimport { client } from './client';\nimport type { GerritFindPRConfig } from './types';\n\nlet repository: string;\nlet username: string;\nexport function configureScm(repo: string, login: string): void {\n repository = repo;\n username = login;\n}\n\nexport class GerritScm extends DefaultGitScm {\n override async branchExists(branchName: string): Promise<boolean> {\n const searchConfig: GerritFindPRConfig = {\n state: 'open',\n branchName,\n limit: 1,\n refreshCache: true,\n };\n const change = (await client.findChanges(repository, searchConfig)).pop();\n if (change) {\n return true;\n }\n return git.branchExists(branchName);\n }\n\n override async getBranchCommit(\n branchName: string,\n ): Promise<LongCommitSha | null> {\n const searchConfig: GerritFindPRConfig = {\n state: 'open',\n branchName,\n limit: 1,\n refreshCache: true,\n requestDetails: ['CURRENT_REVISION'],\n };\n const change = (await client.findChanges(repository, searchConfig)).pop();\n if (change) {\n return change.current_revision as LongCommitSha;\n }\n return git.getBranchCommit(branchName);\n }\n\n override async isBranchBehindBase(\n branchName: string,\n baseBranch: string,\n ): Promise<boolean> {\n const searchConfig: GerritFindPRConfig = {\n state: 'open',\n branchName,\n targetBranch: baseBranch,\n limit: 1,\n refreshCache: true,\n requestDetails: ['CURRENT_REVISION', 'CURRENT_ACTIONS'],\n };\n const change = (await client.findChanges(repository, searchConfig)).pop();\n if (change) {\n const currentRevision = change.revisions![change.current_revision!];\n return currentRevision.actions!.rebase.enabled === true;\n }\n return true;\n }\n\n override async isBranchConflicted(\n baseBranch: string,\n branch: string,\n ): Promise<boolean> {\n const searchConfig: GerritFindPRConfig = {\n state: 'open',\n branchName: branch,\n targetBranch: baseBranch,\n limit: 1,\n };\n const change = (await client.findChanges(repository, searchConfig)).pop();\n if (change) {\n const mergeInfo = await client.getMergeableInfo(change);\n return !mergeInfo.mergeable;\n } else {\n logger.warn(\n { branch, baseBranch },\n 'There is no open change with this branch',\n );\n return true;\n }\n }\n\n override async isBranchModified(\n branchName: string,\n baseBranch: string,\n ): Promise<boolean> {\n const searchConfig: GerritFindPRConfig = {\n state: 'open',\n branchName,\n targetBranch: baseBranch,\n limit: 1,\n refreshCache: true,\n requestDetails: ['CURRENT_REVISION', 'DETAILED_ACCOUNTS'],\n };\n const change = (await client.findChanges(repository, searchConfig)).pop();\n if (change) {\n const currentRevision = change.revisions![change.current_revision!];\n return currentRevision.uploader.username !== username;\n }\n return false;\n }\n\n override async commitAndPush(\n commit: CommitFilesConfig,\n ): Promise<LongCommitSha | null> {\n logger.debug(`commitAndPush(${commit.branchName})`);\n const searchConfig: GerritFindPRConfig = {\n state: 'open',\n branchName: commit.branchName,\n targetBranch: commit.baseBranch,\n limit: 1,\n refreshCache: true,\n requestDetails: ['CURRENT_REVISION'],\n };\n const existingChange = (\n await client.findChanges(repository, searchConfig)\n ).pop();\n\n let hasChanges = true;\n const message =\n typeof commit.message === 'string' ? [commit.message] : commit.message;\n\n // In Gerrit, the change subject/title is the first line of the commit message\n if (commit.prTitle) {\n const firstMessageLines = message[0].split('\\n');\n firstMessageLines[0] = commit.prTitle;\n message[0] = firstMessageLines.join('\\n');\n }\n\n const changeId = existingChange?.change_id ?? generateChangeId();\n commit.message = [\n ...message,\n `Renovate-Branch: ${commit.branchName}\\nChange-Id: ${changeId}`,\n ];\n const commitResult = await git.prepareCommit({ ...commit, force: true });\n if (commitResult) {\n const { commitSha } = commitResult;\n if (existingChange) {\n const currentRevision =\n existingChange.revisions![existingChange.current_revision!];\n const fetchRefSpec = currentRevision.ref;\n await git.fetchRevSpec(fetchRefSpec); // fetch current ChangeSet for git diff\n hasChanges = await git.hasDiff('HEAD', 'FETCH_HEAD'); // avoid pushing empty patch sets\n }\n if (hasChanges || commit.force) {\n const pushOptions = ['notify=NONE'];\n if (commit.autoApprove) {\n pushOptions.push('label=Code-Review+2');\n }\n const pushResult = await git.pushCommit({\n sourceRef: commit.branchName,\n targetRef: `refs/for/${commit.baseBranch!}%${pushOptions.join(',')}`,\n files: commit.files,\n });\n if (pushResult) {\n return commitSha;\n }\n }\n }\n return null; // empty commit, no changes in this Gerrit Change\n }\n\n override deleteBranch(branchName: string): Promise<void> {\n return Promise.resolve();\n }\n\n override async mergeToLocal(branchName: string): Promise<void> {\n const searchConfig: GerritFindPRConfig = {\n state: 'open',\n branchName,\n limit: 1,\n refreshCache: true,\n requestDetails: ['CURRENT_REVISION'],\n };\n const change = (await client.findChanges(repository, searchConfig)).pop();\n if (change) {\n const currentRevision = change.revisions![change.current_revision!];\n return super.mergeToLocal(currentRevision.ref);\n }\n return super.mergeToLocal(branchName);\n }\n}\n\n/**\n * This function should generate a Gerrit Change-ID analogous to the commit hook. We avoid the commit hook cause of security concerns.\n * random=$( (whoami ; hostname ; date; cat $1 ; echo $RANDOM) | git hash-object --stdin) prefixed with an 'I'.\n * TODO: Gerrit don't accept longer Change-IDs (sha256), but what happens with this https://git-scm.com/docs/hash-function-transition/ ?\n */\nfunction generateChangeId(): string {\n return 'I' + hash(randomUUID(), 'sha1');\n}\n"]}
|
@@ -1,6 +1,8 @@
|
|
1
1
|
import type { FindPRConfig } from '../types';
|
2
2
|
export interface GerritFindPRConfig extends FindPRConfig {
|
3
3
|
label?: string;
|
4
|
+
limit?: number;
|
5
|
+
requestDetails?: GerritRequestDetail[];
|
4
6
|
}
|
5
7
|
/**
|
6
8
|
* The Interfaces for the Gerrit API Responses ({@link https://gerrit-review.googlesource.com/Documentation/rest-api.html | REST-API})
|
@@ -23,36 +25,44 @@ export interface GerritBranchInfo {
|
|
23
25
|
revision: string;
|
24
26
|
}
|
25
27
|
export type GerritChangeStatus = 'NEW' | 'MERGED' | 'ABANDONED';
|
26
|
-
export type
|
28
|
+
export type GerritRequestDetail = 'SUBMITTABLE' | 'CHECK' | 'MESSAGES' | 'DETAILED_ACCOUNTS' | 'LABELS' | 'CURRENT_ACTIONS' | 'CURRENT_REVISION' | 'COMMIT_FOOTERS';
|
27
29
|
export interface GerritChange {
|
28
30
|
branch: string;
|
29
31
|
change_id: string;
|
30
32
|
subject: string;
|
31
33
|
status: GerritChangeStatus;
|
32
34
|
created: string;
|
35
|
+
/** Requires o=SUBMITTABLE. */
|
33
36
|
submittable?: boolean;
|
34
37
|
_number: number;
|
38
|
+
/** Requires o=LABELS. */
|
35
39
|
labels?: Record<string, GerritLabelInfo>;
|
36
|
-
|
40
|
+
/** Requires o=LABELS. */
|
41
|
+
reviewers?: {
|
42
|
+
REVIEWER?: GerritAccountInfo[];
|
43
|
+
};
|
44
|
+
/** Requires o=MESSAGES. */
|
37
45
|
messages?: GerritChangeMessageInfo[];
|
38
|
-
|
46
|
+
/** Requires o=CURRENT_REVISION. */
|
47
|
+
current_revision?: string;
|
39
48
|
/**
|
40
49
|
* All patch sets of this change as a map that maps the commit ID of the patch set to a RevisionInfo entity.
|
50
|
+
* Requires o=CURRENT_REVISION.
|
41
51
|
*/
|
42
|
-
revisions
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
52
|
+
revisions?: Record<string, GerritRevisionInfo>;
|
53
|
+
/**
|
54
|
+
* Potential consistency issues with the change (not related to labels).
|
55
|
+
* Requires o=CHECKS. */
|
56
|
+
problems?: unknown[];
|
47
57
|
}
|
48
58
|
export interface GerritRevisionInfo {
|
49
59
|
uploader: GerritAccountInfo;
|
50
|
-
/**
|
51
|
-
* The Git reference for the patch set.
|
52
|
-
*/
|
60
|
+
/** The Git reference for the patch set. */
|
53
61
|
ref: string;
|
62
|
+
/** Requires o=CURRENT_ACTIONS. */
|
54
63
|
actions?: Record<string, GerritActionInfo>;
|
55
|
-
|
64
|
+
/** Requires o=COMMIT_FOOTERS. */
|
65
|
+
commit_with_footers?: string;
|
56
66
|
}
|
57
67
|
export interface GerritChangeMessageInfo {
|
58
68
|
id: string;
|
@@ -71,6 +81,7 @@ export interface GerritActionInfo {
|
|
71
81
|
}
|
72
82
|
export interface GerritAccountInfo {
|
73
83
|
_account_id: number;
|
84
|
+
/** Requires o=DETAILED_ACCOUNTS. */
|
74
85
|
username?: string;
|
75
86
|
}
|
76
87
|
export interface GerritMergeableInfo {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../lib/modules/platform/gerrit/types.ts"],"names":[],"mappings":"","sourcesContent":["import type { FindPRConfig } from '../types';\n\nexport interface GerritFindPRConfig extends FindPRConfig {\n label?: string;\n}\n\n/**\n * The Interfaces for the Gerrit API Responses ({@link https://gerrit-review.googlesource.com/Documentation/rest-api.html | REST-API})\n * minimized to only needed properties.\n *\n * @packageDocumentation\n */\n\nexport interface GerritProjectInfo {\n id: string;\n name: string;\n state?: 'ACTIVE' | 'READ_ONLY' | 'HIDDEN';\n labels?: Record<string, GerritLabelTypeInfo>;\n}\n\nexport interface GerritLabelTypeInfo {\n values: Record<number, string>;\n default_value: number;\n}\n\nexport interface GerritBranchInfo {\n ref: string;\n revision: string;\n}\n\nexport type GerritChangeStatus = 'NEW' | 'MERGED' | 'ABANDONED';\n\nexport type
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../lib/modules/platform/gerrit/types.ts"],"names":[],"mappings":"","sourcesContent":["import type { FindPRConfig } from '../types';\n\nexport interface GerritFindPRConfig extends FindPRConfig {\n label?: string;\n limit?: number;\n requestDetails?: GerritRequestDetail[];\n}\n\n/**\n * The Interfaces for the Gerrit API Responses ({@link https://gerrit-review.googlesource.com/Documentation/rest-api.html | REST-API})\n * minimized to only needed properties.\n *\n * @packageDocumentation\n */\n\nexport interface GerritProjectInfo {\n id: string;\n name: string;\n state?: 'ACTIVE' | 'READ_ONLY' | 'HIDDEN';\n labels?: Record<string, GerritLabelTypeInfo>;\n}\n\nexport interface GerritLabelTypeInfo {\n values: Record<number, string>;\n default_value: number;\n}\n\nexport interface GerritBranchInfo {\n ref: string;\n revision: string;\n}\n\nexport type GerritChangeStatus = 'NEW' | 'MERGED' | 'ABANDONED';\n\nexport type GerritRequestDetail =\n | 'SUBMITTABLE'\n | 'CHECK'\n | 'MESSAGES'\n | 'DETAILED_ACCOUNTS'\n | 'LABELS'\n | 'CURRENT_ACTIONS'\n | 'CURRENT_REVISION'\n | 'COMMIT_FOOTERS';\n\nexport interface GerritChange {\n branch: string;\n change_id: string;\n subject: string;\n status: GerritChangeStatus;\n created: string;\n /** Requires o=SUBMITTABLE. */\n submittable?: boolean;\n _number: number;\n /** Requires o=LABELS. */\n labels?: Record<string, GerritLabelInfo>;\n /** Requires o=LABELS. */\n reviewers?: {\n REVIEWER?: GerritAccountInfo[];\n };\n /** Requires o=MESSAGES. */\n messages?: GerritChangeMessageInfo[];\n /** Requires o=CURRENT_REVISION. */\n current_revision?: string;\n /**\n * All patch sets of this change as a map that maps the commit ID of the patch set to a RevisionInfo entity.\n * Requires o=CURRENT_REVISION.\n */\n revisions?: Record<string, GerritRevisionInfo>;\n /**\n * Potential consistency issues with the change (not related to labels).\n * Requires o=CHECKS. */\n problems?: unknown[];\n}\n\nexport interface GerritRevisionInfo {\n uploader: GerritAccountInfo;\n /** The Git reference for the patch set. */\n ref: string;\n /** Requires o=CURRENT_ACTIONS. */\n actions?: Record<string, GerritActionInfo>;\n /** Requires o=COMMIT_FOOTERS. */\n commit_with_footers?: string;\n}\n\nexport interface GerritChangeMessageInfo {\n id: string;\n message: string;\n tag?: string;\n}\n\nexport interface GerritLabelInfo {\n approved?: GerritAccountInfo;\n rejected?: GerritAccountInfo;\n /** If true, the label blocks submit operation. If not set, the default is false. */\n blocking?: boolean;\n}\n\nexport interface GerritActionInfo {\n method?: string;\n enabled?: boolean;\n}\n\nexport interface GerritAccountInfo {\n _account_id: number;\n /** Requires o=DETAILED_ACCOUNTS. */\n username?: string;\n}\n\nexport interface GerritMergeableInfo {\n submit_type:\n | 'MERGE_IF_NECESSARY'\n | 'FAST_FORWARD_ONLY'\n | 'REBASE_IF_NECESSARY'\n | 'REBASE_ALWAYS'\n | 'MERGE_ALWAYS'\n | 'CHERRY_PICK';\n mergeable: boolean;\n}\n"]}
|
@@ -1,11 +1,15 @@
|
|
1
1
|
import type { BranchStatus, PrState } from '../../../types';
|
2
2
|
import type { Pr } from '../types';
|
3
|
-
import type { GerritChange, GerritChangeStatus, GerritLabelTypeInfo } from './types';
|
3
|
+
import type { GerritChange, GerritChangeStatus, GerritLabelTypeInfo, GerritRequestDetail } from './types';
|
4
4
|
export declare const TAG_PULL_REQUEST_BODY = "pull-request";
|
5
|
+
export declare const REQUEST_DETAILS_FOR_PRS: GerritRequestDetail[];
|
5
6
|
export declare function getGerritRepoUrl(repository: string, endpoint: string): string;
|
6
|
-
export declare function mapPrStateToGerritFilter(state?: PrState): string;
|
7
|
-
export declare function mapGerritChangeToPr(change: GerritChange
|
8
|
-
|
7
|
+
export declare function mapPrStateToGerritFilter(state?: PrState): string | null;
|
8
|
+
export declare function mapGerritChangeToPr(change: GerritChange, knownProperties?: {
|
9
|
+
sourceBranch?: string;
|
10
|
+
prBody?: string;
|
11
|
+
}): Pr | null;
|
12
|
+
export declare function mapGerritChangeStateToPrState(state: GerritChangeStatus): 'merged' | 'open' | 'closed';
|
9
13
|
export declare function extractSourceBranch(change: GerritChange): string | undefined;
|
10
14
|
export declare function findPullRequestBody(change: GerritChange): string | undefined;
|
11
15
|
export declare function mapBranchStatusToLabel(state: BranchStatus | 'UNKNOWN', // suppress default path code removal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.TAG_PULL_REQUEST_BODY = void 0;
|
3
|
+
exports.REQUEST_DETAILS_FOR_PRS = exports.TAG_PULL_REQUEST_BODY = void 0;
|
4
4
|
exports.getGerritRepoUrl = getGerritRepoUrl;
|
5
5
|
exports.mapPrStateToGerritFilter = mapPrStateToGerritFilter;
|
6
6
|
exports.mapGerritChangeToPr = mapGerritChangeToPr;
|
@@ -16,6 +16,13 @@ const regex_1 = require("../../../util/regex");
|
|
16
16
|
const url_1 = require("../../../util/url");
|
17
17
|
const pr_body_1 = require("../pr-body");
|
18
18
|
exports.TAG_PULL_REQUEST_BODY = 'pull-request';
|
19
|
+
exports.REQUEST_DETAILS_FOR_PRS = [
|
20
|
+
'MESSAGES', // to get the pr body
|
21
|
+
'LABELS', // to get the reviewers
|
22
|
+
'DETAILED_ACCOUNTS', // to get the reviewers usernames
|
23
|
+
'CURRENT_REVISION', // to get the commit message
|
24
|
+
'COMMIT_FOOTERS', // to get the commit message
|
25
|
+
];
|
19
26
|
function getGerritRepoUrl(repository, endpoint) {
|
20
27
|
// Find options for current host and determine Git endpoint
|
21
28
|
const opts = hostRules.find({
|
@@ -37,31 +44,36 @@ function getGerritRepoUrl(repository, endpoint) {
|
|
37
44
|
}
|
38
45
|
function mapPrStateToGerritFilter(state) {
|
39
46
|
switch (state) {
|
40
|
-
case 'closed':
|
41
|
-
return 'status:closed';
|
42
47
|
case 'merged':
|
43
48
|
return 'status:merged';
|
44
|
-
case '!open':
|
45
|
-
return '-status:open';
|
46
49
|
case 'open':
|
47
50
|
return 'status:open';
|
51
|
+
case 'closed':
|
52
|
+
return 'status:abandoned';
|
53
|
+
case '!open':
|
54
|
+
return '-status:open';
|
48
55
|
case 'all':
|
49
56
|
default:
|
50
|
-
return
|
57
|
+
return null;
|
51
58
|
}
|
52
59
|
}
|
53
|
-
function mapGerritChangeToPr(change) {
|
60
|
+
function mapGerritChangeToPr(change, knownProperties) {
|
61
|
+
const sourceBranch = knownProperties?.sourceBranch ?? extractSourceBranch(change);
|
62
|
+
if (!sourceBranch) {
|
63
|
+
return null;
|
64
|
+
}
|
54
65
|
return {
|
55
66
|
number: change._number,
|
56
67
|
state: mapGerritChangeStateToPrState(change.status),
|
57
|
-
sourceBranch
|
68
|
+
sourceBranch,
|
58
69
|
targetBranch: change.branch,
|
59
70
|
title: change.subject,
|
60
71
|
createdAt: change.created?.replace(' ', 'T'),
|
61
|
-
reviewers: change.reviewers?.REVIEWER?.
|
72
|
+
reviewers: change.reviewers?.REVIEWER?.map((reviewer) => reviewer.username) ?? [],
|
62
73
|
bodyStruct: {
|
63
|
-
hash: (0, pr_body_1.hashBody)(findPullRequestBody(change)),
|
74
|
+
hash: (0, pr_body_1.hashBody)(knownProperties?.prBody ?? findPullRequestBody(change)),
|
64
75
|
},
|
76
|
+
sha: change.current_revision,
|
65
77
|
};
|
66
78
|
}
|
67
79
|
function mapGerritChangeStateToPrState(state) {
|
@@ -73,13 +85,13 @@ function mapGerritChangeStateToPrState(state) {
|
|
73
85
|
case 'ABANDONED':
|
74
86
|
return 'closed';
|
75
87
|
}
|
76
|
-
return 'all';
|
77
88
|
}
|
78
89
|
function extractSourceBranch(change) {
|
79
90
|
let sourceBranch = undefined;
|
80
91
|
if (change.current_revision) {
|
81
92
|
const re = (0, regex_1.regEx)(/^Renovate-Branch: (.+)$/m);
|
82
|
-
const
|
93
|
+
const currentRevision = change.revisions[change.current_revision];
|
94
|
+
const message = currentRevision.commit_with_footers;
|
83
95
|
if (message) {
|
84
96
|
sourceBranch = re.exec(message)?.[1];
|
85
97
|
}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../../../../lib/modules/platform/gerrit/utils.ts"],"names":[],"mappings":";;;
|
1
|
+
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../../../../lib/modules/platform/gerrit/utils.ts"],"names":[],"mappings":";;;AA0BA,4CA4BC;AAED,4DAcC;AAED,kDA0BC;AAED,sEAWC;AAED,kDAaC;AAED,kDAQC;AAED,wDAcC;;AAxJD,sEAA+E;AAC/E,4CAAyC;AAGzC,4EAAsD;AACtD,+CAA4C;AAC5C,2CAA2D;AAC3D,wCAAsC;AASzB,QAAA,qBAAqB,GAAG,cAAc,CAAC;AAEvC,QAAA,uBAAuB,GAA0B;IAC5D,UAAU,EAAE,qBAAqB;IACjC,QAAQ,EAAE,uBAAuB;IACjC,mBAAmB,EAAE,iCAAiC;IACtD,kBAAkB,EAAE,4BAA4B;IAChD,gBAAgB,EAAE,4BAA4B;CACtC,CAAC;AAEX,SAAgB,gBAAgB,CAAC,UAAkB,EAAE,QAAgB;IACnE,2DAA2D;IAC3D,MAAM,IAAI,GAAG,SAAS,CAAC,IAAI,CAAC;QAC1B,QAAQ,EAAE,QAAQ;QAClB,GAAG,EAAE,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vC,CAAC;IACH,CAAC;IAED,OAAO,YAAY,IAAI,SAAS,CAAC;AACnC,CAAC;AAED,SAAgB,mBAAmB,CAAC,MAAoB;IACtD,MAAM,GAAG,GAAG,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,QAAQ,IAAI,EAAE,CAAC;SAC1C,OAAO,EAAE;SACT,IAAI,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,GAAG,KAAK,6BAAqB,CAAC,CAAC;IACpD,IAAI,GAAG,EAAE,CAAC;QACR,OAAO,GAAG,CAAC,OAAO,CAAC,OAAO,CAAC,qBAAqB,EAAE,EAAE,CAAC,CAAC,CAAC,sDAAsD;IAC/G,CAAC;IACD,OAAO,SAAS,CAAC;AACnB,CAAC;AAED,SAAgB,sBAAsB,CACpC,KAA+B,EAAE,qCAAqC;AACtE,KAA0B;IAE1B,MAAM,OAAO,GAAG,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,QAAQ,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC;IACtE,QAAQ,KAAK,EAAE,CAAC;QACd,KAAK,OAAO;YACV,OAAO,IAAI,CAAC,GAAG,CAAC,GAAG,OAAO,CAAC,CAAC;QAC9B,KAAK,QAAQ,CAAC;QACd,KAAK,KAAK;YACR,OAAO,IAAI,CAAC,GAAG,CAAC,GAAG,OAAO,CAAC,CAAC;IAChC,CAAC;IACD,oBAAoB;IACpB,OAAO,KAAK,CAAC,aAAa,CAAC;AAC7B,CAAC","sourcesContent":["import { CONFIG_GIT_URL_UNAVAILABLE } from '../../../constants/error-messages';\nimport { logger } from '../../../logger';\nimport type { BranchStatus, PrState } from '../../../types';\nimport type { LongCommitSha } from '../../../util/git/types';\nimport * as hostRules from '../../../util/host-rules';\nimport { regEx } from '../../../util/regex';\nimport { joinUrlParts, parseUrl } from '../../../util/url';\nimport { hashBody } from '../pr-body';\nimport type { Pr } from '../types';\nimport type {\n GerritChange,\n GerritChangeStatus,\n GerritLabelTypeInfo,\n GerritRequestDetail,\n} from './types';\n\nexport const TAG_PULL_REQUEST_BODY = 'pull-request';\n\nexport const REQUEST_DETAILS_FOR_PRS: GerritRequestDetail[] = [\n 'MESSAGES', // to get the pr body\n 'LABELS', // to get the reviewers\n 'DETAILED_ACCOUNTS', // to get the reviewers usernames\n 'CURRENT_REVISION', // to get the commit message\n 'COMMIT_FOOTERS', // to get the commit message\n] as const;\n\nexport function getGerritRepoUrl(repository: string, endpoint: string): string {\n // Find options for current host and determine Git endpoint\n const opts = hostRules.find({\n hostType: 'gerrit',\n url: endpoint,\n });\n\n const url = parseUrl(endpoint);\n if (!url) {\n throw new Error(CONFIG_GIT_URL_UNAVAILABLE);\n }\n if (!(opts.username && opts.password)) {\n throw new Error(\n 'Init: You must configure a Gerrit Server username/password',\n );\n }\n url.username = opts.username;\n url.password = opts.password;\n url.pathname = joinUrlParts(\n url.pathname,\n 'a',\n encodeURIComponent(repository),\n );\n logger.trace(\n { url: url.toString() },\n 'using URL based on configured endpoint',\n );\n return url.toString();\n}\n\nexport function mapPrStateToGerritFilter(state?: PrState): string | null {\n switch (state) {\n case 'merged':\n return 'status:merged';\n case 'open':\n return 'status:open';\n case 'closed':\n return 'status:abandoned';\n case '!open':\n return '-status:open';\n case 'all':\n default:\n return null;\n }\n}\n\nexport function mapGerritChangeToPr(\n change: GerritChange,\n knownProperties?: {\n sourceBranch?: string;\n prBody?: string;\n },\n): Pr | null {\n const sourceBranch =\n knownProperties?.sourceBranch ?? extractSourceBranch(change);\n if (!sourceBranch) {\n return null;\n }\n return {\n number: change._number,\n state: mapGerritChangeStateToPrState(change.status),\n sourceBranch,\n targetBranch: change.branch,\n title: change.subject,\n createdAt: change.created?.replace(' ', 'T'),\n reviewers:\n change.reviewers?.REVIEWER?.map((reviewer) => reviewer.username!) ?? [],\n bodyStruct: {\n hash: hashBody(knownProperties?.prBody ?? findPullRequestBody(change)),\n },\n sha: change.current_revision as LongCommitSha,\n };\n}\n\nexport function mapGerritChangeStateToPrState(\n state: GerritChangeStatus,\n): 'merged' | 'open' | 'closed' {\n switch (state) {\n case 'NEW':\n return 'open';\n case 'MERGED':\n return 'merged';\n case 'ABANDONED':\n return 'closed';\n }\n}\n\nexport function extractSourceBranch(change: GerritChange): string | undefined {\n let sourceBranch: string | undefined = undefined;\n\n if (change.current_revision) {\n const re = regEx(/^Renovate-Branch: (.+)$/m);\n const currentRevision = change.revisions![change.current_revision];\n const message = currentRevision.commit_with_footers;\n if (message) {\n sourceBranch = re.exec(message)?.[1];\n }\n }\n\n return sourceBranch ?? undefined;\n}\n\nexport function findPullRequestBody(change: GerritChange): string | undefined {\n const msg = Array.from(change.messages ?? [])\n .reverse()\n .find((msg) => msg.tag === TAG_PULL_REQUEST_BODY);\n if (msg) {\n return msg.message.replace(/^Patch Set \\d+:\\n\\n/, ''); //TODO: check how to get rid of the auto-added prefix?\n }\n return undefined;\n}\n\nexport function mapBranchStatusToLabel(\n state: BranchStatus | 'UNKNOWN', // suppress default path code removal\n label: GerritLabelTypeInfo,\n): number {\n const numbers = Object.keys(label.values).map((x) => parseInt(x, 10));\n switch (state) {\n case 'green':\n return Math.max(...numbers);\n case 'yellow':\n case 'red':\n return Math.min(...numbers);\n }\n /* v8 ignore next */\n return label.default_value;\n}\n"]}
|
package/package.json
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "renovate",
|
3
3
|
"description": "Automated dependency updates. Flexible so you don't need to be.",
|
4
|
-
"version": "40.
|
4
|
+
"version": "40.43.0",
|
5
5
|
"type": "commonjs",
|
6
6
|
"bin": {
|
7
7
|
"renovate": "dist/renovate.js",
|
@@ -261,7 +261,7 @@
|
|
261
261
|
"vuln-vects": "1.1.0",
|
262
262
|
"xmldoc": "1.3.0",
|
263
263
|
"yaml": "2.8.0",
|
264
|
-
"zod": "3.25.
|
264
|
+
"zod": "3.25.42"
|
265
265
|
},
|
266
266
|
"optionalDependencies": {
|
267
267
|
"better-sqlite3": "11.10.0",
|
@@ -275,7 +275,7 @@
|
|
275
275
|
"@ls-lint/ls-lint": "2.3.0",
|
276
276
|
"@openpgp/web-stream-tools": "0.1.3",
|
277
277
|
"@semantic-release/exec": "7.1.0",
|
278
|
-
"@smithy/util-stream": "4.2.
|
278
|
+
"@smithy/util-stream": "4.2.2",
|
279
279
|
"@types/auth-header": "1.0.6",
|
280
280
|
"@types/aws4": "1.11.6",
|
281
281
|
"@types/better-sqlite3": "7.6.13",
|
@@ -303,7 +303,7 @@
|
|
303
303
|
"@types/mdast": "3.0.15",
|
304
304
|
"@types/moo": "0.5.10",
|
305
305
|
"@types/ms": "2.1.0",
|
306
|
-
"@types/node": "22.15.
|
306
|
+
"@types/node": "22.15.27",
|
307
307
|
"@types/parse-link-header": "2.0.3",
|
308
308
|
"@types/punycode": "2.1.4",
|
309
309
|
"@types/semver": "7.7.0",
|