MCPcopy Create free account
hub / github.com/YACReader/yacreader / createLibrary

Function createLibrary

YACReaderLibraryServer/main.cpp:274–292  ·  view source on GitHub ↗

----------------------------------------------------------------------------- create-library--------------------------------------------------------------- -----------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

272// create-library---------------------------------------------------------------
273// -----------------------------------------------------------------------------
274int createLibrary(QCoreApplication &app, QCommandLineParser &parser, QSettings *settings)
275{
276 parser.clearPositionalArguments();
277 parser.addPositionalArgument("create-library", "Creates a library named \"name\" in the specified destination <path>");
278 parser.addPositionalArgument("name", "Library name", "\"name\"");
279 parser.addPositionalArgument("path", "Path to the folder where the library will be created", "<path>");
280 parser.process(app);
281
282 const QStringList args = parser.positionalArguments();
283 if (args.length() != 3) {
284 parser.showHelp(1);
285 return 1;
286 }
287
288 ConsoleUILibraryCreator *libraryCreatorUI = new ConsoleUILibraryCreator(settings);
289 libraryCreatorUI->createLibrary(args.at(1), args.at(2));
290
291 return 0;
292}
293
294// -----------------------------------------------------------------------------
295// update-library---------------------------------------------------------------

Callers 1

mainFunction · 0.85

Calls 2

processMethod · 0.45
createLibraryMethod · 0.45

Tested by

no test coverage detected