]> git.mjollnir.org Git - cil.git/commitdiff
cil-d0b8bc09: All done
authorAndrew Chilton <andychilton@gmail.com>
Sat, 23 Jan 2010 12:42:59 +0000 (01:42 +1300)
committerAndrew Chilton <andychilton@gmail.com>
Sat, 23 Jan 2010 12:42:59 +0000 (01:42 +1300)
issues/c_5fe9eaea.cil [new file with mode: 0644]
issues/i_d0b8bc09.cil
lib/CIL.pm
lib/CIL/VCS/Git.pm

diff --git a/issues/c_5fe9eaea.cil b/issues/c_5fe9eaea.cil
new file mode 100644 (file)
index 0000000..4f42821
--- /dev/null
@@ -0,0 +1,6 @@
+Issue: d0b8bc09
+CreatedBy: Andrew Chilton <andychilton@gmail.com>
+Inserted: 2010-01-23T12:42:07
+Updated: 2010-01-23T12:42:17
+
+All tabs and whitespace formatting tidied-up.
index eea87591717b4b19ea3c9f42e109d4b7a4a2b74a..d42859450a96b04f807240b1cd23cda884798f4c 100644 (file)
@@ -1,9 +1,11 @@
 Summary: Tidy up CIL.pm (and others) of formatting
-Status: New
+Status: Finished
 CreatedBy: Andrew Chilton <andychilton@gmail.com>
 AssignedTo: Andrew Chilton <andychilton@gmail.com>
+Label: Milestone-v0.06
+Comment: 5fe9eaea
 Inserted: 2010-01-23T11:40:50
-Updated: 2010-01-23T11:41:50
+Updated: 2010-01-23T12:42:28
 
 This includes:
 
index b73de9119792ea1406f83c52c89fa20d86fe2859..b1274eb70a8c8beb2385362e0a4803eb247d129a 100644 (file)
@@ -89,7 +89,7 @@ sub new {
     # save the settings for various bits of info
     foreach my $key ( keys %$defaults ) {
         # if we have been passed it in, use it, else use the default
-        $self->$key( $cfg->{$key} || $defaults->{$key} ); 
+        $self->$key( $cfg->{$key} || $defaults->{$key} );
     }
     return $self;
 }
@@ -360,7 +360,7 @@ sub file_exists {
 sub dir_exists {
     my ($self, $dir) = @_;
 
-    return $self->vcs_revision 
+    return $self->vcs_revision
             ? $self->vcs->dir_exists($self->vcs_revision, $dir)
             : -d $dir
             ;
@@ -370,22 +370,22 @@ 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);
+        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);
+        CIL::Utils->parse_cil_file($filename, $last_field);
     }
 }
 
 sub save {
-    my ($self, $filename, $data, @fields) = @_;        
+    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 );
+        CIL::Utils->write_cil_file( $filename, $data, @fields );
     }
 }
 
index a6013245b09fc08795f1e0585d2e67d44f52b518..c082bc43b8ad7f51515022555204f6d0e64144ad 100644 (file)
@@ -51,7 +51,7 @@ sub glob_rev {
 
     # only support globbing the last element
     my ($dir, $pattern) = $path =~ m{^([^\*]*/)([^/]*)$}
-           or croak "unsupported pattern '$path'";
+        or croak "unsupported pattern '$path'";
     $pattern =~ s{([\\\.])}{\\$1}g;
     $pattern =~ s{\*}{.*}g;
     my @match;
@@ -59,9 +59,9 @@ sub glob_rev {
     for ( $self->git->command("ls-tree", $rev, $dir) ) {
         chomp;
         my ($blobid, $path) = m{([0-9a-f]{40})\s+(.*)} or die;
-       if ( $path =~ m{^\Q$dir\E$pattern$} ) {
-           push @match, $path;
-       }
+        if ( $path =~ m{^\Q$dir\E$pattern$} ) {
+            push @match, $path;
+        }
     }
     @match;
 }