Sync with External Folder and folders inside the project

Actually, I’m sure that what I’m thinking of is impossible at the moment (or forever). :slight_smile: Still, I’d like to ask.

As far as I can tell, “folders” inside a Scrivener project are actually just text files that are marked as “folders” by the app for displaying purposes. So, when using Sync with External Folder functionality these “folders” are synced as separate text files, just like the rest of them.

Is there maybe a way to sync them as actual folders, or at least to not sync them at all?

There is no specific setting for this.

Only method I can think of that might work is by enabling setting Sync only documents in this collection and only putting non-folders in the collection–but that sounds like it might be an arduous, maintenance-heavy approach. You’d have to research & test it to confirm.

What problem are you trying solve?

Best,
Jim

This works the way you describe. As in, it excludes everything that’s not included in the collection. Alas, there seems to be no way of organizing anything when syncing with external folder. Basically, if you add all text files to a single collection, it’s not much of a maintenance after that. Just have to remember to add new files to that collection, but that is done once, I suppose.

Trying to get external folder organized in a meaningful way for working outside Scrivener, because Android app is obviously not coming in my lifetime, and I was still not able to get Scrivener to run under WINE. :slight_smile:

If, for example, you have a project structured the way the Novel with Parts template suggests, you have folders for parts and chapters:
изображение

When this gets synced to an external folder, you get this:
изображение

All “folders” get synced as empty files (which they obviously are). This creates clutter.

I did these screenshots as an illustration. In my case it is not a multipart novel, but a collection of companion stories (“missing scenes”, side stories and such) to my novel, organized by character. So it’s much messier. :slight_smile:

It would’ve been perfect if folders from Scrivener were synced as actual folders, but I’m not sure if it’s at all possible, as they are obviously just text files which are only displayed with folder icons in Scrivener. And the way it is now it’s impossible to organize anything, because the whole project is dumped in a single folder as a set of files.

Okay. Will have to think of how to organize it at least visually via naming. :slight_smile:

Folders are empty only if you leave them empty. They can have text, snapshots, synopses, and everything else a text file can have. Differences between files and folders in Scrivener are only

  1. the default icon (but you can change it)
  2. default separator = page break, no page break for files

Separators can be changed on a section type by section type basis and the default can be changed as well. You could decide files should have page breaks and folders should not, for instance.

#2 may not be true at all, in some project templates.

All this is why folders can’t be special in the external sync feature. It might be nice to respect structure, but that’s a different topic entirely, since Scrivener folders can be changed to files or vice versa without changing the structure.

I know that. :slight_smile: Like I said, I realise full well that they are text files and not actual folders. Which makes sense inside Scrivener, but creates clutter when synced to an external folder. All your meaningful structure simply gets dumped into a single folder.

However, if there were, I don’t know, some secret checkbox that would allow to create actual folders out of Scrivener “folders” when syncing to an external folder… :grin:

You said of course they’d be empty, so I thought you might not know how it works. Are you looking for a feature that treats empty folders differently than those with text in them?

I didn’t say quite that. I said that they are exported as empty files, which they obviously are - meaning that they are obviously files, not that they are obviously empty (mine are, but other people might be using them differently in their workflows, and that’s the whole point of Scrivener, imo). I’ve probably put wrong accent in that sentence, and it changed the meaning. Sorry for this confusion, English is not my native language. :grin:

Basically yes, would’ve been perfect. A checkbox. There must be some tag or something under the hood, which tells Scrivener to treat it as a “folder”. Look for a file with such marking, check if it’s empty, and if the checkbox is, well, checked, export it as an honest to God folder, keeping the structure inside it. :slight_smile:

However, I think it must be difficult to implement. This sounds like a more elaborate algorithm, than what we have now. Right now Scrivener just takes existing rtf files and simply converts them to whatever. No complex export process or transformation happens. And most users can probably live without it, anyway. :slight_smile: But would’ve been nice to have it.

1 Like

Yes, probably in the Binder it says what kind of file it is and what icon to use, and in each Compile format it says what the default Separator is. Neither would be stored in the RTF, and the second isn’t a property of the document.

1 Like

This is sort of how Scrivener’s Export command currently works.

To test it, select the Draft/Manuscript folder in the Binder, then choose File > Export > Files.

Most Folders and Texts that are containers in the Binder remain containers in the Export, retaining their subdocuments–although oddly enough, the Draft folder did not in my test. Additionally, if a Folder has its own text, then a subdocument will be created with the Folder’s name to hold the text.

I just had a peek a the manual, and it seems a key design decision underlying Sync with External Folder is that it is only a content-based tool. Hence why it generates a flat list of files, rather than your preferred structured list of files in containers. See pages 301 and 306 of the manual.

Best,
Jim

Indeed, Export does exactly what I’d like to see. However, it is not something that can be used for ongoing work between two devices that are not Apple. Using export would mean having to start every writing session in Scrivener with importing files into a new project and ending it with exporting. And that will lose me all the organisational advantages of Scrivener (labels, tags, collections etc.) I don’t think that’s how this function is supposed to be used. :slight_smile:

I see. So, it’s deliberate. It doesn’t explain why, but I won’t ask. :slight_smile: It’s dangerous to ask the devs about their decisions. :slight_smile:

But then it means that external folder sync can only be used for unstructured projects only, which do not use folders/containers? Something simple. The manual suggests to “simply ignore” the “folder” files. Okay, that can be done, but what about the lost structure. :grin:

Well. The initial question was answered anyway. I suspected it wouldn’t work the convenient way, and you confirmed it. I will have to think of some naming scheme to imitate the unsyncable folder structure, or else I’ll drown. :laughing:

Thank you everyone who took their time to respond, I do appreciate it. :slight_smile:

I don’t think I follow you here. Sync with External Folder imposes no limitation on the binder, only on the files in the External Folder.

You can structure your Binder to whatever depths and levels you like, and the Sync with External Folder process will flatten this structure when it outputs it to the External Folder. You use your third party app to navigate the flattened structure and update docs as necessary, Then, the next time you launch Scrivener, SwEF will apply your updates back into Scrivener’s structure, and you’re good to go.

I haven’t used an external app myself with SwEF–instead, I utilize it as an alternate form of backup–but many posters here have used it successfully.

Best,
Jim

Part of the issue with External Folder Sync is that Scrivener has no way of knowing what the destination software can do. Based on what people post here, quite often the destination is a fairly limited editor on a fairly limited platform. Scrivener can’t assume that the destination will have a Finder-equivalent, much less anything comparable to the Binder.

Then in the opposite direction, remember that the structure in Scrivener is entirely based on text files. So if the user creates a “real” folder – which is a file system object with a specific meaning – how is Scrivener supposed to handle that when it re-syncs?

1 Like

I have explained it in my second message (which was a response to you, btw). :slight_smile:

I know what I can do in Scrivener. What I want is to be able to comfortably work outside of it when there is need, because I don’t have permanent access to a Windows machine with Scrivener installed (although I have purchased the license in the end to support development). My main workstation is Linux. My tablet is Android. I have been advised that sync to external folder would be a solution. And it kind of is, except it’s creating clutter.

At the moment I don’t see any way out other than give the files in the Binder special names that would imitate the folder structure when synced. I will definitely hate doing that, because Binder doesn’t wrap filenames. However, there’s no choice, alas.

You got me intrigued. What platform(s) people use it on, that do(es) not have at least some sort of a file manager that can handle directories?

Create a text file and mark it as a “folder”? I don’t know if it’s possible, but sounds rather logical. If it can create actual folders when exporting, then it must be familiar with the concept. :slight_smile:

In any case, thanks. :slight_smile: No is a no, I get it. :slight_smile: It’s okay. You don’t have to justify anything. This is a unique feature as it is.

Not sure what usecase you had in mind when developing this sync, though. It does look very interesting. Probably was supposed to be used to sync only parts and not whole projects, as it does good job syncing collections. When testing it I only ran into a problem once, and that was most probably my own user error.

Ah, I see, thanks for clarifying.

I guess the flattened structure must really bug you. :pouting_cat:

As opposed to completely restructuring and renaming your entire Binder, why not give it a try “as is” for, say, a month. Maybe you’ll get used to navigating the flat structure in your external app and save yourself all that trouble.

And if you find you just can’t work it, then delete or rename your current External Sync Folder, rename/restructure your Binder items, and resync.

Whatever you decide to do, I wish you the best and hope you find a solution that works for you, so you can get on with the more important task of writing. :smiley:

Jim

1 Like

Sync with External Folder is primarily intended for phones, tablets, and so on. Especially when it was first conceived – before iOS Scrivener existed – those platforms typically had very limited editors and file systems.

If Linux is your primary system, you might want to look at our Linux forum. It’s not officially supported, but a number of people seem to have good luck running Windows Scrivener under WINE.

Even back in 2006, when I had a flip Samsung phone with physical buttons, it could work with folders. :slight_smile: Writing on that tiny thing was another question entirely, but still. Folders were not a problem. Now in year 2021 I’d like to use it with a 10" tablet, which definitely can work with folders via various file managers widely available. But… :grin:

I looked, I tried, I failed. I’m not on a debian based distro, which makes it a bit more tricky, community experience wise. Although I’m pretty sure it can be resolved eventually, if I spend enough hours on it, but I don’t have the required energy now. A writing suite is supposed to assist me, not get in my way. This time would be better spent actually writing. :slight_smile:

I wish that sync function could do what I need it to do, but it can’t. No actual folders, or maybe multiple collections to work around that. Still it’s not the end of the world. :slight_smile: I will plan differently in future. Maybe develop the structure, scene by scene, in Scrivener (it’s great for planning and seeing the whole picture), and then do actual writing in a markdown editor. There are ways, I’ll think of something. It’s not quite a dead end. It’s okay. :slight_smile:

I use Sync with External Folder as part of my regular work flow, opening the rtfs in Word where I can use macros and other tools Scrivener doesn’t have. I initially also thought it would be useful if Scriv’s sync replicated the binder structure when it syncs to disk. Intuitively it makes sense that it would work that way (and Export apparently does.) But in practice, at least for the way I use sync, the flat structure works very nicely and has advantages, all based in simplicity.

Let’s say in Scrivener I’m working on a few different documents, moving between them, each located in a different section and subsection of the binder, front, back, throughout. In Scrivener, I can access these docs through the binder and work with them as a single scrivening, or bring them together as a collection, or etc. When I export to my sync folders, and sort them by descending date in Windows Explorer, those files are all right at the top of the list, ready to be opened in Word. If instead Scriv’s sync had mirrored the binder structure, I’d have to find all of those files in a complicated folder structure, which kind of defeats one of Scrivener’s purposes.

When Scriv copies the files to the sync folder, they retain their last-edited dates, so sorting this way is perfect for my purposes. I have the option to “prefix file names with numbers” disabled, as I found it visually cluttering. But with that enabled, if you sort by name, you would have the Scriv binder structure and top to bottom order reproduced inside a single Explorer window. In that case, the textless docs representing binder folders would become useful as virtual folders when reading the list. But that flat list still seems preferable and more immediately useable to me than creating the actual folder structure. That kind of document management is what I use Scrivener for. I only need sync to do things Scrivener can’t. I don’t ask it to do a lot, cos it can be finicky and temperamental. I wish they’d improve it in various ways. But using it within the limits I do, I’m happy it’s there.

I would actually like the option to make it even flatter, with the Drafts and Notes folders combined into one flat pool.

To answer both questions: the use case as I understand it is

  • a 3rd-party app edits the project – the whole project
  • with no file manager involved, just the 3rd-party app

No. The documents are exported as separate RTF (or text) documents in a flat external folder so that an external editor (such as an RTF editor on an Android device) can be used to modify the contents. Each component file is separate, precisely so other programs that don’t understand Scrivener’s project format can be used.

That’s an option, but it’s not the case I’ve heard of most often. Then again, I wasn’t paying much attention and never thought it was a good idea.