refactor: change `input:extend` to `string` from `array`
BREAKING CHANGE: The ruleset `input:extend` is now a `string` rather than an `array`. The change allows the rulesets to use the [`!reference` tags][reference] tags with `$[[ inputs.extends ]]`. Previously with an array, it was not possible to use the `!reference` concept. This breaks any usage of the `input:extend`. In _most_ cases, the change is to switch from an array to a string: ```yaml include: - component: "${CI_SERVER_HOST}/ci/component/bazelisk/ruleset@v1.2.1" inputs: extends: - .base .base: extends: .job before_script: - echo world ``` Changes to: ```yaml include: - component: "${CI_SERVER_HOST}/ci/component/bazelisk/ruleset@v1.2.1" inputs: extends: .base .base: extends: .job before_script: - echo world ``` In the case of multiple extensions, switch to a single extended job: ```yaml include: - component: "${CI_SERVER_HOST}/ci/component/bazelisk/ruleset@v1.2.1" inputs: extends: - .hello - .world .hello: extends: .job before_script: - echo world .world: extends: .job after_script: - echo world ``` Would change to: ```yaml include: - component: "${CI_SERVER_HOST}/ci/component/bazelisk/ruleset@v1.2.1" inputs: extends: .base .hello: extends: .job before_script: - echo world .world: extends: .job after_script: - echo world .base: extends: - .hello - .world ``` [reference]: https://docs.gitlab.com/ci/yaml/yaml_optimization/#reference-tags
Loading
Please register or sign in to comment