| - navbar.tron | |
| - navbar.tron | |
| - navbar.tron | |
| - navbar.tron | |
| {arch}/lnx-bbc/lnx-bbc--documentation {arch}/lnx-bbc/lnx-bbc--documentation/lnx-bbc--documentation--1.0 {arch}/lnx-bbc/lnx-bbc--documentation/lnx-bbc--documentation--1.0/nick@zork.net--projects {arch}/lnx-bbc/lnx-bbc--documentation/lnx-bbc--documentation--1.0/nick@zork.net--projects/patch-log | {arch}/lnx-bbc/lnx-bbc--documentation {arch}/lnx-bbc/lnx-bbc--documentation/lnx-bbc--documentation--1.0 {arch}/lnx-bbc/lnx-bbc--documentation/lnx-bbc--documentation--1.0/nick@zork.net--projects {arch}/lnx-bbc/lnx-bbc--documentation/lnx-bbc--documentation--1.0/nick@zork.net--projects/patch-log |
| {arch}/lnx-bbc/lnx-bbc--documentation {arch}/lnx-bbc/lnx-bbc--documentation/lnx-bbc--documentation--1.0 {arch}/lnx-bbc/lnx-bbc--documentation/lnx-bbc--documentation--1.0/nick@zork.net--projects {arch}/lnx-bbc/lnx-bbc--documentation/lnx-bbc--documentation--1.0/nick@zork.net--projects/patch-log | {arch}/lnx-bbc/lnx-bbc--documentation {arch}/lnx-bbc/lnx-bbc--documentation/lnx-bbc--documentation--1.0 {arch}/lnx-bbc/lnx-bbc--documentation/lnx-bbc--documentation--1.0/nick@zork.net--projects {arch}/lnx-bbc/lnx-bbc--documentation/lnx-bbc--documentation--1.0/nick@zork.net--projects/patch-log |
| File: CREDITS | |
|---|---|
| patch-4 | patch-5 |
| Line 24 | Line 24 |
| Nick "makes make make sense" Moffitt Sean "keen with the winchesters" Neakums Niall O Broin | Nick "makes make make sense" Moffitt Sean "keen with the winchesters" Neakums Niall O Broin |
| "Yosemite" Sam Phillips | Sam "friendly Arch helper" Phillips |
| Nate "$(if $(filter $(GARBUILD),$(GARHOST)),no,yes)" Riffe Seth "Seth David Schoen" Schoen Andrew Scott | Nate "$(if $(filter $(GARBUILD),$(GARHOST)),no,yes)" Riffe Seth "Seth David Schoen" Schoen Andrew Scott |
| File: Makefile | |
|---|---|
| patch-4 | patch-5 |
| Line 1 | Line 1 |
| # Turn all them .txt files into .html files | # Turn all them .txt files into .html files |
| %.html: %.txt tron.awk navbar.nav | %.html: %.txt tron.awk navbar.tron |
| ./tron.awk $< html: $(patsubst %.txt,%.html,$(wildcard *.txt)) @echo html generated | ./tron.awk $< html: $(patsubst %.txt,%.html,$(wildcard *.txt)) @echo html generated |
| *.html: tron.awk navbar.nav | *.html: tron.awk navbar.tron |
| # top-level Makefile for the entire tree. %: | # top-level Makefile for the entire tree. %: |
| File: README.txt | |
|---|---|
| patch-4 | patch-5 |
| Line 22 | Line 22 |
| "gar" sitting in your current directory. You can rename it if you like. | "gar" sitting in your current directory. You can rename it if you like. |
| === From CVS === | === From arch === |
| The first step is to log into the CVS pserver. | The LNX-BBC project now uses arch as its revision control system. For more detailed information, see our <arch.html arch documentation>. What follows will allow you to download development trees quickly. |
| ----8<---- cvs -d:pserver:anonymous@cvs.lnx-bbc.org:/var/cvs login ----8<---- Just hit return when it asks you for a password. You can now check out the STABLE or HEAD branches of the tree. ==== LNX-BBC 2.1 ==== Each release is tagged in the exact state used for it. These are typically snapshots of the STABLE branch (see below). For example, to grab the 2.1 release, we use the RELEASE_lnx-bbc_2_1 tag as follows: | The first step is to register our public arch mirror as a valid archive. |
| ----8<---- | ----8<---- |
| cvs -z3 -d:pserver:anonymous@cvs.lnx-bbc.org:/var/cvs co -r RELEASE_lnx-bbc_2_1 gar | tla register-archive lnx-bbc-devel@zork.net--gar http://www.lnx-bbc.org/arch |
| ----8<---- | ----8<---- |
| ==== STABLE ==== | You can now get the stable or research branches of the GAR tree. ==== the stable branch ==== |
| The <versions.html STABLE branch> is designed to compile on the | The <versions.html stable branch> is designed to compile on the |
| current revision of Debian Stable, although it may also work on other similarly composed GNU/Linux systems. However, our build system uses Debian Stable, and our <chroot.html published chroot environments> use | current revision of Debian Stable, although it may also work on other similarly composed GNU/Linux systems. However, our build system uses Debian Stable, and our <chroot.html published chroot environments> use |
| Line 55 | Line 48 |
| changes judiciously. ----8<---- | changes judiciously. ----8<---- |
| cvs -z3 -d:pserver:anonymous@cvs.lnx-bbc.org:/var/cvs co -r STABLE gar | tla get lnx-bbc-devel@zork.net--gar/lnx-bbc--stable gar |
| ----8<---- | ----8<---- |
| ==== HEAD ==== | You should now have a working copy of the stable branch in a directory called "gar". |
| This is the <versions.html unstable branch> of the tree, and contains | ==== the research branch ==== This is the <versions.html research branch> of the tree, and contains |
| up-to-the-minute updates of what our developers have been working on. It typically builds on a Debian testing or unstable distribution, and may break on stable. You may find this to build on your more recent Red Hat distributions if the STABLE branch does not. ----8<---- | up-to-the-minute updates of what our developers have been working on. It typically builds on a Debian testing or unstable distribution, and may break on stable. You may find this to build on your more recent Red Hat distributions if the STABLE branch does not. ----8<---- |
| cvs -z3 -d:pserver:anonymous@cvs.lnx-bbc.org:/var/cvs co gar | tla get lnx-bbc-devel@zork.net--gar/lnx-bbc--research gar |
| ----8<---- | ----8<---- |
| You should now have a working copy of the research branch in a directory called "gar". | |
| == Configuring GAR == You can either set environment variables or edit gar.conf.mk directly. | == Configuring GAR == You can either set environment variables or edit gar.conf.mk directly. |
| File: bbctools.txt | |
|---|---|
| patch-4 | patch-5 |
| Line 118 | Line 118 |
| A package can also build a user account on a BBC. To do so, it is necessary to manually create appropriate .passwd, .group, and .bootstrap files and put them in the files/ directory of the package. | A package can also build a user account on a BBC. To do so, it is necessary to manually create appropriate .passwd, .group, and .bootstrap files and put them in the files/ directory of the package. |
| Be sure to prepend the username to /all three/ files | Be sure to prepend the username to *all three* files |
| ($(username).bootstrap will later be copied to $(username)/.bootstrap in the work/ directory). In the Makefile, add the files to your DISTFILES variable and enumerate the users that your package will | ($(username).bootstrap will later be copied to $(username)/.bootstrap in the work/ directory). In the Makefile, add the files to your DISTFILES variable and enumerate the users that your package will |
| File: bittorrent.txt | |
|---|---|
| patch-4 | patch-5 |
| Line 19 | Line 19 |
| == The Tracker == | == The Tracker == |
| The .torrent files contain the location of a /tracker/, which is a | The .torrent files contain the location of a *tracker*, which is a |
| brokering server that connects users with other users who have pieces of files that can be swapped. It deals entirely in sha1 hashes, and thus has no concept of "filenames". The contents of the files never | brokering server that connects users with other users who have pieces of files that can be swapped. It deals entirely in sha1 hashes, and thus has no concept of "filenames". The contents of the files never |
| Line 29 | Line 29 |
| The key is that users grab pieces from *each other*. This means that to put a file up available for download, you actually start a | The key is that users grab pieces from *each other*. This means that to put a file up available for download, you actually start a |
| /downloader/ process, but with the file already completely in place! | *downloader* process, but with the file already completely in place! |
| This can be confusing when you are used to HTTP and FTP servers, but realize that once you have completed a download, the tracker will know | This can be confusing when you are used to HTTP and FTP servers, but realize that once you have completed a download, the tracker will know |
| that you have /all/ pieces of the file available for others to grab. | that you have *all* pieces of the file available for others to grab. |
| This is why often you'll see torrent sites admonishing users to keep their clients open after downloads are complete. The more people do | This is why often you'll see torrent sites admonishing users to keep their clients open after downloads are complete. The more people do |
| File: download.txt | |
|---|---|
| patch-4 | patch-5 |
| Line 7 | Line 7 |
| If you're looking for the bleeding edge of LNX-BBC development, consider our <testing.html testing releases> or our | If you're looking for the bleeding edge of LNX-BBC development, consider our <testing.html testing releases> or our |
| <http://www.lnx-bbc.org/builds/ automated cvs builds>. | <http://www.lnx-bbc.org/builds/ automated arch builds>. |
| We use bittorrent in order to make downloads quicker. If you wish to help mirror the BBC images, the best way is to use our | We use bittorrent in order to make downloads quicker. If you wish to help mirror the BBC images, the best way is to use our |
| File: faq.txt | |
|---|---|
| patch-4 | patch-5 |
| Line 66 | Line 66 |
| * Purchase one from the <http://shop.eff.org/Merchant2/merchant.mvc?Screen=PROD&Store_Code=ES&Product_Code=BBC EFF Online Store> | * Purchase one from the <http://shop.eff.org/Merchant2/merchant.mvc?Screen=PROD&Store_Code=ES&Product_Code=BBC EFF Online Store> |
| * Purchase one from <http://linuxcentral.com/catalog/index.php3?prod_code=L000-181 Linux Central> | |
| * If you run a Free Software user group of some kind, you may request that some be sent on the <http://zork.net/mailman/listinfo/lnx-bbc lnx-bbc | * If you run a Free Software user group of some kind, you may request that some be sent on the <http://zork.net/mailman/listinfo/lnx-bbc lnx-bbc |
| Line 177 | Line 179 |
| == So why GAR? Why not <name-of-favorite-build-system>? == | == So why GAR? Why not <name-of-favorite-build-system>? == |
| The goals of GAR are best suited to the compilation of /third-party/ | The goals of GAR are best suited to the compilation of *third-party* |
| software. We theoretically could set up everything in a big autoconf tree, or scheme- or Java-based build system, but that would require a | software. We theoretically could set up everything in a big autoconf tree, or scheme- or Java-based build system, but that would require a |
| /lot/ of hacking. GAR is designed to support a heterogeneous set of | *lot* of hacking. GAR is designed to support a heterogeneous set of |
| autoconfiguration and build tools, and to make the best of what a software package already has. | autoconfiguration and build tools, and to make the best of what a software package already has. |
| Line 211 | Line 213 |
| Issue the following commands. ----8<---- | Issue the following commands. ----8<---- |
| cvs -z3 -d:pserver:anonymous@cvs.lnx-bbc.org:/var/cvs login cvs -z3 -d:pserver:anonymous@cvs.lnx-bbc.org:/var/cvs co gar | tla register-archive lnx-bbc-devel@zork.net--gar http://www.lnx-bbc.org/arch tla get lnx-bbc-devel@zork.net--gar/lnx-bbc--research gar |
| ----8<---- Just hit return when it asks you for a password. | ----8<---- Just hit return when it asks you for a password. |
| Alternately, you can download <http://cvs.lnx-bbc.org/cvs/gar/gar.tar.gz?tarball=1 the latest CVS snapshot>, updated immediately from the latest CVS checkin. For the STABLE branch, issue the following instead: | For the stable branch, issue the following instead: |
| ----8<---- | ----8<---- |
| cvs -z3 -d:pserver:anonymous@cvs.lnx-bbc.org:/var/cvs login cvs -z3 -d:pserver:anonymous@cvs.lnx-bbc.org:/var/cvs co -r STABLE gar | tla register-archive lnx-bbc-devel@zork.net--gar http://www.lnx-bbc.org/arch tla get lnx-bbc-devel@zork.net--gar/lnx-bbc--stable gar |
| ----8<---- | ----8<---- |
| == When I try to get GAR, it hangs on wireless-tools! How do I fix this? == This is because you have a broken version of CVS, such as the one shipped with Red Hat. Try issuing the above commands without the -z3 flag. | |
| == When I try to build GAR, it fails on one package. How do I fix it? == Sadly, the nature of compilation is that it will behave differently on | == When I try to build GAR, it fails on one package. How do I fix it? == Sadly, the nature of compilation is that it will behave differently on |
| File: garchitecture.txt | |
|---|---|
| patch-4 | patch-5 |
| Line 239 | Line 239 |
| Although the INSTALL_ARGS could not, due to the fact that INSTALL_OVERRIDE_DIRS prepends $(DESTDIR), and the w3m package | Although the INSTALL_ARGS could not, due to the fact that INSTALL_OVERRIDE_DIRS prepends $(DESTDIR), and the w3m package |
| /already/ honors $(DESTDIR)! | *already* honors $(DESTDIR)! |
| For more information on INSTALL_OVERRIDE_DIRS, see the "Install Override Dirs" <gartips.html GAR Tip>. For more information on | For more information on INSTALL_OVERRIDE_DIRS, see the "Install Override Dirs" <gartips.html GAR Tip>. For more information on |
| File: bbc.css | |
|---|---|
| patch-4 | patch-5 |
| Line 1 | Line 1 |
| body { | body { |
| background-color: #000000; color: #cccccc; | |
| font-family: serif; | font-family: serif; |
| font-size: small; | |
| } h1,h2,h3,h4,h5 { font-family: sans-serif; | } h1,h2,h3,h4,h5 { font-family: sans-serif; |
| background-color: #536287; color: white; | |
| margin-top:2pt; margin-bottom:8pt; padding-top: 1px; padding-bottom: 1px; clear: left; | margin-top:2pt; margin-bottom:8pt; padding-top: 1px; padding-bottom: 1px; clear: left; |
| -moz-border-radius: 5%; | |
| } h1 { font-size: xx-large; border-style:double; border-width:medium; | } h1 { font-size: xx-large; border-style:double; border-width:medium; |
| padding-left:3pt; | padding-right:1em; |
| border-color:black; clear: both; | border-color:black; clear: both; |
| text-align: center; | |
| } h2 { | } h2 { |
| Line 37 | Line 34 |
| h3 { font-size: large; padding-left:9pt; | h3 { font-size: large; padding-left:9pt; |
| padding-right:9pt; width: 60%; | |
| } h4 { font-size: medium; padding-left:12pt; | } h4 { font-size: medium; padding-left:12pt; |
| padding-right:12pt; width: 60%; | |
| } h5 { font-size: small; padding-left:15pt; | } h5 { font-size: small; padding-left:15pt; |
| padding-right:15pt; width: 60%; | |
| } | } |
| li.invisible { list-style-type: none; padding-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; margin-top: 0px; margin-bottom: 12pt; margin-left: 0px; margin-right: 0px; | .invisible { display: none; |
| } | } |
| li.navbar,h4.navbar { padding-left: 6pt; margin-top:8pt; | .navbar { margin-top:2pt; |
| margin-bottom:2pt; border-style:none; } | margin-bottom:2pt; border-style:none; } |
| .chapter { | .chapter, .navbar { |
| padding-left: 0pt; | padding-left: 0pt; |
| list-style-type: decimal; list-style-position: inside; | |
| margin-bottom:2pt; } li.chapter { font-size: small; padding-left: 3pt; | margin-bottom:2pt; } li.chapter { font-size: small; padding-left: 3pt; |
| background-color: #333333; | |
| } li.activechapter, li.chapter:hover { | } li.activechapter, li.chapter:hover { |
| list-style-type: decimal; list-style-position: inside; | |
| margin-bottom:2pt; font-size: small; | margin-bottom:2pt; font-size: small; |
| padding-left: 6pt; background-color: #001133; | padding-left: 1em; |
| } | } |
| h4.navbar { text-align: center; padding-left: 0; padding-right: 0; width: 100%; } | |
| li.navbar { padding-left: 3pt; list-style-type: none; | li.navbar { padding-left: 3pt; list-style-type: none; |
| background-color: #333333; | |
| margin-bottom:2pt; margin-top: 2pt; | margin-bottom:2pt; margin-top: 2pt; |
| color: #cccccc; | |
| } li.activenavbar, li.navbar:hover { | } li.activenavbar, li.navbar:hover { |
| padding-left: 6pt; | padding-left: 1em; |
| list-style-type: none; margin-bottom:2pt; margin-top: 2pt; | list-style-type: none; margin-bottom:2pt; margin-top: 2pt; |
| background-color: #001133; | |
| } | } |
| a:link { color: #0099cc; | abbr, acronym { border-bottom: 1px dotted #777777; cursor: help; |
| } | } |
| a.navbar:link, a.navbar:visited { color: #cccccc; | a.navbar:link, a.navbar:visited, a.chapter:link, a.chapter:visited { |
| display: block; } a.next:link, a.next:visited, a.previous:link, a.previous:visited { | display: block; } a.next:link, a.next:visited, a.previous:link, a.previous:visited { |
| background-color: #003366; color:white; | |
| border-style:double; border-width:medium; border-color:black; | border-style:double; border-width:medium; border-color:black; |
| -moz-border-radius: 50%; padding-left: 3pt; padding-right: 3pt; | |
| } div.next { | } div.next { |
| Line 136 | Line 128 |
| clear: both; } | clear: both; } |
| a:visited { color: #aaaaaa; } | |
| dl,ul,ol { margin-top: 1pt; } | dl,ul,ol { margin-top: 1pt; } |
| tt,pre { font-family: monospace; } | |
| pre.code { | pre.code { |
| font-size: x-small; | overflow: auto; |
| margin-top: 8pt; margin-bottom: 8pt; | margin-top: 8pt; margin-bottom: 8pt; |
| background-color: #001133; | |
| white-space:pre; border-style:solid; border-width:thin; | white-space:pre; border-style:solid; border-width:thin; |
| border-color:#0099cc; color:#0099cc; | |
| padding:5px; | padding:5px; |
| font-size: x-small; | |
| } | } |
| .sidebar { | .sidebar, .ednote { |
| font-style: italic; | font-style: italic; |
| border-style: solid; border-width: thin; padding: .5em; text-align: justify; margin-top: .5em; margin-bottom: .5em; -moz-border-radius: 5%; } .sidebar { | |
| float: right; clear: right; width: 33%; margin-left: .5em; | float: right; clear: right; width: 33%; margin-left: .5em; |
| margin-bottom: .5em; margin-top: 0; margin-right: 0; border-style: solid; border-width: thin; border-color:#0099cc; background-color: #001133; text-align: justify; padding: .5em; | margin-right: 1px; background-color: black; } .ednote { float: left; clear: left; width: 20%; border-style: dashed; margin-right: .5em; margin-left: 1px; |
| } .boxology, .listy { | } .boxology, .listy { |
| margin: 3px; padding: 3px; | |
| border-style: solid; border-width: thin; | border-style: solid; border-width: thin; |
| border-color: #536287; border-collapse: collapse; margin: 5px 15px; padding: 5px; | |
| } | } |
| th.listy { text-align: right; font-family: sans-serif; } /* colors for the dep tree */ li.main { color: white; } li.singularity { color: cyan; } li.build { color: blue; } li.rootbin { color: red; } li.lnximg { color: purple; } .lynxonly { display: none; } /* Style info for the diffs in the package list */ TABLE.d2h-table { border-collapse: collapse; border-style: solid; border-width: 1px; border-color: white; margin: 5px 15px; color: #cccccc; } TABLE.d2h-table TR { font-family: sans-serif; | table.boxology, table.listy { /* float: left; */ border-collapse: collapse |
| } | } |
| TABLE.d2h-table TR.blk-hdr { font-size: 11pt; font-weight: bold; border-style: solid; border-width: 1px 0px 0px 0px; border-color: white; background-color: #333333; | th.boxology, th.listy { font-family: sans-serif; |
| } | } |
| TABLE.d2h-table TR.blk-hdr TH { border-style: dashed; border-width: 0px 0px 0px 1px; border-color: white; padding: 0px 2px; | td.boxology, td.listy { font-family: sans-serif; |
| } | } |
| TABLE.d2h-table TR.blk-text { font-size: 11pt; | th.listy { text-align: right; font-family: sans-serif; border-style: none; |
| } | } |
| TABLE.d2h-table TR.blk-text TD { border-style: dashed; border-width: 0px 0px 0px 1px; border-color: white; padding: 0px 5px; | /* dt { font-weight: bold; } */ .toc { position: absolute; top: 1em; left: 3px; width: 242px; float: left; clear: left; display: block; } .mainbody { position: absolute; top: 1em; left: 250px; right: 0; padding-right: 3px; padding-top: 0px; float: right; clear: right; font-size: normal; display: block; |
| } | } |
| TABLE.d2h-table TR.blk-text TD.right-changed, TABLE.d2h-table TR.blk-text TD.left-changed { background-color: #536287; } | |
| TABLE.d2h-table TR.blk-text TD.right-added, TABLE.d2h-table TR.ver-hdr TH.newver { background-color: #336633; } | |
| TABLE.d2h-table TR.blk-text TD.left-removed, TABLE.d2h-table TR.ver-hdr TH.oldver { background-color: #663333; } | |
| File: navbar.nav | |
|---|---|
| patch-4 | patch-5 |
| Line 1 | Line 1 |
| <center><a href="./"><img src="logo.png" alt="[LNX-BBC]" border="0"></a></center> | |
| <h4 class="navbar">LNX-BBC</h4> <li class="navbar"><a class="navbar" href="faq.html">FAQ</a></li> | <h4 class="navbar">LNX-BBC</h4> <li class="navbar"><a class="navbar" href="faq.html">FAQ</a></li> |
| Line 16 | Line 18 |
| <li class="navbar"><a class="navbar" href="garchitecture.html">Package Maintainer's Guide</a></li> | <li class="navbar"><a class="navbar" href="garchitecture.html">Package Maintainer's Guide</a></li> |
| <li class="navbar"><a class="navbar" href="arch.html">Arch Tutorial</a></li> | |
| <li class="navbar"><a class="navbar" href="garvariables.html">GAR Variable list</a></li> <li class="navbar"><a class="navbar" href="gartips.html">GAR Tips and Tricks</a></li> | <li class="navbar"><a class="navbar" href="garvariables.html">GAR Variable list</a></li> <li class="navbar"><a class="navbar" href="gartips.html">GAR Tips and Tricks</a></li> |
| Line 29 | Line 33 |
| <h4 class="navbar">Resources</h4> | <h4 class="navbar">Resources</h4> |
| <li class="navbar"><a class="navbar" href="http://cvs.lnx-bbc.org/cvs/gar/">GAR CVS</a></li> | <!-- li class="navbar"><a class="navbar" href="http://cvs.lnx-bbc.org/cvs/gar/">GAR CVS</a></li --> |
| <li class="navbar"><a class="navbar" href="http://build.lnx-bbc.org/packages/">Package List</a></li> | <!-- li class="navbar"><a class="navbar" href="http://build.lnx-bbc.org/packages/">Package List</a></li --> |
| <li class="navbar"><a class="navbar" href="reports/stable-head/">Branch Status Report</a></li> | <!-- li class="navbar"><a class="navbar" href="reports/stable-head/">Branch Status Report</a></li --> |
| <li class="navbar"><a class="navbar" href="http://bugs.lnx-bbc.org/bugs/">Bug Tracking System</a></li> | <li class="navbar"><a class="navbar" href="http://bugs.lnx-bbc.org/bugs/">Bug Tracking System</a></li> |
| File: tron.awk | |
|---|---|
| patch-4 | patch-5 |
| Line 37 | Line 37 |
| # B (short circuit), R (same), C, L, H, U, E BEGIN { | # B (short circuit), R (same), C, L, H, U, E BEGIN { |
| # load in acronym daturbase before we munge RS. while((getline acronym < "acronyms.tron") > 0) { if(acronym ~ /=/) { split(acronym, ttt, "=") gsub(/"/, "''", ttt[2]) acronyms[ttt[1]] = ttt[2] } } close("acronyms.tron") | |
| # Use arbitrary numbers of blank lines to separate records | # Use arbitrary numbers of blank lines to separate records |
| RS = "\n[[:space:]]*\n+" | RS = "\n[[:space:]]*\n+" |
| FS = "\n" ORS = "\n\n" OFS = "\n" | FS = "\n" ORS = "\n\n" OFS = "\n" |
| Line 51 | Line 61 |
| gsub(/>/, "\\>") | gsub(/>/, "\\>") |
| fore = "<p>" aft = "</p>" | |
| # This stuff only runs at the start of the input .txt # file. It sets up filename vars and fills out some of # the ugly HTML-storing variables. Also slurps the title | # This stuff only runs at the start of the input .txt # file. It sets up filename vars and fills out some of # the ugly HTML-storing variables. Also slurps the title |
| Line 62 | Line 69 |
| outputstem = FILENAME sub(/\.txt$/, "", outputstem) | outputstem = FILENAME sub(/\.txt$/, "", outputstem) |
| pagestart = "<html><head> <title>" $0 "</title>" pagestart = pagestart "<link rel=\"stylesheet\" type=\"text/css\" href=\"print.css\" media=\"print\" />" pagestart = pagestart "<link rel=\"stylesheet\" type=\"text/css\" href=\"bbc.css\" media=\"screen\" /></head>" pagestart = pagestart "<body bgcolor=\"black\" text=\"#cccccc\" link=\"#0099cc\" vlink=\"#aaaaaa\"> <br/> " pagestart = pagestart "<table width=\"100%\" border=\"0\" class=\"layout\">" pagestart = pagestart "<tr height=\"116\" style=\"height:116\" class=\"layout\">" pagestart = pagestart "<th valign=\"top\" align=\"center\" class=\"layout\"> <a href=\"/\"><img src=\"logo.png\" width=\"200\" alt=\"LNX-BBC\" border=\"0\" class=\"logo\"/></a> </span> </th>" pagestart = pagestart "<td rowspan=\"3\" valign=\"top\" width=\"100%\" class=\"mainbody\"> " tocstart = "</td></tr><tr height=\"100%\"> <td valign=\"top\" align=\"left\" height=\"100%\" class=\"layout\"><hr align=\"center\" width=\"25%\"/> " pagefinish = "</td></tr><tr height=\"100%\"> <td valign=\"top\" align=\"left\" height=\"100%\" class=\"layout\"> <a href=\"" outputstem ".txt\">Download this document as plain text</a> </td> </tr> <tr height=\"300\" class=\"layout\"> <td height=\"300\" class=\"layout\"> </td> <td height=\"300\" class=\"layout\"> </td></tr> </table> </div> </body></html>" | pagestart = "<html>\n<head>\n <title>" $0 "</title>\n" pagestart = pagestart " <link rel=\"stylesheet\" type=\"text/css\" href=\"print.css\" media=\"print\" />\n" pagestart = pagestart " <link rel=\"stylesheet\" type=\"text/css\" href=\"color-scheme.css\" media=\"screen\" />\n" pagestart = pagestart " <link rel=\"stylesheet\" type=\"text/css\" href=\"layout.css\" media=\"screen\" />\n</head>\n" pagestart = pagestart "<body bgcolor=\"black\" text=\"#cccccc\" link=\"#00cc00\" vlink=\"#aaaaaa\"> \n" # Note that this table is ignored by the div layout if you have # CSS. It exists only to support non-CSS browsers. mainstart = "<table valign=\"top\" border=\"0\" width=\"100%\"><tr valign=\"top\" height=\"15\"><td valign=\"top\" height=\"15\"> </td><td rowspan=\"2\">" mainstart = mainstart " <div class=\"mainbody\">" # notice the table data in these as well. tocstart = " </div>\n</td></tr><tr valign=\"top\" height=\"100%\"><td valign=\"top\" height=\"100%\">\n <div class=\"toc\">" pagefinish = " </div>\n</td></tr></table>\n\n</body>\n</html>" |
| outputfile = outputstem ".html" | outputfile = outputstem ".html" |
| printerfile = outputstem "_printable.html" | |
| print pagestart > outputfile | print pagestart > outputfile |
| print mainstart > outputfile print pagestart > printerfile | |
| print "<hr align=\"center\" width=\"25%\"/> <h4 class=\"navbar\"><a class=\"navbar\" href=\"" outputfile "\">" $0 "</a></h4><ol class=\"chapter\">" > outputstem ".nav" print "<h1>" $0 "</h1>" >> outputfile | print "<hr align=\"center\" width=\"25%\"/> <h4 class=\"navbar\"><a class=\"navbar\" href=\"" outputfile "\">" $0 "</a></h4><ol class=\"chapter\">" > outputstem ".nav" print "<h1>" $0 "</h1>" >> outputfile |
| print "<h1>" $0 "</h1>" >> printerfile | |
| next | next |
| } | } # # get a nice mouseover on the number of words in each # # paragraph, so that we can better estimate card capacity. # # Not likely to be useful in the general tron.awk distro. # countwords = "/usr/bin/wc -w | xargs echo" # print $0 |& countwords # close(countwords, "to") # wc prints output only when you close input # countwords |& getline numwords # close(countwords) # through with this paragraph # fore = "<p title=\"" numwords " words\">" |
| fore = "<p>" aft = "</p>" | |
| } | } |
| Line 99 | Line 125 |
| blockquotemode = "on" } print >> outputfile | blockquotemode = "on" } print >> outputfile |
| print >> printerfile | |
| next } | next } |
| Line 107 | Line 134 |
| sub(/^-+(8<|>8)-+$/, "</pre></p>", $NF) blockquotemode = "off" print >> outputfile | sub(/^-+(8<|>8)-+$/, "</pre></p>", $NF) blockquotemode = "off" print >> outputfile |
| print >> printerfile | |
| next } blockquotemode == "on" { print >> outputfile | next } blockquotemode == "on" { print >> outputfile |
| print >> printerfile | |
| next } | next } |
| Line 172 | Line 201 |
| } | } |
| # centered blocks. $1 ~ /^[[:blank:]]*-\| .* \|-[[:blank:]]*$/ { sub(/^[[:blank:]]*-\|/, "<div align=\"center\">") sub(/\|-[[:blank:]]*$/, "</div>") } # and left-flush blocks $1 ~ /^[[:blank:]]*\| .* \|-[[:blank:]]*$/ { sub(/^[[:blank:]]*\|/, "<div align=\"left\" style=\"float:left; clear:left;\">") sub(/\|-[[:blank:]]*$/, "</div>") } # and right-flush blocks $1 ~ /^[[:blank:]]*-\| .* \|[[:blank:]]*$/ { sub(/^[[:blank:]]*-\|/, "<div align=\"right\" style=\"float:right; clear:right;\">") sub(/\|[[:blank:]]*$/, "</div>") } | |
| # boxological tables made with dashes and pluses and vertical # pipes. $1 ~ /^[[:blank:]]*\+[+-]+\+[[:blank:]]*$/ || $1 ~ /^[[:blank:]]*\|/ { fore = "<table class=\"boxology\">" for( i = 1; i <= NF; i++) { | # boxological tables made with dashes and pluses and vertical # pipes. $1 ~ /^[[:blank:]]*\+[+-]+\+[[:blank:]]*$/ || $1 ~ /^[[:blank:]]*\|/ { fore = "<table class=\"boxology\">" for( i = 1; i <= NF; i++) { |
| if($i ~ /^[[:blank:]]*\+[+=]+\+[[:blank:]]*$/) { firstrow = "true" } } for( i = 1; i <= NF; i++) { if($i ~ /^[[:blank:]]*\+[+=]+\+[[:blank:]]*$/) { firstrow = "true" $i = "" } | |
| if($i ~ /^[[:blank:]]*\+[+-]+\+[[:blank:]]*$/) { $i = "" | if($i ~ /^[[:blank:]]*\+[+-]+\+[[:blank:]]*$/) { $i = "" |
| } else if (firstrow == "true") { sub(/^[[:blank:]]*\|/, "<tr class=\"boxology\"> <th class=\"boxology\">", $i) sub(/\|[[:blank:]]*$/, "</th> </tr> \n", $i) gsub(/[|+]/, "</th> <th class=\"boxology\">", $i) firstrow = "false" | |
| } else { | } else { |
| sub(/^[[:blank:]]*\|/, "<tr class=\"boxology\"> <td class=\"boxology\">", $i) | if($i ~ /^[[:blank:]]*\|[^|]+\+/) { sub(/^[[:blank:]]*\|/, "<tr class=\"boxology\"> <th class=\"boxology\">", $i) } else { sub(/^[[:blank:]]*\|/, "<tr class=\"boxology\"> <td class=\"boxology\">", $i) } |
| sub(/\|[[:blank:]]*$/, "</td> </tr> \n", $i) gsub(/\|/, "</td> <td class=\"boxology\">", $i) | sub(/\|[[:blank:]]*$/, "</td> </tr> \n", $i) gsub(/\|/, "</td> <td class=\"boxology\">", $i) |
| gsub(/\+/, "</th> <td class=\"boxology\">", $i) | |
| } } aft = "</table>" | } } aft = "</table>" |
| Line 215 | Line 281 |
| sub(/^[[:blank:]]*(>|[\#\|])[[:blank:]]/, "", $i) } gsub(RS, "<p/>") | sub(/^[[:blank:]]*(>|[\#\|])[[:blank:]]/, "", $i) } gsub(RS, "<p/>") |
| fore = fore "<blockquote type=\"cite\">" | fore = fore "<blockquote type=\"cite\" style=\"font-style: italic;\">" |
| aft = "</blockquote> " aft } | aft = "</blockquote> " aft } |
| # Likewise centered blocks. $1 ~ /^[[:blank:]]*-\| .* \|-[[:blank:]]*$/ { sub(/^[[:blank:]]*-\|/, "<div align=\"center\">") sub(/\|-[[:blank:]]*$/, "</div>") } | |
| # lists can have a lot too $1 ~ /^[[:blank:]]+[-\*o[:digit:]\.]+[[:blank:]]/ { indentlevel = 0 | # lists can have a lot too $1 ~ /^[[:blank:]]+[-\*o[:digit:]\.]+[[:blank:]]/ { indentlevel = 0 |
| Line 294 | Line 354 |
| outputfile = outputstem "-" tocname ".html" chapternames[chnum] = outputfile print pagestart > outputfile | outputfile = outputstem "-" tocname ".html" chapternames[chnum] = outputfile print pagestart > outputfile |
| print mainstart > outputfile | |
| } tag = "<h" hlevel "><a name=\"" tocname "\">" closetag = "</a></h" hlevel ">" | } tag = "<h" hlevel "><a name=\"" tocname "\">" closetag = "</a></h" hlevel ">" |
| Line 318 | Line 379 |
| $0 = gensub(/<([^[:space:]]+\.html?)>/, "<a href=\"\\1\">\\1</a>", "g") } | $0 = gensub(/<([^[:space:]]+\.html?)>/, "<a href=\"\\1\">\\1</a>", "g") } |
| # do that funky acronym thing, awk boy { # This is a low-down dirty hack, but at least it doesn't # break so much. for (term in acronyms) { gsub(term, "<acronym title=\"" acronyms[term] "\">" term "</acronym>") #search = "([^[:alnum:]><&]|^)" term "([^[:alnum:]><&]|$)" #while(match($0, search, extras) != 0) { #gsub(extras[1] term extras[2], extras[1] "<acronym title=\"" acronyms[term] "\">" term "</acronym>" extras[2]) #} } } | |
| ## old-style URLs #/\[[^\[]+\]/ { # # images! | ## old-style URLs #/\[[^\[]+\]/ { # # images! |
| Line 336 | Line 410 |
| #sidebars $1 ~ /^[[:space:]]*\[/ && $NF ~ /\][[:space:]]*$/ { | #sidebars $1 ~ /^[[:space:]]*\[/ && $NF ~ /\][[:space:]]*$/ { |
| sub(/<p>/, "<blockquote class=\"sidebar\">", fore) | sub(/<p[^>]*>/, "<blockquote class=\"sidebar\">", fore) |
| sub(/<\/p>/, "</blockquote>", aft) sub(/^[[:space:]]*\[/, "", $1) sub(/\][[:space:]]*$/, "", $NF) } | sub(/<\/p>/, "</blockquote>", aft) sub(/^[[:space:]]*\[/, "", $1) sub(/\][[:space:]]*$/, "", $NF) } |
| #ed. notes $1 ~ /^[[:space:]]*\{/ && $NF ~ /\}[[:space:]]*$/ { | #ed. notes $1 ~ /^[[:space:]]*\{/ && $NF ~ /\}[[:space:]]*$/ { |
| sub(/<p>/, "<blockquote class=\"ednote\">", fore) | sub(/<p[^>]*>/, "<blockquote class=\"ednote\">", fore) |
| sub(/<\/p>/, "</blockquote>", aft) sub(/^[[:space:]]*\{/, "", $1) sub(/\}[[:space:]]*$/, "", $NF) | sub(/<\/p>/, "</blockquote>", aft) sub(/^[[:space:]]*\{/, "", $1) sub(/\}[[:space:]]*$/, "", $NF) |
| Line 353 | Line 428 |
| # emphasis /\*[^\*]+\*/ || /\/[^\/]+\// || /_[^_]+_/ || /{[^}]+}/ { | # emphasis /\*[^\*]+\*/ || /\/[^\/]+\// || /_[^_]+_/ || /{[^}]+}/ { |
| #print "chillin on " $0 $0 = gensub(/([[:space:]_\*])\/([[:punct:][:alpha:]][^\/]+[[:punct:][:alpha:]])\/([[:space:][:punct:]])/, "\\1<em>\\2</em>\\3", "g") $0 = gensub(/([[:space:]_\/])\*([[:punct:][:alpha:]][^\*]+[[:punct:][:alpha:]])\*([[:space:][:punct:]])/, "\\1<strong>\\2</strong>\\3", "g") | $0 = gensub(/([[:space:]_\/])\*([[:punct:][:alpha:]][^\*]+[[:punct:][:alpha:]])\*([[:space:][:punct:]])/, "\\1<em>\\2</em>\\3", "g") |
| $0 = gensub(/([[:space:]\/\*])_([[:punct:][:alpha:]][^_]+[[:punct:][:alpha:]])_([[:space:][:punct:]])/, "\\1<u>\\2</u>\\3", "g") $0 = gensub(/{([^}]+)}/, "<tt>\\1</tt>", "g") } | $0 = gensub(/([[:space:]\/\*])_([[:punct:][:alpha:]][^_]+[[:punct:][:alpha:]])_([[:space:][:punct:]])/, "\\1<u>\\2</u>\\3", "g") $0 = gensub(/{([^}]+)}/, "<tt>\\1</tt>", "g") } |
| Line 368 | Line 441 |
| # print the paragraph now { | # print the paragraph now { |
| print fore $0 aft >> outputfile | print " " fore $0 aft >> outputfile print " " fore $0 aft >> printerfile |
| } # wrap up the indices and finish off the html | } # wrap up the indices and finish off the html |
| Line 380 | Line 454 |
| print "</ol>" >> zootfile } print tocstart >> zootfile | print "</ol>" >> zootfile } print tocstart >> zootfile |
| close("navbar.nav") while((getline navline < "navbar.nav") > 0) { | close("navbar.tron") while((getline navline < "navbar.tron") > 0) { |
| if(navline ~ zootfile "\">") { sub(/class="navbar"/, "class=\"activenavbar\"", navline) } print navline >> zootfile } | if(navline ~ zootfile "\">") { sub(/class="navbar"/, "class=\"activenavbar\"", navline) } print navline >> zootfile } |
| print "</ol>" >> navfile | print "</ol>\n" >> navfile #print "<hr align=\"center\" width=\"25%\"/>\n" >> navfile print "<h4 class=\"navbar\">Other Formats</h4>\n" >> navfile print "<ul class=\"navbar\">\n" >> navfile print "<li class=\"navbar\"><a class=\"navbar\" href=\"" outputstem "_printable.html\">All One File</a></li>\n" >> navfile print "<li class=\"navbar\"><a class=\"navbar\" href=\"" outputstem ".txt\">Plain ASCII Text</a></li>\n" >> navfile print "</ul>\n<br/>\n" >> navfile |
| close(navfile) while((getline navline < navfile) > 0) { print navline >> zootfile | close(navfile) while((getline navline < navfile) > 0) { print navline >> zootfile |
| Line 397 | Line 477 |
| for(i=1; i <= chnum; i++) { zootfile = chapternames[i] print tocstart >> zootfile | for(i=1; i <= chnum; i++) { zootfile = chapternames[i] print tocstart >> zootfile |
| close("navbar.nav") while((getline navline < "navbar.nav") > 0) { | close("navbar.tron") while((getline navline < "navbar.tron") > 0) { |
| print navline >> zootfile } close(navfile) | print navline >> zootfile } close(navfile) |