first commit
This commit is contained in:
47
system/repos_actions.yaml
Normal file
47
system/repos_actions.yaml
Normal file
@@ -0,0 +1,47 @@
|
||||
# yaml-language-server: $schema=https://git.jesof.ch/public/mstr-schemas/raw/branch/main/mstr-tasks-schema.json
|
||||
tasks:
|
||||
- print:
|
||||
format: "Path: $(path)"
|
||||
|
||||
- return:
|
||||
description: "Not a git repository"
|
||||
when: $(!dirExists(format("%s/.git",path)))
|
||||
|
||||
- execute:
|
||||
description: "Pull git repository"
|
||||
exec: "git"
|
||||
dir: $(path)
|
||||
args:
|
||||
- "pull"
|
||||
|
||||
- execute:
|
||||
description: "Check repository"
|
||||
exec: "git"
|
||||
dir: $(path)
|
||||
args:
|
||||
- "remote"
|
||||
- "-v"
|
||||
matchers:
|
||||
- name: "Check for jesof repository"
|
||||
expression: "^origin.*https://git.jesof.ch/"
|
||||
onError: continue
|
||||
|
||||
- return:
|
||||
description: "Not jesof repository"
|
||||
when: $(lastError() != nil)
|
||||
|
||||
- execute:
|
||||
description: "Push all"
|
||||
exec: "git"
|
||||
dir: $(path)
|
||||
args:
|
||||
- "push"
|
||||
- "--all"
|
||||
|
||||
- execute:
|
||||
description: "Push tags"
|
||||
exec: "git"
|
||||
dir: $(path)
|
||||
args:
|
||||
- "push"
|
||||
- "--tags"
|
||||
Reference in New Issue
Block a user