Difference between revisions of "Courses/Hybrid publishing resources"

From Publication Station
Line 51: Line 51:
[http://en.wikipedia.org/wiki/Wiki_markup Wiki markup]:
[http://en.wikipedia.org/wiki/Wiki_markup Wiki markup]:
<pre>
<pre>
= Revenge of the Text =
= Revenge of the Text =


Line 74: Line 75:
* a bit of nothing
* a bit of nothing
</pre>
</pre>
= pandoc =
[http://johnmacfarlane.net/pandoc '''pandoc''']: software for converting between markups with
http://johnmacfarlane.net/pandoc/diagram.png
= markup a text in MS Word/Libre Office/Open Office=
: styles; Test on WDKA
create a '''.docx''' file and mark it up with a few of the following paragraph and characters styles:
* headings
* body text
* block quotes: indented blocks of text
* footnotes
* hyperlinks
* Preformatted text
* Bold
* Italics
Save in '''.docx'''
= convert =
Convert your docx file into a an HTML file using Pandoc.
:shell
:Pandoc command
= convert once more, now to EPUB=
Can you instead of converting the .docx into HTML convert into an EPUB?
: clues
== Markdown ==
Markdown as the '''source file'''.
: link to Markdown syntax
Any plain text editor such as [http://www.sublimetext.com/ Sublime Text] or [https://wiki.gnome.org/Apps/Gedit Gedit] can be used to edit Markdown files. There are also WYSIWYG Markdown editors such as [http://macdown.uranusjr.com/ MacDown].
== Why Markdown ? ==
* only one way to create a structure 
* compatible with HTML, but easier to read and write
* allows the inclusion of HTML tags. E.g.  <pre><!-- an html comment -->  <span id="mrspan">a div</span></pre>
== convert once more, now to Markdown ==
: pandoc argument
== **** ==
== stream line: makefile ==
This same approach of converting between markups using Pandoc can be automated through scripts that execute the commands we have been writing in the terminal.
Ands since computers are good at doing repetitive and boring tasks, we can take advantage from it.
We can make them perform the same task on multiple source files, and make them produce multiple outputs (E.G. EPUB, ICML, HTML).
== makefile ==
My proposal involves using a makefile.
----
== IMCL ==
: to be edited
== Recipe Ingredients ==
* '''empty folder''' - to create the recipe
* '''content''' in a markup language: HTML (or wiki syntax)
* '''terminal''' - a text-based interface to your file system
* [http://johnmacfarlane.net/pandoc/installing.html '''pandoc'''] - markup converter software
* '''plain-text editor''': [http://www.sublimetext.com/ Sublime Text] or [https://wiki.gnome.org/Apps/Gedit Gedit]
* your favorite text layout software
== Testing the Recipe ==
== Testing the Recipe step#1 ==
In on empty folder in your computer save 1  BS article in '''HTML'''.
== Testing the Recipe step#2 ==
'''Convert that HTML file into an ICML file.'''
<pre>pandoc -f html -t icml -s input.html -o output.icml</pre>
'''pandoc''' - program dedicate to the conversion between different markups.
'''-f''' - option standing for “from”, is followed by the input format;
'''-t''' - option standing for “to”, is followed by the output format;
'''-s''' - option standing for “standalone”, produces output with an appropriate header and footer;
'''-o''' - option for file output;
'''input.html''' - html input filename - you need to replace it by its actual name
== Testing the Recipe step#3 ==
Open inDesign and ...
'''Place your output.icml in a inDesign project.'''
The Place function is in: File > Place (shortcut: Apple+D)
== Testing the Recipe step#4 ==
'''Style the content using paragraph and character styles. '''
Paragraph/Characters styles are in: Type > Paragraph/Character Styles
== Testing the Recipe step#5 ==
'''Content updates'''
Using Sublime Text, edit the source html file adding something or extracting something to it.
Repeat the whole recipe, so that you see the content being updated in inDesign.
== Recipe Warning ==
'''Content should remain untouched until the last moment'''
If you change the content of the articles inDesign, the link between the inDesign content and its source ICML file will be lost, and it no longer be able to be updated.
This "disconnection" should only be the last step to be done on your design workflow.
== Recipe Tips ==
'''Loading paragraph styles'''
==Recipe Questions==
'''Can CSS rules be imported and used as inDesign Paragraph/Character Styles ?'''
'''Can inDesign styles be exported as CSS style-sheets ?'''
'''+ ... ?'''
==software used==
* '''Shell terminal''' - a text-based interface to your file system. there are plenty of terminal tutorial online, here are some:
** http://mac.appstorm.net/how-to/utilities-how-to/how-to-use-terminal-the-basics/
** http://computers.tutsplus.com/tutorials/40-terminal-tips-and-tricks-you-never-thought-you-needed--mac-51192
** http://pzwart3.wdka.hro.nl/wiki/Null/Terminal
* [http://johnmacfarlane.net/pandoc/installing.html '''pandoc'''] - markup converter software
* '''plain-text editor''': [http://www.sublimetext.com/ Sublime Text] or [https://wiki.gnome.org/Apps/Gedit Gedit]

Revision as of 16:41, 11 March 2015

<slidy theme="a" />

publicationstation.wdka.hro.nl/wiki

Hybrid Publishing

Focus

Transforming a source (manuscript) into multiple publishable outputs

In a Hybrid Publishing Workflow

Hybrid Publishing Workflow

  1. various outcomes from one workflow
  2. constant connection between source-content and outcome
  3. avoiding repeating tasks

Hybrid Publishing Workflow

Hybrid-workflow.png

http://networkcultures.org/blog/publication/from-print-to-ebooks-a-hybrid-publishing-toolkit-for-the-arts/

EPUB trailer


How?

How can we achieve a publishing workflow where we can go from the source (a word document, a wiki page, a webpage) to several outputs (an EPUB, a website, an animated gif, an inDesign project)?

Structure

By putting the content into an explicit structure, which can withstand those transformations.

How to achieve explicit structure?

An explicit structure is achieved by marking the text with structural information.

marking the text = markup

Markup languages

HTML:

<h1>Revenge of the Text</h1>
 <p>There is a room in the <strong>Musée d’Orsay</strong> that I call the <em>room of possibilities</em>.</p>
 <p>That room contains:</p>
 <ul>
  <li>a snow flake</li>
  <li>the end of a cloud</li>
  <li>a bit of nothing</li>
 </ul>

Wiki markup:


= Revenge of the Text =

There is a room in the '''Musée d’Orsay''' that I call the ''room of possibilities''.

That room contains:

* a snow flake
* the end of a cloud
* a bit of nothing

Markdown:

# Revenge of the Text

There is a room in the **Musée d’Orsay** that I call the *room of possibilities*.

That room contains:

* a snow flake
* the end of a cloud
* a bit of nothing

pandoc

pandoc: software for converting between markups with

http://johnmacfarlane.net/pandoc/diagram.png

markup a text in MS Word/Libre Office/Open Office

styles; Test on WDKA

create a .docx file and mark it up with a few of the following paragraph and characters styles:

  • headings
  • body text
  • block quotes: indented blocks of text
  • footnotes
  • hyperlinks
  • Preformatted text
  • Bold
  • Italics

Save in .docx

convert

Convert your docx file into a an HTML file using Pandoc.

shell
Pandoc command

convert once more, now to EPUB

Can you instead of converting the .docx into HTML convert into an EPUB?

clues

Markdown

Markdown as the source file.

link to Markdown syntax

Any plain text editor such as Sublime Text or Gedit can be used to edit Markdown files. There are also WYSIWYG Markdown editors such as MacDown.

Why Markdown ?

  • only one way to create a structure
  • compatible with HTML, but easier to read and write
  • allows the inclusion of HTML tags. E.g.
    <!-- an html comment -->  <span id="mrspan">a div</span>

convert once more, now to Markdown

pandoc argument


****

stream line: makefile

This same approach of converting between markups using Pandoc can be automated through scripts that execute the commands we have been writing in the terminal.

Ands since computers are good at doing repetitive and boring tasks, we can take advantage from it.

We can make them perform the same task on multiple source files, and make them produce multiple outputs (E.G. EPUB, ICML, HTML).

makefile

My proposal involves using a makefile.




IMCL

to be edited

Recipe Ingredients

  • empty folder - to create the recipe
  • content in a markup language: HTML (or wiki syntax)
  • terminal - a text-based interface to your file system
  • pandoc - markup converter software
  • plain-text editor: Sublime Text or Gedit
  • your favorite text layout software

Testing the Recipe

Testing the Recipe step#1

In on empty folder in your computer save 1 BS article in HTML.

Testing the Recipe step#2

Convert that HTML file into an ICML file.

pandoc -f html -t icml -s input.html -o output.icml

pandoc - program dedicate to the conversion between different markups.

-f - option standing for “from”, is followed by the input format;

-t - option standing for “to”, is followed by the output format;

-s - option standing for “standalone”, produces output with an appropriate header and footer;

-o - option for file output;

input.html - html input filename - you need to replace it by its actual name

Testing the Recipe step#3

Open inDesign and ...

Place your output.icml in a inDesign project.

The Place function is in: File > Place (shortcut: Apple+D)

Testing the Recipe step#4

Style the content using paragraph and character styles.

Paragraph/Characters styles are in: Type > Paragraph/Character Styles


Testing the Recipe step#5

Content updates

Using Sublime Text, edit the source html file adding something or extracting something to it.

Repeat the whole recipe, so that you see the content being updated in inDesign.

Recipe Warning

Content should remain untouched until the last moment

If you change the content of the articles inDesign, the link between the inDesign content and its source ICML file will be lost, and it no longer be able to be updated.

This "disconnection" should only be the last step to be done on your design workflow.

Recipe Tips

Loading paragraph styles

Recipe Questions

Can CSS rules be imported and used as inDesign Paragraph/Character Styles ?

Can inDesign styles be exported as CSS style-sheets ?

+ ... ?





software used