79 lines
1.5 KiB
YAML
79 lines
1.5 KiB
YAML
# yaml-language-server: $schema=https://git.jesof.ch/public/mstr-schemas/raw/branch/main/mstr-tasks-schema.json
|
|
tasks:
|
|
- loadVariables:
|
|
url: $(path)/.mstr.yaml
|
|
path: "variables"
|
|
|
|
- return:
|
|
when: $(!has("orchestra"))
|
|
|
|
- return:
|
|
when: $(orchestra != "deploy")
|
|
|
|
- call:
|
|
script: "@(system)/check-git-repository.yaml"
|
|
args:
|
|
path: $(path)
|
|
returns:
|
|
- gitChanges
|
|
|
|
- throw:
|
|
description: "Check if repository is clean"
|
|
message: 'Git repository "$(path)" not clean, please commit changes ...'
|
|
when: $(gitChanges != "")
|
|
|
|
- execute:
|
|
description: "Update application $(path)"
|
|
exec: "mstr"
|
|
dir: "$(path)"
|
|
args:
|
|
- "update"
|
|
|
|
- call:
|
|
script: "@(system)/check-git-repository.yaml"
|
|
args:
|
|
path: $(path)
|
|
returns:
|
|
- gitChanges
|
|
|
|
- return:
|
|
description: 'Git repository "$(path)" clean, continue ...'
|
|
when: $(gitChanges == "")
|
|
|
|
- execute:
|
|
description: "Update application $(path)"
|
|
exec: "mstr"
|
|
dir: "$(path)"
|
|
args:
|
|
- "build"
|
|
|
|
- execute:
|
|
dir: "$(path)"
|
|
exec: "git"
|
|
args:
|
|
- "add"
|
|
- "."
|
|
|
|
- execute:
|
|
dir: "$(path)"
|
|
exec: "git"
|
|
args:
|
|
- "commit"
|
|
- "-m"
|
|
- "Dependency upgrades"
|
|
|
|
- execute:
|
|
dir: "$(path)"
|
|
exec: "git"
|
|
args:
|
|
- "push"
|
|
|
|
- execute:
|
|
description: "Release application $(path)"
|
|
dir: "$(path)"
|
|
exec: "mstr"
|
|
args:
|
|
- "release"
|
|
- "minor"
|
|
- "--deploy"
|