summaryrefslogtreecommitdiffstats
path: root/krebs/5pkgs/simple/irc-announce/default.nix
diff options
context:
space:
mode:
authormakefu <github@syntax-fehler.de>2020-03-19 13:16:27 +0100
committermakefu <github@syntax-fehler.de>2020-03-19 13:16:27 +0100
commit2761a90fbb4747a473c792060e258088a1749263 (patch)
tree457af539332b3ab299b55f52fe1fbf5195044178 /krebs/5pkgs/simple/irc-announce/default.nix
parentcbd9b1923236566893f12a9ce96bec7c9f59fcda (diff)
parent2ec1535de5c3e751d2c98952d0f2eeb80d1d2e1e (diff)
Merge remote-tracking branch 'lass/master'
Diffstat (limited to 'krebs/5pkgs/simple/irc-announce/default.nix')
-rw-r--r--krebs/5pkgs/simple/irc-announce/default.nix7
1 files changed, 6 insertions, 1 deletions
diff --git a/krebs/5pkgs/simple/irc-announce/default.nix b/krebs/5pkgs/simple/irc-announce/default.nix
index dea30a056..a90814aa9 100644
--- a/krebs/5pkgs/simple/irc-announce/default.nix
+++ b/krebs/5pkgs/simple/irc-announce/default.nix
@@ -24,7 +24,12 @@ pkgs.writeDashBin "irc-announce" ''
# echo2 and cat2 are used output to both, stdout and stderr
# This is used to see what we send to the irc server. (debug output)
echo2() { echo "$*"; echo "$*" >&2; }
- cat2() { (read x ; echo "$x" ; echo "$x" >&2) }
+ cat2() {
+ while read -r line; do
+ echo "$line"
+ echo "$line" >&2
+ done
+ }
# privmsg_cat transforms stdin to a privmsg
privmsg_cat() { awk '{ print "PRIVMSG "ENVIRON["IRC_CHANNEL"]" :"$0 }'; }