#include #include "JSystem/JFilesystem.hh" #include "Jeep/JParser.hh" /** * \file * * Rename file. * * \author mdejong */ int main(int argc, char* argv[]) { using namespace std; using namespace JPP; string inputFile; string outputFile; try { JParser<> zap; zap['f'] = make_field(inputFile); zap['o'] = make_field(outputFile); zap(argc, argv); } catch(const exception& error) { FATAL(error.what() << endl); } const int ierr = rename(inputFile, outputFile); if (ierr != 0) { FATAL("Error renaming " << ierr << endl); } }