Small fixes
authorAndrew DeFaria <Andrew@DeFaria.com>
Wed, 10 May 2017 15:05:51 +0000 (08:05 -0700)
committerAndrew DeFaria <Andrew@DeFaria.com>
Wed, 10 May 2017 15:05:51 +0000 (08:05 -0700)
. Removed tabs from bigfile.pl
. Added interesting trick to gitconfig
. Fixed processaction.cgi. For some reason Debug was putting stuff out
before the header.
. Turned off quiet mode in sshconfig
. Added numbered to vimrc

bin/bigfiles.pl
maps/bin/processaction.cgi
rc/gitconfig
rc/sshconfig
rc/vimrc

index 1918de1..3c539c2 100755 (executable)
@@ -2,11 +2,11 @@
 ################################################################################
 #
 # File:         $RCSfile: bigfiles.pl,v $
-# Revision:    $Revision: 1.3 $
+# Revision:     $Revision: 1.3 $
 # Description:  Reports large files
 # Author:       Andrew@DeFaria.com
 # Created:      Mon May 24 09:09:24 PDT 1999
-# Modified:    $Date: 2011/04/18 05:15:29 $
+# Modified:     $Date: 2011/04/18 05:15:29 $
 # Language:     Perl
 #
 # (c) Copyright 2001, ClearSCM, Inc., all rights reserved
@@ -36,8 +36,8 @@ sub Usage {
 } # usage
 
 sub Bigfiles {
-  my $size     = shift;
-  my @dirs     = @_;
+  my $size = shift;
+  my @dirs = @_;
 
   my @files;
 
@@ -53,10 +53,11 @@ sub Bigfiles {
 
       #if (/\S+\s+\d+\s+(\S+)\s+(\d+).*\"\.\/(.*)\"/) {
       if (/\S+\s+\d+\s+(\S+)\s+\S+ \S+\s+(\d+)\s+\S+\s+\d+\s+\S+\s+(\S+)/){
-       $info {user}    = $1;
-       $info {filesize}        = $2;
-       $info {filename}        = $3;
-       push @files, \%info;
+        $info {user}     = $1;
+        $info {filesize} = $2;
+        $info {filename} = $3;
+
+        push @files, \%info;
       } # if
     } # foreach
   } # foreach
@@ -64,11 +65,11 @@ sub Bigfiles {
   return @files;
 } # Bigfiles
 
-my $lines              = defined $ENV {LINES} ? $ENV {LINES} :-24;
-my $top                        = $lines - 2;
-my $bytes_in_meg       = 1048576;
-my $block_size         = 512;
-my $size_in_meg                = 1;
+my $lines        = $ENV{LINES} || 24;
+my $top          = $lines - 2;
+my $bytes_in_meg = 1048576;
+my $block_size   = 512;
+my $size_in_meg  = 1;
 my %opts;
 
 my $result = GetOptions (
@@ -80,19 +81,20 @@ my $result = GetOptions (
   'size=i',
 );
 
-my @dirs = @ARGV ? @ARGV : ".";
-
+my @dirs = @ARGV || '.';
 my $size = $opts {size} ? $opts {size} * $bytes_in_meg / $block_size : 4096;
 
 # Now do the find
 verbose "Directory:\t$_"
-  foreach (@dirs);
-verbose "Size:\t\t$size_in_meg Meg ($size blocks)";
-verbose "Top:\t\t$top";
 
-my $head = $top ? "cat" : "head -$top";
+foreach (@dirs) {
+  verbose "Size:\t\t$size_in_meg Meg ($size blocks)";
+  verbose "Top:\t\t$top";
+
+  my $head = $top ? "cat" : "head -$top";
 
-my @files = Bigfiles $size, @dirs;
+  my @files = Bigfiles $size, @dirs;
+} # for each
 
 foreach (@files) {
   my %info = %{$_};
index 493020b..f5ef9c6 100755 (executable)
@@ -40,16 +40,12 @@ sub ReturnSequenceNbrs {
   my @names = param;
   my @sequence_nbrs;
 
-  Debug "Entered ReturnSequenceNbrs";
-
   foreach (@names) {
     if (/action(\d+)/) {
       push @sequence_nbrs, $1;
     } # if
   } # foreach
 
-  Debug "Returning sequence nbrs " . join ' ', @sequence_nbrs;
-
   return @sequence_nbrs;
 } # ReturnSequenceNbrs
 
index 8c4dc6b..2d54e48 100644 (file)
@@ -40,6 +40,7 @@
   type=cat-file -t
   dump=cat-file -p
   dlog=log --decorate
+  oldest-ancestor = !bash -c 'diff -u <(git rev-list --first-parent "${1:-master}") <(git rev-list --first-parent "${2:-HEAD}") | sed -ne \"s/^ //p\" | head -1' -
 
 [push]
   default = simple
index 2173b64..2928f2d 100644 (file)
@@ -1,7 +1,6 @@
 ForwardX11 yes
 ForwardX11Trusted yes
 StrictHostKeyChecking no
-Loglevel QUIET
 
 Host *
   ServerAliveInterval 300
index b8aafd5..654081a 100644 (file)
--- a/rc/vimrc
+++ b/rc/vimrc
@@ -8,3 +8,4 @@ set hlsearch
 set ff=unix
 colorscheme default
 map! \7f \b
+set number