Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
XG is an IRC Downloadmanager written in C#.
C# JavaScript CSS Other

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
Core.Test
Core
Lib
Server.Cmd.Setup.Win
Server.Cmd
Server.Plugin.Backend.File
Server.Plugin.Backend.MySql
Server.Plugin.General.Import
Server.Plugin.General.Jabber
Server.Plugin.General.Webserver.Test
Server.Plugin.General.Webserver
Server.Test
Server
.gitignore
README.md
XG.mds
XG.sln
log4net.example
settings.example.xml
start.sh
stop.sh

README.md

XG

XG, called __X__dcc __G__rabscher, is a XDCC download manager. Grabscher is the german word for grabber :-)

What makes it special? (I am already using and happy with xWeasel.)

XG is just a command line app which connects to one or multiple IRC networks and handles the whole communication. The IRC servers, channels, bots and packets are presented with a nice and stylish web frontend. There you can search and download packets of course.

You can run XG on every machine that supports c# / mono - even root servers without x(org), or an old weak pc running linux without a monitor - and control your downloads with your browser from everywhere. You don't have to keep your normal PC running, but just a small download box which handles all the IRC stuff.

A so called killer feature is the multiple download function. Every good XDCC client can resume and check downloads of course, but XG is able to download the same packet / file from different bots / sources. It will split downloads into multiple parts, download each part from a different bot and merge them back after error free downloading. Because of this you can use your maximum bandwidth.

How do i use it?

If you want to change the settings, create a file named settings.xml using the example. The settings file must be located in the folder where the binary Server.Cmd.exe lives. Change the XML file if you want, run the program and after that point your browser to 127.0.0.1:5556 or whatever you have just specified. The default password should be xgisgreat.

Password Dialog

Now you have to add IRC networks and channels. The bots and packets are generated and updated automatically. If you don't know which server and channels to add, try the integrated xg.bitpir.at search.

Server / Channel Dialog

If you click on a packet icon, XG will try to download it and keeps you up to date with updated packet informations.

Packet icon = Packet Icon

Settings

You should change the default settings and this explanation will help you. If you don't want to use a special feature, just disable or remove it.

<?xml version="1.0" encoding="utf-8"?>
<Settings xmlns: xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns: xsd="http://www.w3.org/2001/XMLSchema">
  <IrcNick>anon1234</IrcNick> <!-- the nickname of the IRC user -->
  <IrcPasswort>password123</IrcPasswort> <!-- nickserv password -->
  <IrcRegisterEmail>anon@ymous.org</IrcRegisterEmail> <!-- nickserv email -->
  <AutoRegisterNickserv>false</AutoRegisterNickserv> <!-- register nick if he does not exist -->
  <AutoJoinOnInvite>true</AutoJoinOnInvite> <!-- should xg join channels on invite -->

  <TempPath>/home/user/.config/XG/tmp/</TempPath> <!-- absolute folder of the temporary download folder -->
  <ReadyPath>/home/user/.config/XG/dl/</ReadyPath> <!-- absolute folder for ready downloads -->
  <EnableMultiDownloads>false</EnableMultiDownloads> <!-- enable multi bot dl feature -->
  <ClearReadyDownloads>false</ClearReadyDownloads> <!-- remove ready files from database -->

  <Password>xgisgreat</Password> <!-- server password -->

  <UseWebServer>true</UseWebServer> <!-- start the web server -->
  <WebServerPort>5556</WebServerPort> <!-- port of the web server -->

  <UseJabberClient>false</UseJabberClient> <!-- connect to the jabber server -->
  <JabberServer>jabber.org</JabberServer> <!-- server of the jabber user -->
  <JabberUser>user</JabberUser> <!-- name of the jabber user -->
  <JabberPassword>password</JabberPassword> <!-- password of the jabber user -->

  <FileHandlers></FileHandlers> <!-- commands to process ready downloads - see next chapter -->
</Settings>

Filehandlers

If a packet is downloaded you can run several commands. If the regex of a file handler matches the file name, the process is started. A process is defined by a command, arguments and the next process. The next process can be left empty and only is called if the current one is successfully executed.

The following handler matches all rar archives. It will create a separate folder, extract the archive into it, removes the archive and moves the folder onto a different partition. Every process is executed only, if the previous one was successfully. Because of this, the handler won't delete the archive if he could not extract it.

<FileHandler>
  <Regex>.*\.rar</Regex> <!-- match rar archives -->
  <Process>
    <Command>mkdir</Command> <!-- generate a separate folder -->
    <Arguments>%FOLDER%/%FILENAME%</Arguments>
    <Next>
      <Command>unrar</Command> <!-- unrar command with password skip! -->
      <Arguments>e -p- %PATH% %FOLDER%/%FILENAME%</Arguments>
      <Next>
        <Command>rm</Command> <!-- remove file -->
        <Arguments>%PATH%</Arguments>
        <Next>
          <Command>mv</Command> <!-- move to another partition -->
          <Arguments>%FOLDER%/%FILENAME% /media/data/%FILENAME%</Arguments>
        </Next>
      </Next>
    </Next>
  </Process>
</FileHandler>

Arguments

You can use different placeholders in your arguments:

  • %PATH% = full path of the file, like /the/full/path/to/file_complete.rar
  • %FOLDER% = full path of the folder of the file, like /the/full/path/to
  • %FILE% = the complete file name, like file_complete.rar
  • %FILENAME% = just the file name, like file_complete
  • %EXTENSION% = just the file extension, like rar

Examples

Just look at some more examples.

<FileHandlers>
  <FileHandler>
    <Regex>.*\.tar</Regex> <!-- match all tar archives -->
    <Process>
      <Command>mkdir</Command> <!-- generate a separate folder -->
      <Arguments>%FOLDER%/%FILENAME%</Arguments>
      <Next>
        <Command>tar</Command> <!-- untar -->
        <Arguments>-xf %PATH% -C %FOLDER%/%FILENAME%</Arguments>
        <Next>
          <Command>rm</Command> <!-- remove file -->
          <Arguments>%PATH%</Arguments>
          <Next>
            <Command>mv</Command> <!-- move to another partition -->
            <Arguments>%FOLDER%/%FILENAME% /media/data/%FILENAME%</Arguments>
          </Next>
        </Next>
      </Next>
    </Process>
  </FileHandler>
  <FileHandler>
    <Regex>.*\.[^tar]</Regex>
    <Process>
      <Command>mkdir</Command> <!-- generate a separate folder -->
      <Arguments>%FOLDER%/%FILENAME%</Arguments>
      <Next>
        <Command>mv</Command> <!-- move into folder -->
        <Arguments>%PATH% %FOLDER%/%FILENAME%/%FILE%</Arguments>
        <Next>
          <Command>mv</Command> <!-- move to another partition -->
          <Arguments>%FOLDER%/%FILENAME% /media/data/%FILENAME%</Arguments>
          <Next>
            <Command>send_email_command</Command> <!-- send email to notify -->
            <Arguments>"hello, you have a new download: /media/data/%FILENAME%"</Arguments>
          </Next>
        </Next>
      </Next>
    </Process>
  </FileHandler>
</FileHandlers>

Search for packets

You can search for packets by entering a custom search term and just clicking enter. Your search will be added to the search list and by clicking on one of these items the packet list will be updated.

Search List

The search items are working with the internal and external search and are saved into a file. So you can hassle-free store your favourite searches.

Extended Stats / Snapshots

XG will collect every 5 minutes some statistical data and generate nice graphs. There you can enable and disable different values to get an optimal view of your running XG copy.

Extend Statistic Dialog

This feature wont work in older browsers like the good old IE8, so do yourself a favour and use a newer one ;-)

Something went wrong with that request. Please try again.