Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //liedtitel
- system( "grep -o \"number [0-9]\\{1,\\} on\" track_number.txt | grep -o -e \"[0-9]\\{1,\\}\" > tracknr.txt");
- QFile txttitelzahl("/home/Daniel/QtExamples/parsertest/parsertest-build-desktop/tracknr.txt");
- txttitelzahl.open(QIODevice::ReadOnly);
- if(txttitelzahl.isOpen())
- {
- qDebug() << "Ausgabe: file geöffnet!";
- }
- QString titelzahl = txttitelzahl.readAll();
- titelzahl.replace(" ","");
- QString stringtitelzahl = "\"Track "+ titelzahl +"\" ";
- stringtitelzahl.replace(QString("\n"), QString(" "));
- txttitelzahl.close();
- qDebug() << "Ausgabe: stringtitelanzahl:" << stringtitelzahl;
- qDebug() << "Ausgabe: file geschlossen!";
- //test1
- QString s1 = "grep -A 1 ";
- qDebug() << "Ausgabe: s1:" << s1;
- QString s2 = "tracks.txt > ergebnis.txt";
- qDebug() << "Ausgabe: s2:" << s2;
- QString s3 = s1 + stringtitelzahl + s2;
- // s3.replace(QString("@"), QString("t"));
- qDebug() << "Ausgabe: s3:" << s3;
- const char* myChar = s3.toStdString().c_str();
- qDebug() << "Ausgabe: myChar:" << myChar;
- system(myChar);
Add Comment
Please, Sign In to add comment