oto/assets/pipeline-test2.yaml
2025-08-22 11:47:11 +09:00

114 lines
No EOL
2.1 KiB
YAML

---
property:
workspace: .
os:
- aos
- ios
configAOS:
- C:/Jenkins/jobs/mcs-aos
- C:/Jenkins/jobs/mcs-aos-lt
configiOS:
- C:/Jenkins/jobs/mcs-ios
- C:/Jenkins/jobs/mcs-ios-lt
pipeline:
id: main
workflow:
- foreach:
iterator: <!property.os>
setValue: <@property.osValue>
on-do:
- if:
condition-string: <!property.osValue> == aos
on-true:
- exe: set-aos
on-false:
- exe: set-ios
- exe: print
- foreach:
iterator: <!property.configs>
setValue: <@property.configValue>
on-do:
- exe: print-config
- exe: read
- exe: branch
- exe: param-modify
# - exe: write
commands:
### Set aos
- command: SetValue
id: set-aos
param:
values-string:
repository: C:/works/oto_cli
values-object:
configs: <!property.configAOS>
### Set ios
- command: SetValue
id: set-ios
param:
values-string:
repository: C:/works/dart_framework
values-object:
configs: <!property.configiOS>
### Test print
- command: Print
id: print
param:
message: Repository - <!property.repository>
### Test print
- command: Print
id: print-config
param:
message: Config - <!property.configValue>
### Strings Read
- command: FileRead
id: read
param:
showPrint: false
path: <!property.configValue>
setContent: <@property.content>
### Replace
- command: StringReplace
id: replace
param:
showPrint: true
text: <!property.content>
pair:
- from: <description>
to: <test>
setValue: <@property.content>
### List up branches
- command: GitBranch
id: branch
param:
path: <!property.repository>
startDay: 60
setBranches: <@property.value>
### Modify param
- command: JenkinsParameterModify
id: param-modify
param:
content: <!property.content>
name: branch
value: <!property.value>
setContent: <@property.content>
### Gradle Write
- command: FileWrite
id: write
param:
path: <!property.configValue>
content: <!property.content>