aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormcpcpc <michaelczigler@icloud.com>2020-08-16 12:18:25 -0400
committermcpcpc <michaelczigler@icloud.com>2020-08-16 12:18:25 -0400
commitf0e912510d79950fb1fd616e4af2dcf4580180a3 (patch)
treef2a5271f77910b0f22d31d8a1104f88c7c90d1e4
parentsquash commits related to commands and stabilty (diff)
downloadkirc-f0e912510d79950fb1fd616e4af2dcf4580180a3.tar.gz
kirc-f0e912510d79950fb1fd616e4af2dcf4580180a3.tar.bz2
kirc-f0e912510d79950fb1fd616e4af2dcf4580180a3.tar.xz
kirc-f0e912510d79950fb1fd616e4af2dcf4580180a3.tar.zst
kirc-f0e912510d79950fb1fd616e4af2dcf4580180a3.zip
colored command output
Diffstat (limited to '')
-rw-r--r--README12
-rw-r--r--kirc.c5
2 files changed, 13 insertions, 4 deletions
diff --git a/README b/README
index 57bfee1..fb024ba 100644
--- a/README
+++ b/README
@@ -36,9 +36,14 @@ INSTALLATION
Building and installing from source:
git clone https://github.com/mcpcpc/kirc.git
- cd kirc
- make
- make install
+ tcd kirc
+ make
+ make install
+
+Building and installing using KISS Linux Community repository [2]:
+
+ kiss b kirc
+ kiss i kirc
USAGE
@@ -77,3 +82,4 @@ REFERENCES
[0] https://tools.ietf.org/html/rfc2812
[1] https://en.wikipedia.org/wiki/ANSI_escape_code
+[2] https://github.com/kisslinux/community
diff --git a/kirc.c b/kirc.c
index e1776b8..e417947 100644
--- a/kirc.c
+++ b/kirc.c
@@ -200,7 +200,10 @@ main(int argc, char **argv) {
pars(sl, sbuf);
if (read(fd[0], u, cmax) > 0) {
for (i = 0; u[i] != '\n'; i++) continue;
- if (u[0] != ':') raw("%-*.*s\r\n", i, i, u);
+ if (u[0] != ':') {
+ raw("%-*.*s\r\n", i, i, u);
+ printf("\x1b[1A\x1b[K\x1b[36m%-*.*s\x1b[0m\n", i, i, u);
+ }
}
}
printf("%*s \x1b[31mpress <RETURN> key to quit...\x1b[0m", gutl, " ");