| View previous topic :: View next topic |
| Author |
Message |
haferbrei Voice
Joined: 08 Apr 2020 Posts: 23
|
Posted: Mon Mar 08, 2021 7:36 pm Post subject: Output to channel |
|
|
How can I output the intermediate output directly from a script?
Currently it is only output after the script has finished.
Actually i call a shell script to execute a lot of things.
| Code: |
set binary {./script.sh}
foreach line [split [exec $binary $pack $pack2 $nick] "\n"] {
putquick "PRIVMSG $chan :$line"
}
}
|
my idea would be to split the shell script into x scripts and call them one after the other.
is it also possible to do it more elegantly? |
|
| Back to top |
|
 |
haferbrei Voice
Joined: 08 Apr 2020 Posts: 23
|
Posted: Fri Apr 16, 2021 10:24 pm Post subject: |
|
|
How can I putquick "PRIVMSG $chan :$pack arrives." in the channel before exec is executed?
currently it is not output until exec is done.
| Code: |
set binary {/etc/eggdrop/bashscript.sh}
putquick "PRIVMSG $chan :$pack arrives."
foreach line [split [exec $binary $pack] "\n"] {
putquick "PRIVMSG $chan :$line"
}
|
|
|
| Back to top |
|
 |
|