Show mkdir.cc syntax highlighted
#include "boost/filesystem/operations.hpp"
#include "boost/filesystem/convenience.hpp"
#include "boost/filesystem/path.hpp"
#include <iostream>
using namespace std;
using namespace boost::filesystem;
int main()
{
path a("/tmp");
a /= "b";
a /= "c";
a /= "d";
cout << "creating " << a.native_directory_string() << endl;
try {
create_directories(a);
} catch(...) {
cerr << "Exception thrown" << endl;
}
return 0;
}
See more files for this project here