Removed upstream dir
[maemian] / minimae
diff --git a/minimae b/minimae
index 26721b6..19dc060 100755 (executable)
--- a/minimae
+++ b/minimae
@@ -26,6 +26,9 @@ ascertain who uploaded it, and if they used the correct email address.
     # Check a debian description file
     minimae -i file.dsc
 
+    # Check a binary .deb
+    minimae -b package_name.deb
+
 =cut
 
 use strict;
@@ -40,19 +43,31 @@ use Maemian::Schedule;
 my $LINTIAN_LAB = "/home/jeremiah/maemian/lab";
 
 # --- Command line options
-my $inputfile;                     # --- A file passed on the command line
-my ($help, $verbose);
+my $pkg_mode = 'a';            # auto -- automatically search for
+                               # binary and source pkgs
+my $inputfile;                  # --- A file passed on the command line
+my ($help, $verbose, );
 
 GetOptions
   (
    'help' => \$help,
    'verbose' => \$verbose,
    'inputfile|i=s' => \$inputfile,
+   'binary|b' => \&record_pkgmode,
   );
 
+# Record what type of data is specified
+# Options: -b|--binary, -s|--source, --udeb
+sub record_pkgmode {
+  print "in record_pkgmode\n";
+  $pkg_mode = 'b' if $_[0] eq 'binary';
+  $pkg_mode = 's' if $_[0] eq 'source';
+  $pkg_mode = 'u' if $_[0] eq 'udeb';
+}
+
+
 # --- Process Command line options
-pod2usage() if $help;
-pod2usage() if not $inputfile;
+pod2usage(1) if $help;
 
 # --- Output settings
 my $out = new Maemian::Output;