-
🔰 fundamental topics for beginners getting started with DevSensei
-
🔬 advanced topics for once you have your first workflows automated
Syntax support in IDE for DevSensei configuration 🔰
The app provides a YAML Schema for the devsensei.yaml file.
Benefits:
-
Auto-completion of YAML keys
-
Basic validations, (e.g. ensure that a workflow has actions)
-
Documentation of YAML elements within the editor
-
Showing code examples from the Spec as help
Download the YAML Schema from Bitbucket:
https://YOUR_BITBUCKET/rest/codeowners/1.0/devsensei/schema
Depending on your IDE, map that YAML Schema to files named devsensei.yaml.
IntelliJ IDEA & JetBrains IDE’s
-
Go to IntelliJ IDEA (or other Jetbrains IDE) settings
-
Search for
JSON Schema Mappings -
Add a new mapping:
-
Name:
DevSensei Schema file -
Schema URL: https://YOUR_BITBUCKET/rest/codeowners/1.0/devsensei/schema
-
Schema version:
JSON Schema version 7 -
File:
devsensei.yaml
-
VS Code
VS Code with the RedHat YAML plugin can either use an inline reference to the JSON Schema
# yaml-language-sever: $schema=https://YOUR_BITBUCKET/rest/codeowners/1.0/devsensei/schema
workflows:
# ...
or have a global mapping within the VS Code settings.json:
{
"yaml.schemas": {
"https://YOUR_BITBUCKET/rest/codeowners/1.0/devsensei/schema": [
"devsensei.yaml"
]
}
}