itzg / rcon-cli

A little RCON cli based on james4k's RCON library for golang
Apache License 2.0
177 stars 16 forks source link

End of line supported? #1

Closed djxy closed 6 years ago

djxy commented 6 years ago

Hi,

I'm trying to use the rcon-cli with itzg/minecraft-server, but the cli don't seem to handle the end of line.

Example when I do docker exec mc rcon-cli help it returns this.

root@vultr:~# docker exec mc rcon-cli help
--- Showing help page 1 of 10 (/help <page>) ---/advancement <grant|revoke|test> <player>/ban <name> [reason ...]/ban-ip 
<address|name> [reason ...]/banlist [ips|players]/blockdata <x> <y> <z> <dataTag>/clear [player] [item] [data] [maxCount]
 [dataTag]/clone <x1> <y1> <z1> <x2> <y2> <z2> <x> <y> <z> [maskMode] [cloneMode]Tip: Use the <tab> key while typing a co
mmand to auto-complete the command or its arguments   

But it should return something like this.

--- Showing help page 1 of 10 (/help <page>) ---                                        
/advancement <grant|revoke|test> <player>                                               
/ban <name> [reason ...]                                                                
/ban-ip <address|name> [reason ...]                                                     
/banlist [ips|players]                                                                  
/blockdata <x> <y> <z> <dataTag>                                                        
/clear [player] [item] [data] [maxCount] [dataTag]                                      
/clone <x1> <y1> <z1> <x2> <y2> <z2> <x> <y> <z> [maskMode] [cloneMode]                 
Tip: Use the <tab> key while typing a command to auto-complete the command or its arguments    

I even tried with the interactive mode.

root@vultr:~# docker exec -i mc rcon-cli                                                                       
> help                                                                                                                   
--- Showing help page 1 of 10 (/help <page>) ---/advancement <grant|revoke|test> <player>/ban <name> [reason ...]/ban-ip 
<address|name> [reason ...]/banlist [ips|players]/blockdata <x> <y> <z> <dataTag>/clear [player] [item] [data] [maxCount]
 [dataTag]/clone <x1> <y1> <z1> <x2> <y2> <z2> <x> <y> <z> [maskMode] [cloneMode]Tip: Use the <tab> key while typing a co
mmand to auto-complete the command or its arguments 
djxy commented 6 years ago

It's a bug with minecraft.

https://bugs.mojang.com/browse/MC-7569

itzg commented 6 years ago

Yeah, that’s been annoying me the whole time I started with this tool. I had used wireshark a couple of times to make I wasn’t missing something...so I’m very thankful for the specific issue link you found.