Working on the manual...
Making better tests for error messages. Changed a few names. Moved gethostname to inet.c.
This commit is contained in:
parent
0c9f420a35
commit
62a4c505e4
21 changed files with 341 additions and 315 deletions
11
etc/b64.lua
11
etc/b64.lua
|
@ -1,6 +1,11 @@
|
|||
local base64 = socket.mime.base64.encode()
|
||||
local split = socket.mime.split()
|
||||
local convert = socket.mime.chain(base64, split)
|
||||
local convert
|
||||
if arg and arg[1] == '-d' then
|
||||
convert = socket.mime.decode("base64")
|
||||
else
|
||||
local base64 = socket.mime.encode("base64")
|
||||
local wrap = socket.mime.wrap()
|
||||
convert = socket.mime.chain(base64, wrap)
|
||||
end
|
||||
while 1 do
|
||||
local chunk = io.read(4096)
|
||||
io.write(convert(chunk))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue