How can I quickly save a version of my draft before embarking on major changes like sorting (which just messed up a draft I now have to rewrite). Note that undo command did not work
I am replying to myself. I will try to create an action using draft.saveVersion(); kindly recommended by @sylumer
Drafts should save versions automatically. I think this generally occurs when you navigate away after making modifications.
But to force one, a simple action is absolutely the way to go
I wrote my first action (save version) thanks (and only thanks) to your previous post.
I very much enjoy your scripts. Would you have any suggestion for someone with an IQ in the low Neanderthal range who would want to understand the basics of scripting to create actions ?
If all you want to do is a create a duplicate version of the draft in its current state ahead of editing, just long-press on the draft in the list until green circle with with cross appears. Drag it in the list, let go, and a duplicate will be created. Works on iPhone or iPad. No action required.
@TDK_SA90 - do you see there being a notable advantage to that approach over a version action?
Note that navigating away and back should version a draft that has been edited; which is the comparable non-action approach.
Only in the sense that at least I know I’ve got a backup. I must admit I’ve never really understood the basis by which versions get provoked into creation at a system level. I’ve happily edited and gone back to a draft and still found a version count of zero. Hence my “belt and braces,” approach. If an action can reliably invoke the creating of a version, then, yes, that’s great.
thank you for the info about a duplicate which in terms of workflow is different from a version but also useful.
Did you find it out by yourself or is all this in the manual ?
@agiletortoise - can you clarify what the criteria are for when Drafts should automatically instigate a backup of a draft?
Today for instance. Quite a few edits, in and out of a draft. No new version produced for 15 mins. Then, it resumes producing new versions on a minute by minute basis upon edit. That’s why I regard it as a ‘nice to have,’ rather than wholly reliable, as the versioning, in my experience, seems to be rather fitful.
I think this was probably a tip tweeted by Greg or in one of those rather long reviews of Drafts 5 available on interwebs.
Sounds like you have had significant issues with it in the past. Did you ever raise this as an issue with any of the releases? If not, I’d strongly recommend doing so. To date I’ve not had an issue with versioning, but most of my drafts content is fairly transient in nature, so versions aren’t a daily driver for me.
It’s not a major issue for me either, so have not flagged to support. It’s just a behaviour I’ve noticed. Syncing works fine and is rock-solid across my devices so that’s all I’m really concerned about. If I am making wholesale edits to a draft (not that often), I do the ‘drag and dupe’ just to ensure I know I’ve got a reference draft I can return to.
It’s probably something that could use an audit pass. Drafts tries not to create excessive versions. It generally should create one when you select a different draft, or end an editing session - but only if changes have been made.
There are some other triggers, like running actions, doing a find-replace, etc.
In reading through this thread, it strikes me that ‘New Draft After’ (in settings) in combination with ‘Focus Mode’ might have something to do with how often versioning happens? Especially if we’re staying within the specific word-usement structured by @TDK_SA90
If, in fact, you have ‘New Draft After’ set to 15 minutes, I would be interested to know. I have often wondered how these two settings work together since they are set aside in their own section in the settings.
As a side note to @lucas222,
I’m not sure, but it seems that maybe you did not get the answer you needed?
Drafts creates a version of your Draft frequently. To find these versions, look for the ‘information’ icon in the upper left (it is a lowercase letter ‘i’ inside a circle.) tap that, and in the list of information about that draft, you should see the word “versions” with a count of the number of versions that exist for that Draft:
I hope that helps, and that you can still recover the original version of that Draft you mention you had done such work on! To save an earlier version off to its own Draft, I would guess “select all” copy + paste would work the easiest, but I could be wrong, maybe that’s not even necessary?
thank you for your interesting comment.
I think that saving a version is too important to be left up to the system.
How can the app guess that I am in a critical stage of writing, or too many versions are generated. My solution was to create my own action associated with the Cmd-S shortcut, which consists of one line for which I must give @sylumer credit:
It works perfectly.
Glad you got what you needed!