shithub: neatroff

Download patch

ref: 5a3cf696ed2c10ebacf756f1d7b721a1c5ae82e3
parent: 8fdaed8335f3396503838e7403de464f7ebf7211
author: Ali Gholami Rudi <[email protected]>
date: Wed Jul 24 12:16:31 EDT 2013

tr: add .sy

--- a/tr.c
+++ b/tr.c
@@ -347,6 +347,11 @@
 	in_ex();
 }
 
+static void tr_sy(char **args)
+{
+	system(args[1]);
+}
+
 static void tr_lt(char **args)
 {
 	int lt = args[1] ? eval_re(args[1], n_lt, 'm') : n_t0;
@@ -666,6 +671,7 @@
 	{"so", tr_so},
 	{"sp", tr_sp},
 	{"sv", tr_sv},
+	{"sy", tr_sy, mkargs_eol},
 	{"ta", tr_ta},
 	{"ti", tr_ti},
 	{"tl", tr_tl, mkargs_null},