From d62ec85281e451a46ba30045917c119d65b72a84 Mon Sep 17 00:00:00 2001 From: Ulf Wiger Date: Tue, 16 Sep 2014 14:23:32 +0200 Subject: [PATCH] fix some more esl targets --- priv/scripts/check_edown.script | 2 +- samples/markedoc/SAMPLE3.md | 61 ++++++++++++++++----------------- 2 files changed, 31 insertions(+), 32 deletions(-) diff --git a/priv/scripts/check_edown.script b/priv/scripts/check_edown.script index 84c1427..17726f6 100644 --- a/priv/scripts/check_edown.script +++ b/priv/scripts/check_edown.script @@ -21,7 +21,7 @@ case lists:member("doc", Args) of {error, bad_name} -> io:fwrite("cannot find edown~n", []), D = {edown, ".*", - {git, "git://github.com/esl/edown.git", "HEAD"}}, + {git, "git://github.com/uwiger/edown.git", "HEAD"}}, Deps = case lists:keyfind(deps, 1, CONFIG) of false -> [D]; {_, Ds} -> diff --git a/samples/markedoc/SAMPLE3.md b/samples/markedoc/SAMPLE3.md index 1780442..3f223c9 100644 --- a/samples/markedoc/SAMPLE3.md +++ b/samples/markedoc/SAMPLE3.md @@ -10,7 +10,7 @@ SAMPLE 3: markedoc 0.3 README of Feb 2011 ''' **markedoc helps you keep your project's README.md in sync with your overview.edoc.** - + It is for use on Linux, FreeBSD and Mac OS X and any system that you can install **[sed][Requirements]** on. Status: [pre-beta][Status]. Quite stable and usable. See [Status][]. @@ -75,17 +75,17 @@ to see the result. For something only vaguely related but pretty, try: $ erl -noshell -run edoc_run application "'myapp'" '"samples"' '[{def,{vsn,""}},{stylesheet, "markedoc.css"}]' -This illustrates the motivation for the markedoc as it is now: to have all code lines in one block in order to be able to address them as one united div from css. +This illustrates the motivation for the markedoc as it is now: to have all code lines in one block in order to be able to address them as one united div from css. For your own projects you'd copy markedoc.sed in the right place and do something like: **FreeBSD, Mac OS X** $ sed -E -f bin/markedoc.sed README.md > doc/README.edoc - $ erl -noshell -run edoc_run application "'myapp'" '"."' '[]' + $ erl -noshell -run edoc_run application "'myapp'" '"."' '[]' **Linux** $ sed -r -f bin/markedoc.sed README.md > doc/README.edoc - $ erl -noshell -run edoc_run application "'myapp'" '"."' '[]' + $ erl -noshell -run edoc_run application "'myapp'" '"."' '[]' And that's it. This could also be part of your Makefile. For the intermediary README.edoc to automatically become part of your generated EDoc html pages, you would use a @docfile tag in your overview.edoc file, like so: @@ -95,7 +95,7 @@ By running sed, then edoc, this makes the README.edoc part of the overview page. Accordingly, the sample stub overview.edoc used for the samples here, looks like this: - @author You + @author You @title a markedoc sample doc @version 0.2 @docfile "samples/doc/SAMPLE.edoc" @@ -103,7 +103,7 @@ Accordingly, the sample stub overview.edoc used for the samples here, looks like Status ------ - **Pre-Beta**. Quite usable, but still likes to trip up EDoc now and then, which is kind of easy to do. + **Pre-Beta**. Quite usable, but still likes to trip up EDoc now and then, which is kind of easy to do. There are many ways to create formats that will make the EDoc generator tilt and unfortunately, the errors it throws are sometimes not quite so illuminating to the reader. But why not try an incremental approach and see what works. As you can see from this [source sample][sample], which works alright, it's quite a lot that *does* work and the murky bits can usally be worked out fast. Sometimes an additional line helps, some spaces at the end of a line, general intuitive stuff. Please experiment and push your fixes to me. @@ -114,19 +114,19 @@ Notes **[Erlang][]** is a programming language used to build massively scalable soft real-time systems with requirements on high availability. Some of its uses are in telecom, banking, e-commerce, computer telephony and instant messaging. Erlang's runtime system has built-in support for concurrency, distribution and fault tolerance. Erlang comes bundled with the Open Telecom Platform, OTP. -[Erlang]: http://www.erlang.org/doc/ +[Erlang]: http://www.erlang.org/doc/ **[EDoc][]** is the Erlang program documentation generator. Inspired by the Javadoc tool for the Java programming language, EDoc is adapted to the conventions of the Erlang world, and has several features not found in Javadoc. Edoc is part of the Erlang/OTP distribution. [EDoc]: http://www.erlang.org/doc/apps/edoc/chapter.html - **[edown][]** is an EDoc extension for generating Github-flavored Markdown. It uses edoc-style commented Erlang sources to create markdown files from them. + **[edown][]** is an EDoc extension for generating Github-flavored Markdown. It uses edoc-style commented Erlang sources to create markdown files from them. -[edown]: https://github.com/esl/edown +[edown]: https://github.com/uwiger/edown **[Markdown][]** is a text-to-HTML conversion tool for web writers. Markdown allows you to write using an easy-to-read, easy-to-write plain text format, then convert it to structurally valid XHTML (or HTML). -[Markdown]: http://daringfireball.net/projects/markdown/ +[Markdown]: http://daringfireball.net/projects/markdown/ **[sed][]** ('stream editor') is a Unix utility that parses text files and implements a programming language which can apply textual transformations to such files. It reads input files line by line (sequentially), applying the operation which has been specified via the command line (or a sed script), and then outputs the line. It is available today for most operating systems. There seems to be [one for Windows][winsed], too. @@ -148,18 +148,18 @@ To test markedoc, see '[Test][]', above. Or use sed -E -f bin/markedoc.sed samples/SAMPLE1.md > samples/doc/SAMPLE.edoc erl -noshell -run edoc_run application "'myapp'" '"samples"' '[{def,{vsn,""}},{stylesheet, "markedoc.css"}]' mv samples/doc/overview-summary.html samples/your-test-results/sample1.html - mv samples/doc/SAMPLE.edoc samples/your-test-results/SAMPLE1.edoc - + mv samples/doc/SAMPLE.edoc samples/your-test-results/SAMPLE1.edoc + sed -E -f bin/markedoc.sed samples/SAMPLE2.md > samples/doc/SAMPLE.edoc erl -noshell -run edoc_run application "'myapp'" '"samples"' '[]' mv samples/doc/overview-summary.html samples/your-test-results/sample2.html mv samples/doc/SAMPLE.edoc samples/your-test-results/SAMPLE2.edoc - + sed -E -f bin/markedoc.sed samples/SAMPLE3.md > samples/doc/SAMPLE.edoc erl -noshell -run edoc_run application "'myapp'" '"samples"' '[{def,{vsn,""}},{stylesheet, "markedoc.css"}]' mv samples/doc/overview-summary.html samples/your-test-results/sample3.html - mv samples/doc/SAMPLE.edoc samples/your-test-results/SAMPLE3.edoc - + mv samples/doc/SAMPLE.edoc samples/your-test-results/SAMPLE3.edoc + Then check samples/your-test-results/sample1.html - sample3.html and compare with samples/what-you-should-see/sample1.html, sample2.html and samples/what-you-could-see/sample3.html. To create the reference samples: @@ -174,37 +174,37 @@ or do the following to create six samples and save the results into samples/what erl -noshell -run edoc_run application "'myapp'" '"samples"' '[]' mv samples/doc/overview-summary.html samples/what-you-could-see/sample1.html mv samples/doc/SAMPLE.edoc samples/what-you-should-see/SAMPLE1.edoc - + sed -E -f bin/markedoc.sed samples/SAMPLE2.md > samples/doc/SAMPLE.edoc erl -noshell -run edoc_run application "'myapp'" '"samples"' '[]' mv samples/doc/overview-summary.html samples/what-you-could-see/sample2.html mv samples/doc/SAMPLE.edoc samples/what-you-should-see/SAMPLE2.edoc - + sed -E -f bin/markedoc.sed samples/SAMPLE3.md > samples/doc/SAMPLE.edoc erl -noshell -run edoc_run application "'myapp'" '"samples"' '[]' mv samples/doc/overview-summary.html samples/what-you-could-see/sample3.html mv samples/doc/SAMPLE.edoc samples/what-you-should-see/SAMPLE3.edoc - + sed -E -f bin/markedoc.sed samples/SAMPLE1.md > samples/doc/SAMPLE.edoc erl -noshell -run edoc_run application "'myapp'" '"samples"' '[{def,{vsn,""}},{stylesheet, "markedoc.css"}]' mv samples/doc/overview-summary.html samples/what-you-could-see/sample1.html mv samples/doc/SAMPLE.edoc samples/what-you-could-see/SAMPLE1.edoc - + sed -E -f bin/markedoc.sed samples/SAMPLE2.md > samples/doc/SAMPLE.edoc erl -noshell -run edoc_run application "'myapp'" '"samples"' '[{def,{vsn,""}},{stylesheet, "markedoc.css"}]' mv samples/doc/overview-summary.html samples/what-you-could-see/sample2.html mv samples/doc/SAMPLE.edoc samples/what-you-could-see/SAMPLE2.edoc - + sed -E -f bin/markedoc.sed samples/SAMPLE3.md > samples/doc/SAMPLE.edoc erl -noshell -run edoc_run application "'myapp'" '"samples"' '[{def,{vsn,""}},{stylesheet, "markedoc.css"}]' mv samples/doc/overview-summary.html samples/what-you-could-see/sample3.html - mv samples/doc/SAMPLE.edoc samples/what-you-could-see/SAMPLE3.edoc + mv samples/doc/SAMPLE.edoc samples/what-you-could-see/SAMPLE3.edoc To test this very README.md, use markdown.lua, credit Niklas Frykholm, : lua etc/markdown.lua README.md - -### HTML Special Signs + +### HTML Special Signs http://www.mountaindragon.com/html/iso.htm @@ -218,31 +218,30 @@ H. Diedrich History ------- - + 02/03/11 - 0.3 - **rough edges polished:** Linux, FreeBSD, Mac OS X * added doc for Linux use * added support for multi-line '[..]: ... "..."' references * added footnote signs and sepcial chars: -* dagger, double dagger: (+), (++), stars: (*), (**), (***) -* superscript 1, 2, 3: (*1), (*2), (*3), copyright (C), (R), (TM), +* dagger, double dagger: (+), (++), stars: (*), (**), (***) +* superscript 1, 2, 3: (*1), (*2), (*3), copyright (C), (R), (TM), * guillemots <<, >> and middle dot :: * added test batches etc/test-bsd.sh and etc/test-linux.sh -* added css sample in samples/what-you-could-see/ +* added css sample in samples/what-you-could-see/ * added classes for `
  • ' list item tags for '[..]:...'-references * fixed italic and bold merker interference bullet points * eliminated [..]: part of '[..]:...'-references, flipping "..." to lead * dev: sample creation batch make_samples.sh added - + 02/02/11 - 0.2 - **basics complete:** FreeBSD / Mac OS X * added support for === and --- headline format -* fixed cutting off of last lines +* fixed cutting off of last lines * fixed page-local anchor jumps * fixed space in javascript links * eliminated end-space requirement at end of '[..]:...'-style references. * eliminated need for echoing '@doc' first into edoc output file * added javascript title tag setting for '[..]:...'-style references. - + 01/31/11 - 0.1 - **first release:** FreeBSD / Mac OS X - \ No newline at end of file