diff options
author | Arnold D. Robbins <arnold@skeeve.com> | 2010-07-16 12:09:58 +0300 |
---|---|---|
committer | Arnold D. Robbins <arnold@skeeve.com> | 2010-07-16 12:09:58 +0300 |
commit | cae8bc6ced84c12590e3554a06a952283735363a (patch) | |
tree | ca4f38bfcb1312bfb62fc693564d68f3e9b3e973 /test/include.awk | |
parent | dbd583bd2b8a6dd40c622875a4e197360cb5aba7 (diff) | |
download | egawk-cae8bc6ced84c12590e3554a06a952283735363a.tar.gz egawk-cae8bc6ced84c12590e3554a06a952283735363a.tar.bz2 egawk-cae8bc6ced84c12590e3554a06a952283735363a.zip |
Move to 2.14.
Diffstat (limited to 'test/include.awk')
-rw-r--r-- | test/include.awk | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/test/include.awk b/test/include.awk new file mode 100644 index 00000000..a506a813 --- /dev/null +++ b/test/include.awk @@ -0,0 +1,13 @@ +# input file should have lines which start with "@incl" followed by +# a name of a file to include +{ + if ((NF == 2) && ($1 == "@incl")) { + print " -- included file -- ", $2 + while ((getline line < $2) > 0) + print line + close ($2) + printf "\t***\n" + } else { + print + } +} |