One-click compile?

Is there any way to setup a one-click compile, so that I can write and write and write and hit a key command that will compile using a specific pre-setup format without any more user interaction to do it? just a quick and fast way to compile and export markdown version for example to the filesystem somewhere,

also pre-configured the destination too.

Well, it’s two clicks. Once you’ve set up all Compile Settings and saved it in your Compile Format, click Compile on the Main Toolbar and the Compile button in the Compile Overview window. The location saved to is one of those settings.

don’t you have to select which compile format to use from the main compile window before hitting that second compile button?

Two button clicks can be automated but if there is more stuff about then selecting the resulting format, which includes destination path, etc…then its more complicated…I’m not saying undoable untiL I try it…but not trivial

Also I noticed that Marked2, for example, is able to monitor a scriv file, determine when it has changed and even fire off some kind of compile, all from an external program…So there must be someway to control Scrivener just as Marked2 is doing.

For anyone who uses the wonderful automation tool, BetterTouchTool, set this up as a key binding, (I use hyper+b):

It calls up compile dialog, then selects the active [compile] button, then selects the active [export] button, then presses ⌘R as if the destination file already exists a confirm requestor comes up. BetterTouchTool can also do a cooler:

It can find images (i.e. buttons), then move the mouse to that position and click for you, but that works the same so I stuck to the simpler one…

The preset if you want to impor directly: exported_triggers.bttpreset.zip (1.5 KB)

https://folivora.ai

3 Likes

And what @nontroppo shows here is just one example. With apps like BTT you can automate (almost) everything you do every day with Scrivener. I can no longer imagine using my Mac and especially Scrivener without BTT. If you don’t know it yet, you might be a bit put off at first. It’s not necessary. It looks much more complicated than it actually is. You don’t need any special knowledge for apps like BTT. But it contributes so much to designing your own workflow the way you want it.

2 Likes

The last saved Compile Format will be used. The location to save to is part of the Compile Format.

An AutoHotKey-script of a few lines will execute those two clicks with one Keystroke. :wink:

On Windows, does it ask you if you want to replace the existing file? @Dewdman42 refers to Marked2… is that available for Windows? Just asking.

AutoHotkey is Windows, Keyboard Maestro and Better Toucg Tool are Mac; @Dewdman42 doesn’t say which platform he uses.

:smiley:

Mark

2 Likes

Dewdman42 is on MacOs and iOS. I already have keyboard maestro, if I go down that road. I have more or less already decided that Scrivener is not the right tool for this task, will probably use Obsidian. still researching. Appreciate all the suggestions for how to shoe horn Scrivener into the task, but Obsidian is simply a much closer fit for blog/article jekyll posting.

I think Scrivener is still king of the hill for putting together longer form documents.

Though one case that can be made strongly for using Scrivener, is that I don’t really like the idea of spending many hundred of hours writing blog site content over the next few years where the content is in hard coded markdown files sitting on github or something. I mean that will work and it’s very simple and straightforward, but the actual writing content is buried undernearth a lot of technical website stuff that way.

I do like the idea of separating the writing from the formatting. With Scrivener I can write the actual works, the words with pictures and structure…in a very solid base form that is not the final format, but is clearly the core writing content. Then with compile I can compile all the markdown into it for whatever website system i happen to be using. For now it will be jekyll, but later that could easily change.

So I could see a huge benefit to using Scrivener after all, but also there is a lot of initial overhead for me to learn the compiler, setup the right set of styles to represent my various block elements that will need markdown added to them. Also I have to figure out this challenge related to both one-click compile as well as compile into multiple md files rather then a single long form document.

But once I do that and setup my scrivener template, I think it would be a nice way to work in terms of the writing experience, getting my ideas written down.

Many people like markdown for exactly that reason it’s very very simple…you don’t sit there trying to format it all day, you just use the rather limited markdown paradigm and write it. That’s great exactly I don’t really love having my core writing saved with hard coded markdown in it. So that is exactly where Scriveners compiler would really shine, despite all the technical overhead of learning the compiler and setting up just the right scrivener template for this use case.