From bb574f52182821e79bfa9c113f66b5b2d3c15aa5 Mon Sep 17 00:00:00 2001 From: Sean Hinchee Date: Tue, 30 Jan 2018 07:44:08 +0000 Subject: [PATCH] tweaks --- x/mux/man.go | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/x/mux/man.go b/x/mux/man.go index e3d760ec7057a84b88baa9bc7b036baec8ff425a..3f4ec1899d3a8cc1e322b76158cd208fd16a4228 100644 --- a/x/mux/man.go +++ b/x/mux/man.go @@ -19,7 +19,7 @@ func (m *Mux) Man(ds *discordgo.Session, dm *discordgo.Message, ctx *Context) { "Section (1) for general publicly accessible commands.", "Section (2) for library functions, including system calls.", "Section (3) for kernel devices (accessed via bind (1)).", - "Section (4) for file services (accessed via mount ).", + "Section (4) for file services (accessed via mount).", "Section (5) for the Plan 9 file protocol.", "Section (6) for file formats.", "Section (7) for databases and database access programs.", @@ -77,6 +77,11 @@ func (m *Mux) Man(ds *discordgo.Session, dm *discordgo.Message, ctx *Context) { resp += "No matching manual page(s) found." } + } else if len(ctx.Fields) == 1 { + resp += ".\n" + for i:=1; i < 9; i++ { + resp += desc[i-1] + "\n" + } } else { resp += "No op. Please use the 'man 3 srv' format or 'man srv' format." }