Update README.md

This commit is contained in:
Tiiffi
2019-11-08 21:56:56 +02:00
committed by GitHub
parent 3f1ea02756
commit 9eb7af2d71

View File

@ -22,31 +22,32 @@ You can also download precompiled binaries*: https://github.com/Tiiffi/mcrcon/re
--- ---
### Usage: ### Usage:
mcrcon [OPTIONS]... [COMMANDS]... mcrcon [OPTIONS] [COMMANDS]
Sends rcon commands to Minecraft server. Sends rcon commands to Minecraft server.
``` ```
Option: Option:
-h Print usage -H Server address (default: localhost)
-H Server address -P Port (default: 25575)
-P Port (default is 25575)
-p Rcon password -p Rcon password
-t Interactive terminal mode -t Terminal mode
-s Silent mode (do not print received packets) -s Silent mode
-c Disable colors -c Disable colors
-r Output raw packets (debugging and custom handling) -r Output raw packets
-v Output version information -h Print usage
-v Version information
``` ```
Commands with arguments must be enclosed in quotes.
Server address, port and password can be set using following environment variables: Server address, port and password can be set using following environment variables:
``` ```
MCRCON_HOST MCRCON_HOST
MCRCON_PORT MCRCON_PORT
MCRCON_PASS MCRCON_PASS
``` ```
Note that command-line options will override environment variables. ###### Notes:
- mcrcon will start in terminal mode if no commands are given
- Command-line options will override environment variables
- Rcon commands with spaces must be enclosed in quotes
Example: Example:
```mcrcon -H my.minecraft.server -p password "say Server is restarting!" save-all stop``` ```mcrcon -H my.minecraft.server -p password "say Server is restarting!" save-all stop```