Yaml BuildPipeLine Preview READMEYaml BuildPipeLine Preview is a small extension to check the syntax and "runabilitly" for a pipeline. FeaturesIt adds a ability to test your current yaml - pipeline file with the preview api from azure devops to check the syntax of your file - without need to check it in or run a real build/release It uses a feature mentioned in the forum here: DeveloperCommunity - Ability to test yaml builds locally RequirementsYou need a azure devOps project and a created pipeline in the specific project you want to run it in. Additionally the extension needs an Personal Access Token to invoke the Azure DevOps Pipelines API. Pls refer to the Azure DevOps Documentation to create one in your organisation How to useYou just need to open up the yml file and select the command in the context menu or the commandlist context menu: or here from the list: Then the extension tries to obtain the information needed to invoke the devops api. 1) Start of the processThe extension validates the current Situation. following errors can occur:
2) Identification of the devOps ProjectThe extension tries to identify the Azure Devops orgaisation and project.
If the setting do not have the property If the remote url is found - you see that message: If this is not possible the extension asks you with an input box If the Url is not provided or not parseable - you get the message:
3) getting/ reading the Personal Access Tokenif the token is not found in the .vscode/settings.json file (property: if you do not enter a value you will get the message 4) getting/reading the pipelineID to useif the token is not found in the .vscode/settings.json file (property: if you do not enter a value you will get the message 5) doing the magic stuffnext the extension tries to get the yml content from the editor and send it to the Azure DevOps Pipelines API. if the response indicates success - the simulation was successful - you get the message if not you will get for example the following message: in this example the error is at Line 26 - position 1 - with clicking the button "Jump there" the cursor gets set to the specific position. Extension SettingsInclude if your extension adds any VS Code settings through the For example: This extension contributes the following settings:
if the settings are not set you get asked on the first run of the extension in your project. Known Issuesnone so far but you are in the early stage of development 😅. Release NotesUsers appreciate release notes as you update your extension. 1.0.0Initial release of it :P -> 1.0.4Bundle updates and readme fixes... 1.0.5Fix parsing DevOpsUrl... 1.0.6Fix in menu definition... Licenseit is published under MIT License. |