[Sumover-dev] [svn commit] r4647 - vic/branches/cc/cc/tools
sumover-dev at cs.ucl.ac.uk
sumover-dev at cs.ucl.ac.uk
Thu Feb 25 14:52:26 GMT 2010
Author: soohyunc
Date: Thu Feb 25 14:52:26 2010
New Revision: 4647
Modified:
vic/branches/cc/cc/tools/asv.cc
Log:
this tool can now specify the output file name:
Usage: ./asv <desired output filename> <input file>
Modified: vic/branches/cc/cc/tools/asv.cc
==============================================================================
--- vic/branches/cc/cc/tools/asv.cc (original)
+++ vic/branches/cc/cc/tools/asv.cc Thu Feb 25 14:52:26 2010
@@ -45,11 +45,12 @@
int main (int argc, char *argv[]) {
if (argc < 2) {
- cout << "Usage: " << endl;
+ cout << "Usage: ./asv <desired output filename> <input file>" << endl;
exit (0);
}
- ifstream fin (argv[1]);
+ ifstream fin (argv[1]);
+ string option = argv[2];
ofstream fout;
// variables
@@ -60,7 +61,7 @@
if (fin.is_open()) {
// preparing for the output file
stringstream ss;
- ss << "seqno" << ".xg";
+ ss << option << ".xg";
fout.open(ss.str().c_str());
// get input file stream
More information about the Sumover-dev
mailing list