121 lines
2.1 KiB
YAML
121 lines
2.1 KiB
YAML
include-source: false # Drop file/line/col from output
|
|
---
|
|
on: push
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- run: echo hi
|
|
test-level-0:
|
|
needs: build # string
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- run: echo hi
|
|
test-level-1:
|
|
needs: build
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- run: echo hi
|
|
deploy:
|
|
needs: # sequence
|
|
- test-level-0
|
|
- test-level-1
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- run: echo hi
|
|
---
|
|
{
|
|
"jobs": [
|
|
{
|
|
"type": "job",
|
|
"id": "build",
|
|
"name": "build",
|
|
"if": {
|
|
"type": 3,
|
|
"expr": "success()"
|
|
},
|
|
"runs-on": "ubuntu-latest",
|
|
"steps": [
|
|
{
|
|
"id": "__run",
|
|
"if": {
|
|
"type": 3,
|
|
"expr": "success()"
|
|
},
|
|
"run": "echo hi"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"type": "job",
|
|
"id": "test-level-0",
|
|
"name": "test-level-0",
|
|
"needs": [
|
|
"build"
|
|
],
|
|
"if": {
|
|
"type": 3,
|
|
"expr": "success()"
|
|
},
|
|
"runs-on": "ubuntu-latest",
|
|
"steps": [
|
|
{
|
|
"id": "__run",
|
|
"if": {
|
|
"type": 3,
|
|
"expr": "success()"
|
|
},
|
|
"run": "echo hi"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"type": "job",
|
|
"id": "test-level-1",
|
|
"name": "test-level-1",
|
|
"needs": [
|
|
"build"
|
|
],
|
|
"if": {
|
|
"type": 3,
|
|
"expr": "success()"
|
|
},
|
|
"runs-on": "ubuntu-latest",
|
|
"steps": [
|
|
{
|
|
"id": "__run",
|
|
"if": {
|
|
"type": 3,
|
|
"expr": "success()"
|
|
},
|
|
"run": "echo hi"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"type": "job",
|
|
"id": "deploy",
|
|
"name": "deploy",
|
|
"needs": [
|
|
"test-level-0",
|
|
"test-level-1"
|
|
],
|
|
"if": {
|
|
"type": 3,
|
|
"expr": "success()"
|
|
},
|
|
"runs-on": "ubuntu-latest",
|
|
"steps": [
|
|
{
|
|
"id": "__run",
|
|
"if": {
|
|
"type": 3,
|
|
"expr": "success()"
|
|
},
|
|
"run": "echo hi"
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|