Mercurial > hg > easyhg
comparison mainwindow.cpp @ 249:123e06d5d9af
* If the hgignore file doesn't exist when the user asks to edit it, create it with a "syntax: glob" line
author | Chris Cannam |
---|---|
date | Tue, 11 Jan 2011 17:56:22 +0000 |
parents | 011312e59e44 |
children | 0689dada1419 669f2a8ff1a8 |
comparison
equal
deleted
inserted
replaced
248:011312e59e44 | 249:123e06d5d9af |
---|---|
489 QString hgIgnorePath; | 489 QString hgIgnorePath; |
490 QStringList params; | 490 QStringList params; |
491 | 491 |
492 hgIgnorePath = workFolderPath; | 492 hgIgnorePath = workFolderPath; |
493 hgIgnorePath += "/.hgignore"; | 493 hgIgnorePath += "/.hgignore"; |
494 | |
495 if (!QDir(workFolderPath).exists()) return; | |
496 QFile f(hgIgnorePath); | |
497 if (!f.exists()) { | |
498 f.open(QFile::WriteOnly); | |
499 QTextStream *ts = new QTextStream(&f); | |
500 *ts << "syntax: glob\n"; | |
501 delete ts; | |
502 f.close(); | |
503 } | |
494 | 504 |
495 params << hgIgnorePath; | 505 params << hgIgnorePath; |
496 | 506 |
497 QString editor = getEditorBinaryName(); | 507 QString editor = getEditorBinaryName(); |
498 | 508 |