IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 16301


Ignore:
Timestamp:
Feb 4, 2008, 6:57:10 PM (18 years ago)
Author:
eugene
Message:

parse the neb schema

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/DataStore/scripts/dsget

    r16178 r16301  
    33# Copyright (C) 2006-2008  Joshua Hoblitt
    44#
    5 # $Id: dsget,v 1.11 2008-01-22 20:54:45 jhoblitt Exp $
     5# $Id: dsget,v 1.12 2008-02-05 04:57:10 eugene Exp $
    66
    77use strict;
     
    1515use File::Temp ();
    1616use File::Basename qw( basename dirname );
     17use Nebulous::Util qw( parse_neb_key );
    1718
    1819use Getopt::Long qw( GetOptions :config auto_help auto_version gnu_getopt );
     
    3940) unless defined $uri and defined $filename;
    4041
     42# if --nebulous is specified, parse the nebulous name
     43my ($uriVolume, $uriFilename);
     44if ($nebulous) {
     45    ($uriVolume, $uriFilename) = parse_neb_key ($filename);
     46}   
     47
    4148# --volume implies --nebulous
    4249if ($volume) {
    4350    $nebulous ||=1;
    44 }
     51}
     52
     53# if ($uriVolume) {
     54#     print "uriVolume: $uriVolume\n";
     55# }
     56# if ($uriFilename) {
     57#     print "uriFilename: $uriFilename\n";
     58# }
     59
     60if ($volume and $uriVolume and ($volume ne $uriVolume)) {
     61    die "conflicting volume names specified";
     62}
     63
     64if ($uriVolume) { $volume = $uriVolume; }
     65if ($uriFilename) { $filename = $uriFilename; }
     66
     67# if ($volume) {
     68#     print "volume: $volume\n";
     69# } else {
     70#     print "volume undefined\n";
     71# }
     72# print "filename: $filename\n";
     73# if ($nebulous) {
     74#     print "using nebulous\n";
     75# }
    4576
    4677my %p = (
Note: See TracChangeset for help on using the changeset viewer.