Skip to content
forked from atla/goirc-xdcc

Golang xdcc addon for the popular fluffle/goirc package

License

Notifications You must be signed in to change notification settings

Weneg/goirc-xdcc

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

goirc-xdcc

xdcc addon for the popular fluffle/goirc package

Usage:

You can either use the xdcc package as an addon to the Connection class of fluffle/goirc and add xdcc capabilities like that:

xdcc := xdcc.New(bot.conn)

xdcc.GetXdcc(pack.Host, fmt.Sprintf("xdcc send #%d", pack.PackageID), "./downloads/")

or you can use the convenience bot package that makes use of fluffle/goirc and the xdcc package to automate file downloads by providing an easy to use interface:


import "github.com/atla/goirc-xdcc/bot"

func main() {

	xdccBot := bot.New()

	// bot will get a package and store it in ./downloads/ folder
	xdccBot.Get(bot.Package{
		Host:    "botxy123",
		Network: "irc.freenode.net",
		// channel the client has to be in in order to receive a transfer from the bot
		Channel: "#channel1",
		// sometimes there is a second channel that you have to connect to before bot will send you files
		CompanionChannel: "#otherChannel",
		PackageID:        42,
	})

}

Future updates planned:

  • DCC Resume command
  • proper quitting of the bot after download
  • Percentage updates in form of an DownloadUpdate channel

About

Golang xdcc addon for the popular fluffle/goirc package

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 100.0%