about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--COPYING26
-rw-r--r--Makefile7
-rw-r--r--combine.ed12
3 files changed, 45 insertions, 0 deletions
diff --git a/COPYING b/COPYING new file mode 100644 index 0000000..2e90147 --- /dev/null +++ b/COPYING
@@ -0,0 +1,26 @@
1Copyright (c) Case Duckworth
2
3Redistribution and use in source and binary forms, with or without
4modification, are permitted provided that the following conditions are met:
5
61. Redistributions of source code must retain the above copyright notice, this
7 list of conditions and the following disclaimer.
8
92. Redistributions in binary form must reproduce the above copyright notice,
10 this list of conditions and the following disclaimer in the documentation
11 and/or other materials provided with the distribution.
12
133. Neither the name of the copyright holder nor the names of its
14 contributors may be used to endorse or promote products derived from
15 this software without specific prior written permission.
16
17THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
18AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
19IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
20DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
21FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
22DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
23SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
24CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
25OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
26OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..d0bab7b --- /dev/null +++ b/Makefile
@@ -0,0 +1,7 @@
1# subtext
2
3subtext: subtext.sh subtext.awk
4 ed subtext.sh < combine.ed > $@
5
6readme.html:
7 ./subtext.sh -m html -o $@ readme.st
diff --git a/combine.ed b/combine.ed new file mode 100644 index 0000000..a3d519b --- /dev/null +++ b/combine.ed
@@ -0,0 +1,12 @@
1/stawk()
2+c
3subtext="$(cat<<'__END_SUBTEXT__'
4.
5.r subtext.awk
6a
7__END_SUBTEXT__
8)"
9awk "$subtext" "$@"
10.
11w /dev/stdout
12q \ No newline at end of file