an experimental irc client

docs: add manpage

Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>

+135
+11
build.zig
··· 1 1 const std = @import("std"); 2 + const zzdoc = @import("zzdoc"); 2 3 3 4 /// Must be kept in sync with git tags 4 5 const comlink_version: std.SemanticVersion = .{ .major = 0, .minor = 0, .patch = 0 }; ··· 6 7 pub fn build(b: *std.Build) void { 7 8 const target = b.standardTargetOptions(.{}); 8 9 const optimize = b.standardOptimizeOption(.{}); 10 + 11 + // manpages 12 + { 13 + var man_step = zzdoc.addManpageStep(b, .{ 14 + .root_doc_dir = b.path("docs/"), 15 + }); 16 + 17 + const install_step = man_step.addInstallStep(.{}); 18 + b.default_step.dependOn(&install_step.step); 19 + } 9 20 10 21 const ziglua_dep = b.dependency("ziglua", .{ 11 22 .target = target,
+4
build.zig.zon
··· 18 18 .url = "git+https://github.com/ianic/tls.zig#36ae29b0e51fae564222767ffd5d7f60f9a8dd0b", 19 19 .hash = "1220319a215975c0ac3d251b334bfb915765adf21f7e64904028b1ec5ebcf00ea3cd", 20 20 }, 21 + .zzdoc = .{ 22 + .url = "git+https://github.com/rockorager/zzdoc?ref=v0.2.0#4952c59aa4eaacb8e58c651022ca200d0def2e8c", 23 + .hash = "12202a808ac9b32753cf4e093ef95a1c56aa595f7e3d331092ebd8883350c48da930", 24 + }, 21 25 }, 22 26 .paths = .{""}, 23 27 }
+120
docs/comlink.1.scd
··· 1 + comlink(1) 2 + 3 + # NAME 4 + 5 + comlink - an IRC client 6 + 7 + # SYNOPSIS 8 + 9 + *comlink* [options...] 10 + 11 + # OPTIONS 12 + 13 + *-v*, *--version* 14 + Print the version and exit. 15 + 16 + # CONFIGURATION 17 + 18 + Comlink is configured using *lua 5.4*. A lua file defining the API for 19 + configuration should be available in _$PREFIX/share/comlink/lua/comlink.lua_. 20 + Configuration will be loaded from _$XDG_CONFIG_HOME/comlink/init.lua_. Local lua 21 + modules will be searched for within this directory. The search paths are: 22 + 23 + ``` 24 + $XDG_CONFIG_HOME/comlink/\*.lua 25 + $XDG_CONFIG_HOME/comlink/lua/\*.lua 26 + $XDG_CONFIG_HOME/comlink/lua/\*/init.lua 27 + ``` 28 + 29 + The most simple configuration is 30 + 31 + ``` 32 + local comlink = require("comlink") 33 + comlink.connect({ 34 + server = "chat.sr.ht", 35 + user = "rockorager", 36 + nick = "rockorager", 37 + password = "password", 38 + real_name = "Tim Culverhouse", 39 + }) 40 + ``` 41 + 42 + # KEYBOARD SHORTCUTS 43 + 44 + Many keyboard shortcuts may be configured in the configuration file. The 45 + shortcuts shown here are the defaults. 46 + 47 + ## NAVIGATION AND UI 48 + 49 + *CTRL-C* 50 + Quit comlink. 51 + 52 + *ALT-UP* 53 + Select the previous channel or buffer. 54 + 55 + *ALT-DOWN* 56 + Select the next channel or buffer. 57 + 58 + *CTRL-L* 59 + Redraw the entire screen. 60 + 61 + *PAGE_UP* 62 + Scroll the channel up 3 messages. 63 + 64 + *PAGE_DOWN* 65 + Scroll the channel down 3 messages. 66 + 67 + *HOME* 68 + Scroll the channel to the most recent message. 69 + 70 + *TAB* 71 + Open completion options for the last word in the input field. Cycle 72 + through options when the completion menu is open. 73 + 74 + *SHIFT-TAB* 75 + If the compeletion menu is open, cycle through options. 76 + 77 + 78 + 79 + ## EDITING 80 + 81 + *CTRL-A* 82 + Move the cursor to the beginning of the input field. 83 + 84 + *CTRL-E*, *END* 85 + Move the cursor to the end of the input field. 86 + 87 + *CTRL-B* 88 + Move the cursor left one character. 89 + 90 + *CTRL-F* 91 + Move the cursor right one character. 92 + 93 + *CTRL-K* 94 + Delete from the cursor to the end of the input field. 95 + 96 + *CTRL-U* 97 + Delete from the cursor to the start of the input field. 98 + 99 + *CTRL-D* 100 + Delete the character after the cursor 101 + 102 + *ALT-B*, *ALT-LEFT* 103 + Move the cursor backwards one word. 104 + 105 + *ALT-F*, *ALT-RIGHT* 106 + Move the cursor forwards one word. 107 + 108 + *CTRL-W*, *ALT-BACKSPACE* 109 + Delete the word before the cursor. 110 + 111 + *ALT-D* 112 + Delete the word after the cursor. 113 + 114 + *ENTER* 115 + Send the text in the input field. 116 + 117 + # AUTHORS 118 + 119 + Maintained by Tim Culverhouse <tim@timculverhouse.com>. Source code available at 120 + https://git.sr.ht/~rockorager/comlink.