all repos — hastyscribe @ e4135d2e366f57daf033134700793d75ee10bc78

A professional markdown compiler.

- Fixed incorrect syntax for configure.sh options.
- Allowing any file extension to be compiled.
(Closes #22 and #26)
h3rald h3rald@h3rald.com
Fri, 17 Oct 2014 22:33:14 +0200
commit

e4135d2e366f57daf033134700793d75ee10bc78

parent

20ebac21e5d074eaf97040c4bb91d2bfec296348

M doc/HastyScribe_UserGuide.htmdoc/HastyScribe_UserGuide.htm

@@ -256,7 +256,7 @@ <ol>

<li>Clone the discount <a href="https://github.com/Orc/discount">repository</a>.</li> <li><p>In the directory containing the Discount source code, run the following commands:</p> -<div class="terminal"><p>./configure.sh &ndash;with-tabstops=2 &ndash;with-dl=both &ndash;with-id-anchor &ndash;with-github-tags &ndash;with-fenced-code &ndash;enable-all-features</p> +<div class="terminal"><p>./configure.sh --with-tabstops=2 --with-dl=both --with-id-anchor --with-github-tags --with-fenced-code --enable-all-features</p> <p>make</p></div>

@@ -278,7 +278,7 @@

<h2 id="Usage">Usage<a href="#document-top" title="Go to top"></a></h2> -<p>HastyScribe is a command-line application that can compile one or more <span class="ext">.md</span> or <span class="ext">.markdown</span> files into one or more HTML files with the same name(s).</p> +<p>HastyScribe is a command-line application that can compile one or more Markdown files into one or more HTML files with the same name(s).</p> <h3 id="Command.Line.Syntax">Command Line Syntax<a href="#document-top" title="Go to top"></a></h3>

@@ -287,7 +287,7 @@

<p>Where:</p> <ul> -<li><em>filename-or-glob-expression</em> is a valid file or <a href="http://en.wikipedia.org/wiki/Glob_(programming">glob</a>) expression ending in <span class="ext">.md</span> or <span class="ext">.markdown</span> that will be compiled into HTML.</li> +<li><em>filename-or-glob-expression</em> is a valid file or <a href="http://en.wikipedia.org/wiki/Glob_(programming">glob</a>) expression that will be compiled into HTML.</li> <li><span class="opt">&ndash;notoc</span> causes HastyScribe to output HTML documents <em>without</em> automatically generated a Table of Contents at the start.</li> </ul>

@@ -314,7 +314,7 @@ <div class="terminal"><p>hastyscribe.exe *.md</p></div>

<div class="tip"><p>Tip</p> -<p>You can also drag a <span class="kwd">.md</span> file directly on <span class="kwd">hastyscribe.exe</span> to compile it to HTML.</p></div> +<p>You can also drag a Markdown file directly on <span class="kwd">hastyscribe.exe</span> to compile it to HTML.</p></div> <h2 id="Syntax.Reference">Syntax Reference<a href="#document-top" title="Go to top"></a></h2>

@@ -1104,7 +1104,7 @@ </ul>

</div> <div id="footer"> - <p><span class="copy"></span> Fabio Cevasco &ndash; October 14, 2014</p> + <p><span class="copy"></span> Fabio Cevasco &ndash; October 17, 2014</p> <p><span>Powered by</span> <a href="https://h3rald.com/hastyscribe"><span class="hastyscribe"></span></a></p> </div> </body>
M doc/HastyScribe_UserGuide.mddoc/HastyScribe_UserGuide.md

@@ -95,7 +95,7 @@ 1. Clone the discount [repository](https://github.com/Orc/discount).

2. In the directory containing the Discount source code, run the following commands: > %terminal% - > ./configure.sh --with-tabstops=2 --with-dl=both --with-id-anchor --with-github-tags --with-fenced-code --enable-all-features + > ./configure.sh \-\-with-tabstops=2 \-\-with-dl=both \-\-with-id-anchor \-\-with-github-tags \-\-with-fenced-code \-\-enable-all-features > > make

@@ -113,7 +113,7 @@ 4. Run [nimrod c hastyscribe.nim](class:cmd)

## Usage -{{hs}} is a command-line application that can compile one or more [.md](class:ext) or [.markdown](class:ext) files into one or more HTML files with the same name(s). +{{hs}} is a command-line application that can compile one or more Markdown files into one or more HTML files with the same name(s). ### Command Line Syntax

@@ -121,7 +121,7 @@ [hastyscribe](class:cmd) _filename-or-glob-expression_ **[** [--notoc](class:opt) **]**

Where: - * _filename-or-glob-expression_ is a valid file or [glob](http://en.wikipedia.org/wiki/Glob_(programming)) expression ending in [.md](class:ext) or [.markdown](class:ext) that will be compiled into HTML. + * _filename-or-glob-expression_ is a valid file or [glob](http://en.wikipedia.org/wiki/Glob_(programming)) expression that will be compiled into HTML. * [--notoc](class:opt) causes {{hs}} to output HTML documents _without_ automatically generated a Table of Contents at the start. ### Linux/OSX Examples

@@ -151,7 +151,7 @@

> %tip% > Tip > -> You can also drag a [.md](class:kwd) file directly on [hastyscribe.exe](class:kwd) to compile it to HTML. +> You can also drag a Markdown file directly on [hastyscribe.exe](class:kwd) to compile it to HTML. ## Syntax Reference
M hastyscribe.nimhastyscribe.nim

@@ -251,12 +251,10 @@ if input == "":

quit(usage, 1) for file in walkFiles(input): - let filesplit = file.splitFile - if (filesplit.ext == ".md" or filesplit.ext == ".markdown"): - files.add(file) + files.add(file) if files.len == 0: - quit("Error: \"$1\" does not match any markdown file" % [input], 2) + quit("Error: \"$1\" does not match any file" % [input], 2) else: for file in files: compile(file)
M hastyscribe.nimrod.cfghastyscribe.nimrod.cfg

@@ -10,19 +10,27 @@ i386.linux.gcc.path = "/usr/local/gcc-4.8.1-for-linux32/bin"

i386.linux.gcc.exe = "i586-pc-linux-gcc" i386.linux.gcc.linkerexe = "i586-pc-linux-gcc" +# http://will-tm.com/cross-compiling-mac-os-x-mavericks/ +arm.linux.gcc.path = "/usr/local/arm-willtm-linux-gnueabi/bin" +arm.linux.gcc.exe = "arm-willtm-linux-gnueabi-gcc" +arm.linux.gcc.linkerexe = "arm-willtm-linux-gnueabi-gcc" + putenv: "LIBRARY_PATH=/tmp/babel/hastyscribe/vendor:/tmp/babel/hastyscribe_head/vendor:/private/tmp/babel/hastyscribe_head/vendor:/private/tmp/babel/hastyscribe/vendor" passL: "-lm" passL: "-L./vendor" @if macosx: - passL: "-lmarkdown_macosx" + passL: "-lmarkdown_macosx_x86" @end @if windows: - passL: "-lmarkdown_windows" + passL: "-lmarkdown_windows_x86" @end @if linux: - passL: "-lmarkdown_linux" + passL: "-lmarkdown_linux_x86" + @if arm: + passL: "-lmarkdown_linux_arm" + @end @end
M nakefile.nimnakefile.nim

@@ -4,6 +4,7 @@

const compile = "nimrod c -d:release" linux_x86 = "--cpu:i386 --os:linux" + linux_arm = "--cpu:arm --os:linux" windows_x86 = "--cpu:i386 --os:windows" parallel = "--parallelBuild:1" hs = "hastyscribe"

@@ -13,25 +14,32 @@

proc filename_for(os: string, arch: string): string = return "hastyscribe" & "_v" & v & "_" & os & "_" & arch & ".zip" -task "windows-build", "Build HastyScribe for Windows (x86)": - direshell compile, "--cpu:i386 --os:windows", hs_file +task "windows-x86-build", "Build HastyScribe for Windows (x86)": + direshell compile, windows_x86, hs_file -task "linux-build", "Build HastyScribe for Linux (x86)": - direshell compile, "--cpu:i386 --os:linux", hs_file +task "linux-x86-build", "Build HastyScribe for Linux (x86)": + direshell compile, linux_x86, hs_file -task "macosx-build", "Build HastyScribe for Mac OS X (x86)": +task "linux-arm-build", "Build HastyScribe for Linux (ARM)": + direshell compile, linux_arm, parallel, hs_file + +task "macosx-x86-build", "Build HastyScribe for Mac OS X (x86)": direshell compile, hs_file task "release", "Release HastyScribe": - echo "\n\n\n WINDOWS:\n\n" - runTask "windows-build" + echo "\n\n\n WINDOWS - x86:\n\n" + runTask "windows-x86-build" direshell zip, filename_for("windows", "x86"), hs & ".exe" direshell "rm", hs & ".exe" - echo "\n\n\n LINUX:\n\n" - runTask "linux-build" + echo "\n\n\n LINUX - x86:\n\n" + runTask "linux-x86-build" direshell zip, filename_for("linux", "x86"), hs direshell "rm", hs - echo "\n\n\n MAC OS X:\n\n" + echo "\n\n\n LINUX - ARM:\n\n" + runTask "linux-arm-build" + direshell zip, filename_for("linux", "arm"), hs + direshell "rm", hs + echo "\n\n\n MAC OS X - x86:\n\n" runTask "macosx-build" direshell zip, filename_for("macosx", "x86"), hs direshell "rm", hs