vscode-yaml
vscode-yaml copied to clipboard
.gitlab-ci.yml - Custom tag !reference defined in schema but reported as error.
Describe the bug
Expected Behavior
This code is actually valid:
.gitlab-ci.yml
.common:
before_script:
- git config --global credential.helper store
.job:
before_script:
- !reference [.common, before_script]
The correct schema is loaded: https://github.com/SchemaStore/schemastore/blob/master/src/api/json/catalog.json#L1732 https://gitlab.com/gitlab-org/gitlab/-/blob/master/app/assets/javascripts/editor/schema/ci.json#L29
Current Behavior
Problems are raised for each !reference tag in the file: Unresolved tag: !reference
Steps to Reproduce
Use the above mentioned file.
Environment
- [X ] Windows
- [ ] Mac
- [ X] Linux
- [ ] other (please specify)
I can confirm it is reproduced on Mac OS, too.
It is still an issue; MacOS Sonoma, latest vs code
I fixed it by adding the following in my settings.yml of vscode
"yaml.customTags": [
"!reference sequence"
],