update scheduler
This commit is contained in:
parent
47b78623a8
commit
8920def09d
1 changed files with 96 additions and 19 deletions
|
|
@ -1,38 +1,115 @@
|
|||
---
|
||||
scheduler:
|
||||
alias: test
|
||||
# cron: '* * * * *'
|
||||
interval: 60000 # ms
|
||||
alias: darksoulIII
|
||||
cron: '* * * * *'
|
||||
# interval: 10000 # ms
|
||||
enableLog: true # (Optional) default: false
|
||||
|
||||
|
||||
property:
|
||||
workspace: /home/deck/work/oto_cli
|
||||
|
||||
workspace: /home/deck/.steam/steam/steamapps/compatdata/374320/pfx/drive_c/users/steamuser/AppData/Roaming/DarkSoulsIII
|
||||
saveFolder: <!property.workspace>/01100001112a7a14
|
||||
savePath: <!property.saveFolder>/DS30000.sl2
|
||||
|
||||
pipeline:
|
||||
id: main
|
||||
workflow:
|
||||
- exe: read-web
|
||||
- exe: json-read-web
|
||||
- exe: json-read-local
|
||||
- exe: diff
|
||||
- if:
|
||||
condition-bool: <!property.isDiff> == true
|
||||
- if:
|
||||
condition-bool: <!property.diff> == true
|
||||
on-true:
|
||||
- exe: shell
|
||||
|
||||
- exe: info
|
||||
- if:
|
||||
condition-date: <!property.lastSavedWeb> < <!property.info.modified>
|
||||
on-true:
|
||||
- exe: json-write-local
|
||||
- exe: upload
|
||||
- if:
|
||||
condition-date: <!property.lastSavedWeb> > <!property.lastSavedLocal>
|
||||
on-true:
|
||||
- exe: json-write-web
|
||||
- exe: download
|
||||
|
||||
|
||||
commands:
|
||||
- command: FileInfo
|
||||
id: info
|
||||
param:
|
||||
path: <!property.savePath>
|
||||
setInfo: <@property.info>
|
||||
|
||||
- command: WebRequest
|
||||
id: read-web
|
||||
param:
|
||||
url: https://toki-labs.com/cdn/save/darksoulIII/save.json
|
||||
setResponse: <@property.web>
|
||||
|
||||
- command: JsonReader
|
||||
id: json-read-web
|
||||
param:
|
||||
json: <!property.web>
|
||||
pair:
|
||||
- from: lastSaved
|
||||
setValue: <@property.lastSavedWeb>
|
||||
|
||||
- command: JsonReaderFile
|
||||
id: json-read-local
|
||||
param:
|
||||
path: <!property.saveFolder>/save.json
|
||||
pair:
|
||||
- from: lastSaved
|
||||
setValue: <@property.lastSavedLocal>
|
||||
|
||||
- command: Print
|
||||
id: print
|
||||
param:
|
||||
message: change save file
|
||||
|
||||
- command: FileDiffCheck
|
||||
id: diff
|
||||
param:
|
||||
paths:
|
||||
- <!property.workspace>/lib/oto/data/command_data.dart
|
||||
- <!property.workspace>/lib/oto/data/jenkins_data.dart
|
||||
- <!property.workspace>/lib/oto/data/jira_data.dart
|
||||
- <!property.workspace>/lib/oto/data/pipeline_data.dart
|
||||
setDiff: <@property.isDiff>
|
||||
paths:
|
||||
- <!property.savePath>
|
||||
setDiff: <@property.diff>
|
||||
|
||||
- command: Shell
|
||||
id: shell
|
||||
- command: JsonWriterFile
|
||||
id: json-write-local
|
||||
param:
|
||||
commands:
|
||||
- flutter pub run build_runner build --delete-conflicting-outputs
|
||||
path: <!property.saveFolder>/save.json
|
||||
pair:
|
||||
- from: lastSaved
|
||||
value: <!property.info.modified>
|
||||
|
||||
- command: Upload
|
||||
id: upload
|
||||
param:
|
||||
sftp: true
|
||||
port: 22
|
||||
host: toki-labs.com
|
||||
user: toki
|
||||
password: r0bins
|
||||
map:
|
||||
<!property.savePath> : /Users/toki/docker/nginx/home/cdn/save/darksoulIII
|
||||
<!property.saveFolder>/save.json : /Users/toki/docker/nginx/home/cdn/save/darksoulIII
|
||||
|
||||
- command: JsonWriterFile
|
||||
id: json-write-web
|
||||
param:
|
||||
path: <!property.saveFolder>/save.json
|
||||
pair:
|
||||
- from: lastSaved
|
||||
value: <!property.lastSavedWeb>
|
||||
|
||||
- command: Download
|
||||
id: download
|
||||
param:
|
||||
sftp: true
|
||||
port: 22
|
||||
host: toki-labs.com
|
||||
user: toki
|
||||
password: r0bins
|
||||
map:
|
||||
/Users/toki/docker/nginx/home/cdn/save/darksoulIII/DS30000.sl2 : <!property.saveFolder>
|
||||
Loading…
Reference in a new issue