# go-sendxmpp ## about A little tool to send messages to an XMPP contact or MUC inspired by (but not as powerful as) [sendxmpp](https://sendxmpp.hostname.sk/). ## requirements * [go](https://golang.org/) ## installation If you have *[GOPATH](https://github.com/golang/go/wiki/SettingGOPATH)* set just run this commands: ```bash $ go get salsa.debian.org/mdosch-guest/go-sendxmpp $ go install salsa.debian.org/mdosch-guest/go-sendxmpp ``` You will find the binary in `$GOPATH/bin` or, if set, `$GOBIN`. ## usage The account details for logging into your XMPP account and at least `contact` or `muc` must be specified. If `-message` is not specified you can either pipe a programs output to `go-sendxmpp` or write in your terminal (put ^D in a new line to finish). If `-port` is not set, the standard port *5222* is used. ```bash Usage of ./go-sendxmpp: -contact string Recipient of the message. (default "alice@example.com") -message string The message you want to send. (default "Hello World!") -muc string MUC to send the message to. (default "offtopic@conference.example.com") -muc-nick string The nickname the bot uses in the MUC. (default "go-sendxmpp") -pass string Password for XMPP account. (default "ChangeThis!") -port string XMPP server port. (default "5222") -server string XMPP server address. (default "example.com") -user string Username for XMPP account. (default "bob@example.com") ``` ### examples ```bash inxi -F | ./go-sendxmpp -pass 'ChangeThis!' -port '5222' -server 'example.com' -user 'bob@example.com' -muc 'test@conference.example.com' ``` ```bash ./go-sendxmpp -pass 'ChangeThis!' -port '5222' -server 'example.com' -user 'bob@example.com' -muc 'test@conference.example.com' -message 'Hello World!' ```