D23832: Backup on save: Support time and date string replacements

2019-09-11 Thread Dominik Haumann
This revision was automatically updated to reflect the committed changes. dhaumann marked 3 inline comments as done. Closed by commit R39:a32b79d9394a: Backup on save: Support time and date string replacements (authored by dhaumann). REPOSITORY R39 KTextEditor CHANGES SINCE LAST UPDATE https

D23832: Backup on save: Support time and date string replacements

2019-09-11 Thread Dominik Haumann
dhaumann updated this revision to Diff 65843. dhaumann added a comment. - Avoid running the backup when no backup prefix/suffix was provided REPOSITORY R39 KTextEditor CHANGES SINCE LAST UPDATE https://phabricator.kde.org/D23832?vs=65754&id=65843 BRANCH bug REVISION DETAIL https://p

D23832: Backup on save: Support time and date string replacements

2019-09-11 Thread Dominik Haumann
dhaumann added inline comments. INLINE COMMENTS > cullmann wrote in katedocument.cpp:2594 > Why not, saves useless evals. No: that's exactly the point: I currently don't think it's possible, but both evals could result in empty strings. Can you do the integration? Author does not matter. REPO

D23832: Backup on save: Support time and date string replacements

2019-09-11 Thread Christoph Cullmann
cullmann added inline comments. INLINE COMMENTS > dhaumann wrote in katedocument.cpp:2594 > Shall we wrap all this with > > if (!(backupSuffix.isEmpty() && backupPrefix.isEmpty())) {...} Why not, saves useless evals. REPOSITORY R39 KTextEditor BRANCH bug REVISION DETAIL https://phabr

D23832: Backup on save: Support time and date string replacements

2019-09-10 Thread Dominik Haumann
dhaumann added inline comments. INLINE COMMENTS > katedocument.cpp:2594 > +const auto backupSuffix = > KTextEditor::EditorPrivate::self()->variableExpansionManager()->expandText(config()->backupSuffix(), > nullptr); > +if (backupPrefix.contains(QDir::separator())) { > /** Shal

D23832: Backup on save: Support time and date string replacements

2019-09-10 Thread Christoph Cullmann
cullmann accepted this revision. cullmann added a comment. This revision is now accepted and ready to land. Looks fine. REPOSITORY R39 KTextEditor BRANCH bug REVISION DETAIL https://phabricator.kde.org/D23832 To: dhaumann, cullmann Cc: ngraham, kwrite-devel, kde-frameworks-devel, LeGa

D23832: Backup on save: Support time and date string replacements

2019-09-10 Thread Dominik Haumann
dhaumann retitled this revision from "Variable expansion: Prefer return value over return argument" to "Backup on save: Support time and date string replacements". dhaumann edited the summary of this revision. REPOSITORY R39 KTextEditor REVISION DETAIL https://phabricator.kde.org/D23832 To