This repository has been archived by the owner on Dec 12, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 4
/
index.t2t
145 lines (107 loc) · 4.27 KB
/
index.t2t
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
txt2tags
ONE source, MULTI targets
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% Welcome to the sources of the txt2tags site
%
% This is a live example of a marked up file in the txt2tags format.
% There are some special tricks you can learn by reading.
% As you may be wondering, lines starting with % are ignored.
%
% Txt2tags generates the HTML code for this text, and all the page
% formatting (colors, sizes, fonts, blocks, position) is made on an
% external CSS file (http://txt2tags.org/inc/site.css).
%
% See those first lines at the top? They are the page heading.
%
% Now comes some special configuration directives, starting with %!
%
% The config used by all pages are centralized on this file
% (http://txt2tags.org/inc/config.t2t) and the "includeconf"
% command reads it.
%
%!includeconf: inc/config.t2t
%%% Some post processing filter magic (search & replace)
% Adds an ID to the <body> tag
% Note: the (?i) makes the pattern case insensitive (avoids headaches)
%!postproc: '(?i)(<body)' '\1 id="home"'
% Adds the RSS feed header to the page, right after <head> tag
%!postproc: '(?i)(<head>)' \1\n<link rel="alternate" href="http://txt2tags.wordpress.com" type="application/rss+xml">
% Adds class name to the splash image
%!postproc: '(download-v\d+.png")' '\1 class="splashimg"'
% Fills the "PHP" tooltip on "About this site". See config.t2t for details.
%!postproc: {tooltip1} One exception: Txt2tags Online is a PHP file, because it needs to be interactive.
% meta: keywords
%!postproc: (</HEAD>) <meta name="keywords" content="txt2tags, convert, conversion, online, text, HTML, XHTML, SGML, LaTeX, Lout, Man page, Wikipedia, Google Code Wiki, DokuWiki, MoinMoin, MagicPoint, PageMaker, Python, free, tool, markup, Linux, Mac, Windows, GPL">\n\1
% meta: description
%!postproc: (</HEAD>) <meta name="description" content="txt2tags - Convert plain text to HTML, XHTML, SGML, LaTeX, DocBook, Lout, Man page, Creole, Wikipedia, Google Code Wiki, DokuWiki, PmWiki, MoinMoin, MagicPoint, PageMaker, AsciiDoc and ASCII Art!">\n\1
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%% All the config is made, so the real contents begins now
% The sidebar with the menu links are on a separated file, included now
%!include: inc/menu.t2t
% DOWNLOAD banner and (deactivated) birthday cake
[[img/download-v26.png] download.html]
% | [img/cake.png] | [7 years of txt2tags! http://txt2tags.wordpress.com/2008/07/26/7-years-of-txt2tags/]
% And here's our first heading, level 2 (see the two equal signs)
== About txt2tags ==
Txt2tags is a document generator. It reads a text file with minimal
markup such as ``**bold**`` and ``//italic//`` and converts it to the
following formats:
- HTML
- XHTML
- SGML
- DocBook (**NEW**)
- LaTeX
- Lout
- Man page
- Creole (**NEW**)
- Wikipedia / MediaWiki
- Google Code Wiki
- PmWiki (**NEW**)
- DokuWiki
- MoinMoin
- MagicPoint
- PageMaker
- AsciiDoc (**NEW**)
- ASCII Art (**NEW**)
- Plain text
- [Add your favorite! new-target.html]
- Read more: [txt2tags features features.html]
- Try it now: [txt2tags online online.php]
- Get it: [download download.html]
- Contribute: [GitHub https://github.com/txt2tags/txt2tags]
% See how lists are simple?
%
% Now follows a definition list. The leading spaces are optional.
: Author:
[Aurelio Jargas http://aurelio.net/soft/]
<verde (a) aurelio net>
[@aureliojargas http://twitter.com/aureliojargas]
: Keywords:
free,
tool,
convert,
text,
[markup markup.html],
simple,
[Linux download.html],
[Mac download.html],
[Windows download.html],
[GUI img/gui.png],
[CLI img/help.png],
[Web {URLONLINE}],
[Python http://python.org],
[GPL http://directory.fsf.org/txt2tags.html]
% Write the way you want. It will get right on the screen.
% You got it, right? The markup is damn simple.
== About this site ==
This site is 100% powered by txt2tags and [CSS inc/site.css].
No Javascript, CGI or [PHP #tooltip1], just plain static
[valid {URLHTMLVALIDATOR}] HTML pages.
You can read the text sources for each page, just click the "See
sources" link on the footer. Reading them you will learn the markup
instantly.
% Tip for the source readers:
% Change the .html by .t2t on the page address to read the sources
% The footer is an external file
%!include: inc/footer.t2t