mirror of
https://github.com/spring-projects/spring-security.git
synced 2025-07-13 05:43:29 +00:00
Override collector config for 6.0.0-RC1
Closes gh-12607
This commit is contained in:
parent
02587c7407
commit
06d05691b9
@ -5,6 +5,13 @@ const JVM_ARGS='-Xmx3g -XX:+HeapDumpOnOutOfMemoryError'
|
|||||||
const REPO_URL = 'https://github.com/spring-projects/spring-security'
|
const REPO_URL = 'https://github.com/spring-projects/spring-security'
|
||||||
const TASK_NAME=':spring-security-docs:generateAntora'
|
const TASK_NAME=':spring-security-docs:generateAntora'
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Set of tags that contain a collector config, but the antora command fails on GitHub Actions.
|
||||||
|
*/
|
||||||
|
const VERSIONS_TO_OVERRIDE = [
|
||||||
|
'6.0.0-RC1'
|
||||||
|
]
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The purpose of this extension is to inject the Antora Collector configuration into the parsed component version
|
* The purpose of this extension is to inject the Antora Collector configuration into the parsed component version
|
||||||
* descriptor in tags created before Antora Collector was introduced. Antora Collector runs a command to generate a
|
* descriptor in tags created before Antora Collector was introduced. Antora Collector runs a command to generate a
|
||||||
@ -15,7 +22,13 @@ module.exports.register = function () {
|
|||||||
this.once('contentAggregated', ({ contentAggregate }) => {
|
this.once('contentAggregated', ({ contentAggregate }) => {
|
||||||
for (const { origins } of contentAggregate) {
|
for (const { origins } of contentAggregate) {
|
||||||
for (const origin of origins) {
|
for (const origin of origins) {
|
||||||
if (!(origin.url === REPO_URL && origin.descriptor.ext?.collector === undefined)) continue
|
if (origin.url !== REPO_URL) {
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
// Ignore tags with their own collector config unless the antora command fails on GitHub Actions
|
||||||
|
if (!(origin.descriptor.ext?.collector === undefined || VERSIONS_TO_OVERRIDE.includes(origin.tag))) {
|
||||||
|
continue
|
||||||
|
}
|
||||||
origin.descriptor.ext = {
|
origin.descriptor.ext = {
|
||||||
collector: {
|
collector: {
|
||||||
run: { command: `${BASE_COMMAND} "-Dorg.gradle.jvmargs=${JVM_ARGS}" ${TASK_NAME}`, local: true },
|
run: { command: `${BASE_COMMAND} "-Dorg.gradle.jvmargs=${JVM_ARGS}" ${TASK_NAME}`, local: true },
|
||||||
|
Loading…
x
Reference in New Issue
Block a user