From 6fc33abdea2e0a09adf5cf1811fe1ee2fd36f0c9 Mon Sep 17 00:00:00 2001 From: Mikhail Osipov Date: Mon, 20 Jan 2020 04:20:48 +0300 Subject: initial --- pkg/server/echo.go | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 pkg/server/echo.go (limited to 'pkg/server/echo.go') diff --git a/pkg/server/echo.go b/pkg/server/echo.go new file mode 100644 index 0000000..74c0450 --- /dev/null +++ b/pkg/server/echo.go @@ -0,0 +1,15 @@ +package server + +import ( + "strings" + "fmt" + "io" +) + +func init() { + setHandler("echo", echo) +} + +func echo(s *Server, args []string, out io.Writer) { + fmt.Fprint(out, strings.Join(args[1:], " ")) +} -- cgit v1.2.3-70-g09d2