ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/COMP/JOBROBOT/generateDBSDLSQueryAsciiFile.pl
Revision: 1.1
Committed: Mon Nov 6 01:14:01 2006 UTC (18 years, 5 months ago) by gutsche
Content type: application/x-perl
Branch: MAIN
CVS Tags: HEAD
Log Message:
added possibility to read in ascii file of DBS/DLS discovery, provided script to generate ascii file for given pattern

File Contents

# User Rev Content
1 gutsche 1.1 #!/usr/bin/env perl
2    
3     #
4     # script which generates DBS/DLS query ascii file for pattern given as first command line argument
5     #
6     # prerequisites: setup local CMSSW project and eval `scramv1 runtime -(c)sh` an setup crab
7     #
8     # creates file: dlsdls_query_$cleaned_pattern.txt
9     # where cleaned pattern is the pattern with / replaced by _
10     #
11     # to be executed in JOBROBOT directory
12     #
13     my $pattern = $ARGV[0];
14     my $cleaned_pattern = $pattern;
15     $cleaned_pattern =~ s/\//_/g;
16     my $patternfile = "dbsdls_query_" . $cleaned_pattern . ".txt";
17     print "Execute DBS/DLS discovery for pattern: $pattern and save it in file: $patternfile\n";
18     my $cmd = "python DBSDLSQuery.py --pattern \"$pattern\" > $patternfile";
19     system($cmd);