]> git.proxmox.com Git - mirror_edk2.git/blob - .azurepipelines/ReadMe.md
NetworkPkg/DxeNetLib: Change the order of conditions in IF statement
[mirror_edk2.git] / .azurepipelines / ReadMe.md
1 # Azure DevOps Pipelines
2
3 These yml files are used to provide CI builds using the Azure DevOps Pipeline Service.
4 Most of the CI leverages edk2-pytools to support cross platform building and execution.
5
6 ## Core CI
7
8 Focused on building and testing all packages in Edk2 without an actual target platform.
9
10 See `.pytools/ReadMe.py` for more details
11
12 ## Platform CI
13
14 Focused on building a single target platform and confirming functionality on that platform.
15
16 ## Conventions
17
18 * Files extension should be *.yml. *.yaml is also supported but in Edk2 we use those for our package configuration.
19 * Platform CI files should be in the `<PlatformPkg>/.azurepipelines` folder.
20 * Core CI files are in the root folder.
21 * Shared templates are in the `templates` folder.
22 * Top level CI files should be named `<host os>-<tool_chain_tag>.yml`
23
24 ## Links
25
26 * Basic Azure Landing Site - https://docs.microsoft.com/en-us/azure/devops/pipelines/?view=azure-devops
27 * Pipeline jobs - https://docs.microsoft.com/en-us/azure/devops/pipelines/process/phases?view=azure-devops&tabs=yaml
28 * Pipeline yml scheme - https://docs.microsoft.com/en-us/azure/devops/pipelines/yaml-schema?view=azure-devops&tabs=schema%2Cparameter-schema
29 * Pipeline expression - https://docs.microsoft.com/en-us/azure/devops/pipelines/process/expressions?view=azure-devops
30 * PyTools - https://github.com/tianocore/edk2-pytool-extensions and https://github.com/tianocore/edk2-pytool-library
31
32 ## Lessons Learned
33
34 ### Templates and parameters
35
36 They are great but evil. If they are used as part of determining the steps of a build they must resolve before the build starts. They can not use variables set in a yml or determined as part of a matrix. If they are used in a step then they can be bound late.
37
38 ### File matching patterns
39
40 On Linux this can hang if there are too many files in the search list.
41
42 ### Templates and file splitting
43
44 Suggestion is to do one big yaml file that does what you want for one of your targets. Then do the second one and find the deltas. From that you can start to figure out the right split of files, steps, jobs.
45
46 ### Conditional steps
47
48 If you want the step to show up in the log but not run, use a step conditional. This is great when a platform doesn't currently support a feature but you want the builders to know that the features exists and maybe someday it will.
49
50 If you want the step to not show up use a template step conditional wrapper. Beware this will be evaluated early (at build start). This can hide things not needed on a given OS for example.