...
This commit is contained in:
@@ -153,7 +153,7 @@ pub fn plbook_run(cmd Command) !(&playbook.PlayBook, string) {
|
||||
|
||||
dagu := cmd.flags.get_bool('dagu') or { false }
|
||||
|
||||
plbook = playcmds.run(plbook:plbook)!
|
||||
playcmds.run(mut playbook)!
|
||||
|
||||
// TODO: below gives Segmentation fault (core dumped)
|
||||
// console.print_stdout(plbook.str())
|
||||
|
||||
@@ -58,6 +58,7 @@ pub mut:
|
||||
|
||||
// only return the actions which are not done yet
|
||||
// if filtered is set, it means we only get the ones which were prioritized before
|
||||
// we ignore prio's above 49
|
||||
pub fn (mut plbook PlayBook) actions_sorted(args SortArgs) ![]&Action {
|
||||
mut res := []&Action{}
|
||||
mut nrs := plbook.priorities.keys()
|
||||
@@ -98,6 +99,7 @@ pub fn (mut plbook PlayBook) heroscript(args HeroScriptArgs) !string {
|
||||
// out += '${plbook.othertext}'
|
||||
// }
|
||||
out = texttools.remove_empty_js_blocks(out)
|
||||
out +="\n\n"
|
||||
return out
|
||||
}
|
||||
|
||||
|
||||
@@ -22,10 +22,10 @@ pub fn run(args_ PlayArgs) !PlayBook {
|
||||
mut plbook := args.plbook or {
|
||||
playbook.new(text: args.heroscript, path: args.heroscript_path)!
|
||||
}
|
||||
plbook = play_core(plbook:plbook)!
|
||||
plbook = play_git(plbook:plbook)!
|
||||
play_core(mut playbook)!
|
||||
play_git(mut playbook)!
|
||||
|
||||
// plbook = play_ssh(mut plbook)!
|
||||
// play_ssh(mut plbook)!
|
||||
// play_publisher(mut plbook)!
|
||||
// play_zola(mut plbook)!
|
||||
// play_caddy(mut plbook)!
|
||||
@@ -36,8 +36,8 @@ pub fn run(args_ PlayArgs) !PlayBook {
|
||||
|
||||
// plbook = farmingsimulator.play(mut plbook)!
|
||||
// plbook = gridsimulator.play(mut plbook)!
|
||||
plbook = bizmodel.play(plbook:plbook)!
|
||||
plbook = doctree.play(plbook:plbook)!
|
||||
plbook = bizmodel.play(mut playbook)!
|
||||
plbook = doctree.play(mut playbook)!
|
||||
|
||||
// slides.play(mut plbook)!
|
||||
// base_install(play(mut plbook)!
|
||||
|
||||
@@ -11,7 +11,7 @@ import freeflowuniverse.herolib.ui.console
|
||||
// interactive:true
|
||||
|
||||
|
||||
pub fn play_core(args_ PlayArgs) !PlayBook {
|
||||
fn play_core(args_ PlayArgs) !PlayBook {
|
||||
mut args := args_
|
||||
mut plbook := args.plbook or {
|
||||
playbook.new(text: args.heroscript, path: args.heroscript_path)!
|
||||
|
||||
@@ -6,7 +6,7 @@ import freeflowuniverse.herolib.core.playbook { PlayBook }
|
||||
// import freeflowuniverse.herolib.ui.console
|
||||
import freeflowuniverse.herolib.web.docusaurus
|
||||
|
||||
pub fn play(args_ PlayArgs) !PlayBook {
|
||||
fn play(args_ PlayArgs) !PlayBook {
|
||||
mut args := args_
|
||||
mut plbook := args.plbook or {
|
||||
playbook.new(text: args.heroscript, path: args.heroscript_path)!
|
||||
|
||||
@@ -4,7 +4,7 @@ import freeflowuniverse.herolib.develop.gittools
|
||||
import freeflowuniverse.herolib.core.playbook {PlayBook}
|
||||
import freeflowuniverse.herolib.ui.console
|
||||
|
||||
pub fn play_git(args_ PlayArgs) !PlayBook {
|
||||
fn play_git(args_ PlayArgs) !PlayBook {
|
||||
mut args := args_
|
||||
mut plbook := args.plbook or {
|
||||
playbook.new(text: args.heroscript, path: args.heroscript_path)!
|
||||
|
||||
@@ -4,7 +4,7 @@ import freeflowuniverse.herolib.develop.luadns
|
||||
import freeflowuniverse.herolib.core.playbook {PlayBook}
|
||||
// import os
|
||||
|
||||
pub fn play_luadns(args_ PlayArgs) !PlayBook {
|
||||
fn play_luadns(args_ PlayArgs) !PlayBook {
|
||||
mut args := args_
|
||||
mut plbook := args.plbook or {
|
||||
playbook.new(text: args.heroscript, path: args.heroscript_path)!
|
||||
|
||||
@@ -3,7 +3,7 @@ module playcmds
|
||||
import freeflowuniverse.herolib.osal.sshagent
|
||||
import freeflowuniverse.herolib.core.playbook {PlayBook}
|
||||
|
||||
pub fn play_ssh(args_ PlayArgs) !PlayBook {
|
||||
fn play_ssh(args_ PlayArgs) !PlayBook {
|
||||
mut args := args_
|
||||
mut plbook := args.plbook or {
|
||||
playbook.new(text: args.heroscript, path: args.heroscript_path)!
|
||||
|
||||
@@ -124,7 +124,7 @@ import freeflowuniverse.herolib.web.site
|
||||
// session ?&base.Session is optional
|
||||
mut plbook := playbook.new( "....")!
|
||||
|
||||
site.play(plbook:plbook)!
|
||||
site.play(mut playbook)!
|
||||
|
||||
```
|
||||
|
||||
|
||||
Reference in New Issue
Block a user