rarslave2.git
13 years ago[RARSLAVE] Add porcelain
Ira W. Snyder [Wed, 27 Dec 2006 03:49:49 +0000 (19:49 -0800)]
[RARSLAVE] Add porcelain

Add all of the user-level polish, such as the option parser, and all
related functions which are needed to implement its actions.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[CONFIG] Remove unneeded option
Ira W. Snyder [Wed, 27 Dec 2006 03:42:14 +0000 (19:42 -0800)]
[CONFIG] Remove unneeded option

Remove an unnecessary option from the RarslaveConfig class' default
options. Also, change the default loglevel to 0. (Fatal and Normal
messages only)

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[RARSLAVE] Add debug logging messages
Ira W. Snyder [Tue, 26 Dec 2006 22:41:09 +0000 (14:41 -0800)]
[RARSLAVE] Add debug logging messages

Add a couple of debug-level messages.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[LOGGER] Change inner workings (again)
Ira W. Snyder [Tue, 26 Dec 2006 21:37:23 +0000 (13:37 -0800)]
[LOGGER] Change inner workings (again)

Change the inner workings of the RarslaveLogger class so that it has
four different message types: Fatal, Normal, Verbose, Debug. This also
adds the function printLoglevel() to the RarslaveLogger class. It will
print all messages at a certain loglevel.

Also update the unit tests so that they behave with the current workings of
the RarslaveLogger class.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[RARSLAVE] Add logging messages
Ira W. Snyder [Tue, 26 Dec 2006 05:05:22 +0000 (21:05 -0800)]
[RARSLAVE] Add logging messages

Adds a lot of logging messages. Also audited (and added) many error return
values, as well as missing success paths.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[RARSLAVE] Remove id requirement from RarslaveLogger
Ira W. Snyder [Tue, 26 Dec 2006 03:51:34 +0000 (19:51 -0800)]
[RARSLAVE] Remove id requirement from RarslaveLogger

Remove the id requirement from RarslaveLogger. This reduces the class'
utility, but makes it much easier to use in the existing rarslave
infrastructure.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[RARSLAVE] Change RarslaveLogger operation
Ira W. Snyder [Mon, 25 Dec 2006 18:55:07 +0000 (10:55 -0800)]
[RARSLAVE] Change RarslaveLogger operation

Changes the RarslaveLogger class' method of operation to not require a
pre-generated id. Instead, it still requires an id, but keeps track of all
id's given to it.

This also removes the unit tests that tested the old behavior.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[CONFIG] Fix automatic absolutizing of directories
Ira W. Snyder [Wed, 27 Dec 2006 00:00:07 +0000 (16:00 -0800)]
[CONFIG] Fix automatic absolutizing of directories

Fix the automatic absolutizing of directories in the RarslaveConfig class.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[CONFIG] Automatically absolute-ize directories
Ira W. Snyder [Tue, 26 Dec 2006 23:52:57 +0000 (15:52 -0800)]
[CONFIG] Automatically absolute-ize directories

This patch makes the RarslaveConfig class automatically return the absolute
paths to directories, even though they are not stored in the config that
way.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[RARSLAVE] Config-ify rarslave
Ira W. Snyder [Tue, 26 Dec 2006 23:42:10 +0000 (15:42 -0800)]
[RARSLAVE] Config-ify rarslave

Have rarslave rely on the RarslaveConfig class for all of its configuration
needs, such as options, regexes, etc.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[CONFIG] Update RarslaveConfig for rarslave2
Ira W. Snyder [Tue, 26 Dec 2006 23:28:28 +0000 (15:28 -0800)]
[CONFIG] Update RarslaveConfig for rarslave2

Updates the RarslaveConfig class for rarslave2, removing things that were
only needed in the original rarslave, and adding new things that we need.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[CONFIG] Add RarslaveConfig class
Ira W. Snyder [Tue, 26 Dec 2006 22:43:55 +0000 (14:43 -0800)]
[CONFIG] Add RarslaveConfig class

Add the RarslaveConfig class, which is almost entirely imported from the
original rarslave program.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[RARSLAVE] Fix extraction
Ira W. Snyder [Tue, 26 Dec 2006 23:45:25 +0000 (15:45 -0800)]
[RARSLAVE] Fix extraction

Important bugfix. If the extraction directory is None, then we can safely
assume that we just don't want to do anything but a default extraction, not
outputting the files anywhere special.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[RARSLAVE] Fix directory switching
Ira W. Snyder [Tue, 26 Dec 2006 19:49:48 +0000 (11:49 -0800)]
[RARSLAVE] Fix directory switching

Important bugfix. This fixes the directory switching code in the
run_command() function. Without this fix, the directory never gets switched
as expected.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[RARSLAVE] Improve error handling
Ira W. Snyder [Mon, 25 Dec 2006 09:13:51 +0000 (01:13 -0800)]
[RARSLAVE] Improve error handling

Improve the error handling, mostly of the main operations that occur during
a program run (check, repair, join, extract, delete).

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[RARSLAVE] Improve deletion
Ira W. Snyder [Mon, 25 Dec 2006 08:21:23 +0000 (00:21 -0800)]
[RARSLAVE] Improve deletion

Improve the deletion capabilities. This has initial support for deleting
interactively as well.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[RARSLAVE] Add main program logic
Ira W. Snyder [Mon, 25 Dec 2006 04:56:05 +0000 (20:56 -0800)]
[RARSLAVE] Add main program logic

Add the main program logic to the PAR2Set class. This handles verifying,
repairing, joining, extraction, and deletion of the leftover files in the
PAR set.

This also converts over the main() code to use this function exclusively.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[RARSLAVE] Add PAR2 Parser
Ira W. Snyder [Mon, 25 Dec 2006 01:45:56 +0000 (17:45 -0800)]
[RARSLAVE] Add PAR2 Parser

Add the class par2parser which parses PAR2 files to extract the list of
files which are "protected" by them.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[RARSLAVE] Add PAR2Set class
Ira W. Snyder [Mon, 25 Dec 2006 01:39:24 +0000 (17:39 -0800)]
[RARSLAVE] Add PAR2Set class

Add the PAR2Set class, which is able to tell whether a parset is the same
as another set.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[RARSLAVE] Add repairer
Ira W. Snyder [Sun, 24 Dec 2006 20:33:36 +0000 (12:33 -0800)]
[RARSLAVE] Add repairer

Add the class RarslaveRepairer which will repair / join par sets.

Also, change the no-extract heads to return the files that are protected by
the rar set, so that they can be mv'd later.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years agoMerge with add-logger
Ira W. Snyder [Sun, 24 Dec 2006 03:14:22 +0000 (19:14 -0800)]
Merge with add-logger

13 years ago[RARSLAVE] Add extraction class
Ira W. Snyder [Sun, 24 Dec 2006 03:08:11 +0000 (19:08 -0800)]
[RARSLAVE] Add extraction class

Adds the RarslaveExtractor class which handles extraction of all types of
set supported by rarslave.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years ago[RARSLAVE] Add logging class
Ira W. Snyder [Sun, 24 Dec 2006 03:04:21 +0000 (19:04 -0800)]
[RARSLAVE] Add logging class

This adds the RarslaveLogger class, used for logging of messages on a
per-set basis. It also adds the support class RarslaveMessage, which is
used within RarslaveLogger.

Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
13 years agoInitial work on extraction.
Ira W. Snyder [Sat, 16 Dec 2006 21:19:03 +0000 (13:19 -0800)]
Initial work on extraction.

13 years agoAdd type detection code.
Ira W. Snyder [Sat, 16 Dec 2006 07:22:34 +0000 (23:22 -0800)]
Add type detection code.

13 years agoInitial commit of the rarslave project.
Ira W. Snyder [Sat, 16 Dec 2006 05:17:23 +0000 (21:17 -0800)]
Initial commit of the rarslave project.