]> git.mjollnir.org Git - cil.git/commitdiff
cil-03c93e82: Removed all the VCS stuff we do not need
authorAndrew Chilton <andychilton@gmail.com>
Mon, 25 Jan 2010 09:55:40 +0000 (22:55 +1300)
committerAndrew Chilton <andychilton@gmail.com>
Mon, 25 Jan 2010 09:55:50 +0000 (22:55 +1300)
18 files changed:
.cil
bin/cil
issues/i_03c93e82.cil
lib/CIL.pm
lib/CIL/Command/Add.pm
lib/CIL/Command/Comment.pm
lib/CIL/Command/DependsOn.pm
lib/CIL/Command/Edit.pm
lib/CIL/Command/Init.pm
lib/CIL/Command/Label.pm
lib/CIL/Command/Precedes.pm
lib/CIL/Command/Status.pm
lib/CIL/Command/Steal.pm
lib/CIL/Command/Track.pm
lib/CIL/Command/Work.pm
lib/CIL/Git.pm [moved from lib/CIL/VCS/Git.pm with 89% similarity]
lib/CIL/VCS/Factory.pm [deleted file]
lib/CIL/VCS/Null.pm [deleted file]

diff --git a/.cil b/.cil
index cfe5edb22388e3b52470ec4e12dcd6e25333fc9b..b8e42db597bb0a4dff71ef5ea3e7aa1116437933 100644 (file)
--- a/.cil
+++ b/.cil
@@ -1,4 +1,5 @@
 VCS: Git
+UseGit: 1
 StatusStrict: 1
 StatusOpenList: New
 StatusOpenList: InProgress
diff --git a/bin/cil b/bin/cil
index 51d202b0eb096d4328c7bd523ff9304bcfbdbb99..766fb44aab732c2b3d763512df1c51c35db006fc 100755 (executable)
--- a/bin/cil
+++ b/bin/cil
@@ -117,7 +117,6 @@ my %BOOLEAN_ARGS = (
 
     $cil->read_config_user();
     $cil->read_config_file();
-    $cil->check_args($args);
 
     # add any hooks we want
     # none yet
@@ -381,7 +380,7 @@ may be declared multiple times:
 
 The C<.cil> file is fairly simple and an example can be seen here:
 
-    VCS: Git
+    UseGit: 1
     StatusStrict: 1
     StatusOpenList: New
     StatusOpenList: InProgress
@@ -395,12 +394,12 @@ The C<.cil> file is fairly simple and an example can be seen here:
 
 =over
 
-=item VCS
+=item UseGit
 
-Default: empty, Type: Enum(Git)
+Default: 0, Type: Boolean (0/1)
 
-Currently this option only supports Git. This enables you to use the 'track'
-command.
+Determines whether to use Git or not. Some features require Git though Cil is
+perfectly usable without.
 
 =item StatusStrict
 
index d4e3541c6a595d92f8c1448a6fed2d7febad81a1..c81a4da552bbc44d008a491ea715ff27cef24020 100644 (file)
@@ -1,10 +1,10 @@
 Summary: Remove the whole VCS.pm stuff, just have a Git.pm at the top level
-Status: New
+Status: Finished
 CreatedBy: Andrew Chilton <andychilton@gmail.com>
 AssignedTo: Andrew Chilton <andychilton@gmail.com>
 Label: Milestone-v0.07
 Inserted: 2010-01-24T10:17:18
-Updated: 2010-01-24T10:39:29
+Updated: 2010-01-25T09:55:05
 
 No-one is going to use cil with anything other than Git (well, maybe not using
 Git at all) so remove all the abstract stuff that isn't needed.
index 3a86f75b1321b2071ffba2cabab94f9b15536372..6250a333ee508f9aa7e5deae90e036e516d7e2b4 100644 (file)
@@ -26,7 +26,7 @@ use warnings;
 use Carp qw(croak confess);
 use File::Glob qw(:glob);
 use File::HomeDir;
-use Git;
+use CIL::Git;
 
 use vars qw( $VERSION );
 $VERSION = '0.5.1';
@@ -36,19 +36,16 @@ use Module::Pluggable
         search_path => [ 'CIL::Command' ],
         require     => 1;
 
-use CIL::VCS::Factory;
-
 use base qw(Class::Accessor);
 __PACKAGE__->mk_accessors(qw(
     IssueDir
     StatusStrict StatusAllowed StatusOpen StatusClosed
     LabelStrict LabelAllowed
     DefaultNewStatus
-    VCS
+    UseGit
     UserName UserEmail
     AutoAssignSelf
-    vcs hook
-    vcs_revision
+    git hook
 ));
 
 my $defaults = {
@@ -56,7 +53,7 @@ my $defaults = {
     StatusStrict     => 0,        # whether to complain if a status is invalid
     LabelStrict      => 0,        # whether to complain if a label is invalid
     DefaultNewStatus => 'New',    # What Status to use for new issues by default
-    VCS              => 'Null',   # don't do anything for VCS hooks
+    UseGit           => 0,        # don't do anything with Git
 };
 
 my @config_hashes = qw(StatusOpen StatusClosed LabelAllowed);
@@ -68,9 +65,6 @@ my $defaults_user = {
 };
 
 my $allowed = {
-    vcs => {
-        'Git' => 1,
-    },
     hook => {
         'issue_post_save' => 1,
     },
@@ -94,27 +88,17 @@ sub new {
     return $self;
 }
 
-#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
 sub command_names {
     return map { $_->name } $_[0]->commands;
 }
 
-#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
 sub list_entities {
     my ($self, $prefix, $base) = @_;
 
     $base = '' unless defined $base;
 
     my $globpath = $self->IssueDir . "/${prefix}_${base}*.cil";
-    my @filenames;
-    if ( $self->vcs_revision ) {
-        @filenames = $self->vcs->glob_rev($self->vcs_revision, $globpath);
-    }
-    else {
-        @filenames = bsd_glob($globpath);
-    }
+    my @filenames = bsd_glob($globpath);
 
     my @entities;
     foreach my $filename ( sort @filenames ) {
@@ -263,14 +247,13 @@ sub read_config_file {
     my $cfg;
     if ( -f $filename ) {
         $cfg = CIL::Utils->parse_cil_file( $filename );
+        %$cfg = (%$defaults, %$cfg);
     }
     else {
+        # set some defaults if we don't have a .cil file
         $cfg = $defaults;
     }
 
-    # set some defaults if we don't have any of these
-    %$cfg = (%$defaults, %$cfg);
-
     # for some things, make a hash out of them
     foreach my $hash_name ( @config_hashes ) {
         # if we have nothing in the cfg hash already, set it to empty and move on
@@ -293,6 +276,7 @@ sub read_config_file {
 
     # set each config item
     $self->IssueDir( $cfg->{IssueDir} );
+    $self->UseGit( $cfg->{UseGit} );
 
     # Status info
     $self->StatusStrict( $cfg->{StatusStrict} );
@@ -308,24 +292,13 @@ sub read_config_file {
 
     $self->DefaultNewStatus( $cfg->{DefaultNewStatus} );
 
-    # if we are allowed this VCS, create the hook instance
-    $self->VCS( $cfg->{VCS} || 'Null' );
-    my $vcs = CIL::VCS::Factory->new( $cfg->{VCS} );
-    $self->vcs( $vcs );
-}
-
-sub check_args {
-    my ($self, $args) = @_;
-
-    if ( $args->{r} ) {
-        $self->vcs_revision($args->{r});
-        if ( !$self->VCS or $self->VCS eq "Null" ) {
-            warn "No VCS set in config file!\n";
-        }
+    # create the git instance if we want it
+    $self->UseGit( $cfg->{UseGit} || 0 );
+    if ( $self->UseGit ) {
+        $self->git( CIL::Git->new() );
     }
 }
 
-
 sub register_hook {
     my ($self, $hook_name, $code) = @_;
 
@@ -353,44 +326,22 @@ sub run_hook {
 
 sub file_exists {
     my ($self, $filename) = @_;
-    if ( $self->vcs_revision ) {
-        $self->vcs->file_exists($self->vcs_revision, $filename);
-    }
-    else {
-        -f $filename;
-    }
+    return -f $filename;
 }
 
 sub dir_exists {
     my ($self, $dir) = @_;
-
-    return $self->vcs_revision
-            ? $self->vcs->dir_exists($self->vcs_revision, $dir)
-            : -d $dir
-            ;
+    return -d $dir;
 }
 
 sub parse_cil_file {
     my ($self, $filename, $last_field) = @_;
-
-    if ( $self->vcs_revision ) {
-        my $fh = $self->vcs->get_fh($self->vcs_revision, $filename);
-        CIL::Utils->parse_from_fh($fh, $last_field);
-    }
-    else {
-        CIL::Utils->parse_cil_file($filename, $last_field);
-    }
+    return CIL::Utils->parse_cil_file($filename, $last_field);
 }
 
 sub save {
     my ($self, $filename, $data, @fields) = @_;
-
-    if ( $self->vcs_revision ) {
-        confess "tried to ->save on alternate revision";
-    }
-    else {
-        CIL::Utils->write_cil_file( $filename, $data, @fields );
-    }
+    return CIL::Utils->write_cil_file( $filename, $data, @fields );
 }
 
 ## ----------------------------------------------------------------------------
index dd1b147e56f7e3bcd1e1beced85c11c309f45b1d..76b178500ceb51fe1fa9105f405197e37136509f 100644 (file)
@@ -47,14 +47,16 @@ sub run {
 
     $issue = CIL::Utils->add_issue_loop($cil, undef, $issue);
 
-    # if we want to add or commit this issue
-    if ( $args->{add} or $args->{commit} ) {
-        $cil->vcs->add( $cil, $issue );
-    }
+    if ( $cil->UseGit ) {
+        # if we want to add or commit this issue
+        if ( $args->{add} or $args->{commit} ) {
+            $cil->git->add( $cil, $issue );
+        }
 
-    # if we want to commit this issue
-    if ( $args->{commit} ) {
-        $cil->vcs->commit( $cil, 'New Issue', $issue );
+        # if we want to commit this issue
+        if ( $args->{commit} ) {
+            $cil->git->commit( $cil, 'New Issue', $issue );
+        }
     }
 }
 
index 38288f90fbcbf44e6f77b5749b5099364daa1d08..094298246c2a5b532311901fb0979493eee69d01 100644 (file)
@@ -45,15 +45,17 @@ sub run {
 
     $comment = CIL::Utils->add_comment_loop($cil, undef, $issue, $comment);
 
-    # if we want to add or commit this comment
-    if ( $args->{add} or $args->{commit} ) {
-        $cil->vcs->add( $cil, $issue );
-        $cil->vcs->add( $cil, $comment );
-    }
-
-    # if we want to commit this comment
-    if ( $args->{commit} ) {
-        $cil->vcs->commit( $cil, 'New Comment', $issue, $comment );
+    if ( $cil->UseGit ) {
+        # if we want to add or commit this comment
+        if ( $args->{add} or $args->{commit} ) {
+            $cil->git->add( $cil, $issue );
+            $cil->git->add( $cil, $comment );
+        }
+
+        # if we want to commit this comment
+        if ( $args->{commit} ) {
+            $cil->git->commit( $cil, 'New Comment', $issue, $comment );
+        }
     }
 }
 
index a3127874e70bf63af29a75562624f99e329fb7cd..1df5f198a2fdd57633dc847d52f9ceeea03c689b 100644 (file)
@@ -42,16 +42,18 @@ sub run {
     $issue->save($cil);
     $depends->save($cil);
 
-    # if we want to add or commit this change
-    if ( $args->{add} or $args->{commit} ) {
-        $cil->vcs->add( $cil, $issue );
-        $cil->vcs->add( $cil, $depends );
-    }
-
-    # if we want to commit this change
-    if ( $args->{commit} ) {
-        my $message = 'Issue ' . $issue->name . ' has a new dependent ' . $depends->name;
-        $cil->vcs->commit_multiple( $cil, $message, $issue, $depends );
+    if ( $cil->UseGit ) {
+        # if we want to add or commit this change
+        if ( $args->{add} or $args->{commit} ) {
+            $cil->git->add( $cil, $issue );
+            $cil->git->add( $cil, $depends );
+        }
+
+        # if we want to commit this change
+        if ( $args->{commit} ) {
+            my $message = 'Issue ' . $issue->name . ' has a new dependent ' . $depends->name;
+            $cil->git->commit_multiple( $cil, $message, $issue, $depends );
+        }
     }
 }
 
index db531491f27cf09787a3f1d7292930ccad618149..2f7a7e0aa2d84cc845acb67c87d10df1257d2f11 100644 (file)
@@ -65,14 +65,16 @@ sub run {
     # save it
     $issue->save($cil);
 
-    # if we want to add or commit this issue
-    if ( $args->{add} or $args->{commit} ) {
-        $cil->vcs->add( $cil, $issue );
-    }
+    if ( $cil->UseGit ) {
+        # if we want to add or commit this issue
+        if ( $args->{add} or $args->{commit} ) {
+            $cil->git->add( $cil, $issue );
+        }
 
-    # if we want to commit this issue
-    if ( $args->{commit} ) {
-        $cil->vcs->commit( $cil, 'Issue Edited', $issue );
+        # if we want to commit this issue
+        if ( $args->{commit} ) {
+            $cil->git->commit( $cil, 'Issue Edited', $issue );
+        }
     }
 
     CIL::Utils->display_issue($cil, $issue);
index 2823ab679b0c87831c22c7fb04eda6a0e168baf3..1bf92d5a647fac0a28d544e1f71751d80a5821e5 100644 (file)
@@ -59,11 +59,10 @@ sub run {
     }
 
     # are we in a Git repository?
-    my $VCSconfig = '';
+    my $use_git = 0;
     if ( -d '.git' ) {
-        CIL::Utils->msg( 'git repository detected, setting VCS accordingly' );
-        $VCSconfig = 'VCS: Git';
-        my $vcs = CIL::VCS::Factory->new( 'Git' );
+        CIL::Utils->msg( 'git repository detected, setting to use it' );
+        $use_git = 1;
     }
 
     # create a .cil file here also
@@ -76,7 +75,7 @@ sub run {
     else {
         # write a default .cil file
         write_file($config, <<"CONFIG");
-$VCSconfig
+UseGit: $use_git
 StatusStrict: 1
 StatusOpenList: New
 StatusOpenList: InProgress
index 8687185ae35b2d640041cd47a8cb83ebf2c17be0..d8da2c87b21e7dd104ba5abdc26e78d796dc0dc2 100644 (file)
@@ -55,21 +55,25 @@ sub run {
         # save
         $issue->save($cil);
 
-        # if we want to add or commit this issue
-        if ( $args->{add} or $args->{commit} ) {
-            $cil->vcs->add( $cil, $issue );
+        if ( $cil->UseGit ) {
+            # if we want to add or commit this issue
+            if ( $args->{add} or $args->{commit} ) {
+                $cil->git->add( $cil, $issue );
+            }
         }
 
         push @issues, $issue;
     }
 
-    # if we want to commit these issues
-    if ( $args->{commit} ) {
-        if ( $args->{remove} ) {
-            $cil->vcs->commit_multiple( $cil, "Removed label '$label'", @issues );
-        }
-        else {
-            $cil->vcs->commit_multiple( $cil, "Added label '$label'", @issues );
+    if ( $cil->UseGit ) {
+        # if we want to commit these issues
+        if ( $args->{commit} ) {
+            if ( $args->{remove} ) {
+                $cil->git->commit_multiple( $cil, "Removed label '$label'", @issues );
+            }
+            else {
+                $cil->git->commit_multiple( $cil, "Added label '$label'", @issues );
+            }
         }
     }
 }
index 42c42918063280ce1dc40cdbe7d6d19c1ed72e1d..0fdf12efed15ea950eb33c53e42dc4f37435f91c 100644 (file)
@@ -42,16 +42,18 @@ sub run {
     $issue->save($cil);
     $precedes->save($cil);
 
-    # if we want to add or commit this change
-    if ( $args->{add} or $args->{commit} ) {
-        $cil->vcs->add( $cil, $issue );
-        $cil->vcs->add( $cil, $precedes );
-    }
-
-    # if we want to commit this change
-    if ( $args->{commit} ) {
-        my $message = 'Issue ' . $issue->name . ' precedes ' . $precedes->name;
-        $cil->vcs->commit_multiple( $cil, $message, $issue, $precedes );
+    if ( $cil->UseGit ) {
+        # if we want to add or commit this change
+        if ( $args->{add} or $args->{commit} ) {
+            $cil->git->add( $cil, $issue );
+            $cil->git->add( $cil, $precedes );
+        }
+
+        # if we want to commit this change
+        if ( $args->{commit} ) {
+            my $message = 'Issue ' . $issue->name . ' precedes ' . $precedes->name;
+            $cil->git->commit_multiple( $cil, $message, $issue, $precedes );
+        }
     }
 }
 
index 23212efaee367d9252c5bd042752d89f0d147181..35fe88518ff905c850e38cb610faba0d269898e2 100644 (file)
@@ -49,16 +49,20 @@ sub run {
         $issue->save($cil);
 
         # if we want to add or commit this issue
-        if ( $args->{add} or $args->{commit} ) {
-            $cil->vcs->add( $cil, $issue );
+        if ( $cil->UseGit ) {
+            if ( $args->{add} or $args->{commit} ) {
+                $cil->git->add( $cil, $issue );
+            }
         }
 
         push @issues, $issue;
     }
 
-    # if we want to commit these issues
-    if ( $args->{commit} ) {
-        $cil->vcs->commit_multiple( $cil, "Status changed to '$status'", @issues );
+    if ( $cil->UseGit ) {
+        # if we want to commit these issues
+        if ( $args->{commit} ) {
+            $cil->git->commit_multiple( $cil, "Status changed to '$status'", @issues );
+        }
     }
 }
 
index e4d04f5d8512b1ab20f4af15ed399affaafcba82..641c5aeed144cbce344c9552bea0fd06e61ec3a2 100644 (file)
@@ -40,14 +40,16 @@ sub run {
     $issue->AssignedTo( CIL::Utils->user($cil) );
     $issue->save($cil);
 
-    # if we want to add or commit this issue
-    if ( $args->{add} or $args->{commit} ) {
-        $cil->vcs->add( $cil, $issue );
-    }
-
-    # if we want to commit this issue
-    if ( $args->{commit} ) {
-        $cil->vcs->commit( $cil, 'Issue Stolen', $issue );
+    if ( $cil->UseGit ) {
+        # if we want to add or commit this issue
+        if ( $args->{add} or $args->{commit} ) {
+            $cil->git->add( $cil, $issue );
+        }
+
+        # if we want to commit this issue
+        if ( $args->{commit} ) {
+            $cil->git->commit( $cil, 'Issue Stolen', $issue );
+        }
     }
 
     CIL::Utils->display_issue_full($cil, $issue);
index fe851b54155734ee15e0a4fabc44f27e8332bf55..ce2f879b9dd2a7b701c38872a762684b30ad2aeb 100644 (file)
@@ -33,11 +33,8 @@ sub name { 'track' }
 sub run {
     my ($self, $cil, undef, $issue_name) = @_;
 
-    CIL::Utils->fatal("the 'VCS' option in your .cil file is not set")
-        unless defined $cil->VCS;
-
-    CIL::Utils->fatal("the 'VCS' option currently only supports values of 'Git'")
-        unless $cil->VCS eq 'Git';
+    CIL::Utils->fatal("to use this feature the 'UseGit' option in your .cil file should be set")
+        unless $cil->UseGit;
 
     my $issue = CIL::Utils->load_issue_fuzzy($cil, $issue_name);
 
index 3a71c994e8a5be9a955f14bbd202ff3a4aa734cd..83f8d7cde073d2509ffd7fb3244464b895fd97dc 100644 (file)
@@ -34,21 +34,23 @@ sub name { 'work' }
 sub run {
     my ($self, $cil, $args, $issue_name) = @_;
 
+    CIL::Utils->fatal("to use this feature the 'UseGit' option in your .cil file should be set")
+        unless $cil->UseGit;
+
     # firstly, read the issue in
     my $issue = CIL::Utils->load_issue_fuzzy( $cil, $issue_name );
 
     # right, got it's name, let's see if there is a branch for it
-    use Data::Dumper;
-    my @branches = $cil->vcs->branches();
+    my @branches = $cil->git->branches();
     my $branch = {};
     foreach ( @branches ) {
         $branch->{substr $_, 2} = 1;
     }
     if ( exists $branch->{$issue->name} ) {
-        $cil->vcs->switch_to_branch( $issue->name );
+        $cil->git->switch_to_branch( $issue->name );
     }
     else {
-        $cil->vcs->create_branch( $issue->name );
+        $cil->git->create_branch( $issue->name );
     }
 
     # now that we've switched branches, load the issue in again (just in case)
similarity index 89%
rename from lib/CIL/VCS/Git.pm
rename to lib/CIL/Git.pm
index 091585bd17e2abacf5642c72ce764a3b7a0ce88f..1dec72061376b9b41cc6c3dede864dfc95379668 100644 (file)
 #
 ## ----------------------------------------------------------------------------
 
-package CIL::VCS::Git;
+package CIL::Git;
 
 use strict;
 use warnings;
 use Carp;
-
-use base qw(CIL::VCS::Factory);
-
-sub post_add {
-    my ($self, $issue) = @_;
-
-    my $issue_dir = $issue->cil->IssueDir();
-    my @files;
-    push @files, "$issue_dir/i_" . $issue->name . '.cil';
-    push @files, map { "$issue_dir/c_${_}.cil" } @{ $issue->CommentList };
-    push @files, map { "$issue_dir/a_${_}.cil" } @{ $issue->AttachmentList };
-
-    return [ "git add @files" ];
-}
-
 use Git;
 
+use base qw(Class::Accessor);
+
 sub git {
     my $self = shift;
     $self->{git} ||= Git->repository;
diff --git a/lib/CIL/VCS/Factory.pm b/lib/CIL/VCS/Factory.pm
deleted file mode 100644 (file)
index 52ac43e..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-## ----------------------------------------------------------------------------
-# cil is a Command line Issue List
-# Copyright (C) 2008 Andrew Chilton
-#
-# This file is part of 'cil'.
-#
-# cil is free software: you can redistribute it and/or modify it under the
-# terms of the GNU General Public License as published by the Free Software
-# Foundation, either version 3 of the License, or (at your option) any later
-# version.
-#
-# This program is distributed in the hope that it will be useful, but WITHOUT
-# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
-# FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
-# details.
-#
-# You should have received a copy of the GNU General Public License along with
-# this program.  If not, see <http://www.gnu.org/licenses/>.
-#
-## ----------------------------------------------------------------------------
-
-package CIL::VCS::Factory;
-
-use strict;
-use warnings;
-use Carp;
-
-use base qw( Class::Factory );
-
-__PACKAGE__->register_factory_type( Null => 'CIL::VCS::Null' );
-__PACKAGE__->register_factory_type( Git => 'CIL::VCS::Git' );
-
-foreach my $method_name ( qw(post_add glob_rev file_exists dir_exists get_fh) ) {
-    my $method = sub {
-        my ($self) = @_;
-        my $class = ref $self || $self;
-        die "Method '$method_name' not overriden in derived class '$class'";
-    };
-
-    no strict 'refs';
-    *{$method_name} = $method;
-}
-
-## ----------------------------------------------------------------------------
-1;
-## ----------------------------------------------------------------------------
diff --git a/lib/CIL/VCS/Null.pm b/lib/CIL/VCS/Null.pm
deleted file mode 100644 (file)
index c8c3dbf..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-## ----------------------------------------------------------------------------
-# cil is a Command line Issue List
-# Copyright (C) 2008 Andrew Chilton
-#
-# This file is part of 'cil'.
-#
-# cil is free software: you can redistribute it and/or modify it under the
-# terms of the GNU General Public License as published by the Free Software
-# Foundation, either version 3 of the License, or (at your option) any later
-# version.
-#
-# This program is distributed in the hope that it will be useful, but WITHOUT
-# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
-# FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
-# details.
-#
-# You should have received a copy of the GNU General Public License along with
-# this program.  If not, see <http://www.gnu.org/licenses/>.
-#
-## ----------------------------------------------------------------------------
-
-package CIL::VCS::Null;
-
-use strict;
-use warnings;
-use Carp;
-
-use base qw(CIL::VCS::Factory);
-
-foreach my $method_name ( qw(post_add) ) {
-    no strict 'refs';
-    *{"CIL::VCS::Null::$method_name"} = sub {};
-}
-
-foreach my $method_name ( qw(UserName UserEmail) ) {
-    no strict 'refs';
-    *{"CIL::VCS::Null::$method_name"} = sub { return ''; };
-}
-
-## ----------------------------------------------------------------------------
-1;
-## ----------------------------------------------------------------------------