HOW TO distribute your own templates and script formats

User avatar
KB
Site Admin
Posts: 19190
Joined: Tue Jun 13, 2006 11:23 pm
Platform: Mac
Location: Truro, Cornwall
Contact:

Tue Jul 24, 2007 6:08 pm Post

Hello,

As many of you know, for some time now Scrivener has allowed you to save export settings and create project templates. As of the 1.1 betas, you have also been able to create your own script format templates. Up until now, to get these working, you have had to play around with stuff in the Application Support folder. As of 1.06b (the latest 1.1 beta), though, it is now much easier to distribute this sort of stuff to other users should you so wish.

First, a quick low-down on how these things work:

Project Templates
You can create your own project templates that new projects will be based on. You might want to do this, for instance, if you prefer to have the "Draft" folder entitled "Manuscript" and have several other root folders that you use for all projects. You might also have a couple of template documents (character sheets or whatever). Obviously, if you use this sort of thing in a lot of projects, it would be a pain to set this up every time by importing them into and/or creating them in a vanilla project. You might also want to do this if you have a certain window size you like, or certain view and full screen settings which you would like all new projects to start with.

To create a project template, you simply create a new project and then set it up how you would like other new projects to start off - by adding template documents, setting up the folder system how you want it, resizing the window, setting up the inspector and full screen how you want them to look for new projects and so forth. Then you just go to File > Save As Template... and choose a name and description for your template. Once saved, the template will appear in a list of templates whenever you go to File > New Project. You can make it the default template to use whenever creating a new project by selecting "Templates..." > "Select Current by Default" from the pop-up button in the New Project Assistant.

Export Settings
There are occasions when you may wish to use different export settings for the same project depending on why you are exporting or printing it. For instance, you may just wish to use Export Draft to print off all of the titles and synopses of your draft items in your favourite font. Or, you may wish to print off just the text with headers and page numbers in the font preferred by your editor. In these situations, it makes sense to be able to save and load certain export settings.

You do this by using the "Save" and "Load" buttons in the Export Draft sheet. If you click on "Save", you will be prompted to enter a name for your new saved settings. The settings currently used in the Export Draft sheet will be saved to file so that you can load them again later from any project. Note that because saved export settings can be used between projects, the list of documents to export and the header text are not saved. Only information that is not project-specific (font, element types to include etc) get saved. Clicking on "Load" allows you to choose from settings that have already been saved.

Script Formats
Earlier versions of Scrivener came with three types of script format built-in: Screenplay, Stageplay (UK) and Stageplay (US). As of Scrivener 1.1, only one format is built-in - Screenplay. But there is a new script settings panel (available via Text > Scriptwriting > Script Settings...) that allows you complete customisation of the format so that you can create your own script formats - for stageplays, comic scripts or whatever you want. (The old Stageplay (UK & US) formats now come as separate files that have to be installed separately, so they are still available.)

To create your own script format, just play with the Script Settings panel until you have something you like. Note this is a one-shot thing Scrivener recognises the different elements of a script by their formatting. So once you have set up a script format, if you use it to write a script and then go back and change the script format using the Script Settings panel, Scrivener will no longer recognise the formatting of the text you have already created as anything other than "General Text". This is because it no longer matches the format you have defined in your script format settings.

Once you have created a script format you like, by default it will be stored inside your project (.scriv file). Its name will appear at the top of the Scripwriting menu as a toggle (that is, it will have a tick next to it when it is in use). By default, it will not be available in other projects. Obviously, in most cases you will want to use any script formats you create with other projects. To do this, in the Script Settings panel, click on the "Manage..." pop-up button and select "Save for use with other projects". You will be prompted to enter a file name.

SHARING YOUR TEMPLATES AND SETTINGS
Okay, so that's how to save all of these settings for use on your own computer with other projects. But what if you want to share them with other users - or even just get them onto another computer of your own?

At the moment, they all reside in subdirectories of the ~/Library/Application Support/Scrivener folder. So the first thing you need to do is to save them out to somewhere a little less arcane. The next thing you need to do is provide a way for users to install them. They could just copy them into their Application Support folder themselves, but this isn't exactly user-friendly. Fortunately, as of 1.1, there is a better way. Here's how.

1. Create folders to hold the files
First, you need to create a folder for each type of file that you want to share:

If you want to share project templates, create a folder entitled ProjectTemplates (note that it is important that the name is exactly as it appears here, with capital letters in the right place and no space between the words).

If you want to share export settings, create a folder entitled ExportSettings.

If you want to share script formats, create a folder entitled ScriptFormats.

Depending on what you are sharing, then, you should have between one and three folders set up ready to hold your files.

2. Save out the files to the new folders
To save out project templates, go to File > New Project and select the template that you wish to share. From the "Templates..." pop-up button, select "Export Template...". Save the template into the "ProjectTemplates" folder you just created. Do this for all templates you wish to share. (NOTE: be careful not to save any templates with names that are in use by the templates that come with Scrivener 1.1's Extras Installer.)

To save out export settings, go to File > Export > Draft... and click on "Load...". From the list, choose the setting that you wish to share and click on "Export...". Save the setting into the "ExportSettings" folder that you created. Do this for all export settings that you wish to share.

To save out script formats, go to the Text > Scriptwriting menu and select the script format that you wish to share, so that it appears at the top of the Scriptwriting menu with a tick next to it. Then go to Text > Scriptwriting > Script Settings... and select "Save to file..." from the "Manage..." pop-up button. Save the script format into the "ScriptFormats" folder that you created earlier. Do this for all script formats that you wish to share.

3. Set up the installer
As of the 1.06 beta, Scrivener 1.1 comes with an Extras Installer (its icon is the same as Scrivener's except with a blue arrow pointing down over it). This is used to install project templates, export settings and script formats that come with the program. But I designed the Extras Installer in such a way that you can easily modify it to install your own shared templates and settings. Here's how:

1) Copy the Extras Installer from off the Scrivener DMG to somewhere in the Finder and rename it to something you will remember (e.g. "John C's Scripts Installer" or some such).
2) In the finder, ctrl-click on your copy of the Extras Installer and select "Show Package Contents".
3) This will open a new Finder window displaying the contents of Extras Installer.app - a single folder entitled "Contents". Double-click on Contents to see its contents.
4) You will now see a few files and folders - double-click on the folder entitled "Resources".
5) More files and folders. Take note of the folder entitled "English.lproj", as we'll be coming back to that. For now though, double-click on the folder entitled "ExtrasToInstall".
6) You should be able to guess the next bit... See those three folders? They have exactly the same names as the ones you created earlier - ExportSettings, ProjectTemplates, ScriptFormats. Were you to open them, you would see the templates that come with Scrivener. What you need to do, though, is delete them and replace them with the three folders that you created earlier. If you didn't create three folders but only one or two, that's fine - delete the ones inside "ExtrasToInstall" and just copy in whichever folder(s) you created. It's perfectly okay if you are only sharing a few ScriptFormats - in that case, this folder would only contain a directory entitles "ScriptFormats", which would contain the script formats you want to share.
7) Now click on the "back" button in the Finder to take you back to the "Resources" folder, and this time double-click into the "English.lproj" folder that we took note of earlier. In there you will find a "Readme.rtf" file. Open it up in TextEdit and edit it to give details about the files you are sharing.

That's it! You can now close that Finder window, zip up your copy of the Extras Installer and share it on the Scrivener forums. Anybody who downloads it just has to unzip it and run the installer to install the settings, templates or formats that you wish to share.

That was an awful lot of text, but I think once you've done this once it should only take you five or ten minutes to set up an installer that will share several of your templates, script formats and export settings.

(The only thing to note is that users of versions of Scrivener prior to 1.06 should not use these installers, as the Application Support folders used by 1.06 and above have slightly different names to earlier versions of Scrivener, and the Extras Installer updates the folder names; so if a user of 1.055b or below runs an installer, 1.055b or below will no longer be able to find any of the settings.)

Whew! After all that, I really hope that this is of some use to someone, and that someone decides to share their settings and formats!

Best,
Keith

User avatar
west4east
Posts: 15
Joined: Mon Aug 18, 2014 1:14 am
Platform: Mac + Windows
Location: Beijing, China
Contact:

Sun Nov 30, 2014 12:52 pm Post

How big should the image that would represent a template be, in pixels?
Cordially,
Abel Kay
http://wps.abelakay.com

User avatar
AmberV
Posts: 20612
Joined: Sun Jun 18, 2006 4:30 am
Platform: Mac + Linux
Location: Santiago de Compostela, Galiza
Contact:

Mon Dec 01, 2014 9:20 pm Post

The easiest thing to do would be to use the Save Icon as File... button in the template save dialogue. So for example you can select Generic Text or Blank, and then save the file so you can edit it in your graphics program. I would suggest changing the format to PNG for best quality.

It is 128 x 128 pixels, though. :)
.:.
Ioa Petra'ka
“Whole sight, or all the rest is desolation.” —John Fowles

Te
Tenri68
Posts: 1
Joined: Mon Aug 29, 2016 6:27 pm
Platform: Windows

Mon Aug 29, 2016 7:09 pm Post

The questions is where i go upload RSS.