my_modules is simply modules now
This commit is contained in:
parent
295ab39024
commit
e0012c3c62
139 changed files with 187 additions and 197 deletions
|
|
@ -12,7 +12,7 @@ indent_style = tab
|
|||
indent_size = 8
|
||||
trim_trailing_whitespace = true
|
||||
|
||||
[my_modules/**.js]
|
||||
[modules/**.js]
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
trim_trailing_whitespace = true
|
||||
|
|
|
|||
16
Gruntfile.js
16
Gruntfile.js
|
|
@ -77,7 +77,7 @@
|
|||
* I added the "prepjs" task to perform the same constant inlining that my old PHP script "inline.php"
|
||||
* used to do as part of the old "jsmachines.net" build process. Unfortunately, Grunt appears to be
|
||||
* a real memory hog, and so "prepjs" had to be disabled until I could resolve that issue (see my notes
|
||||
* in "my_modules/grunts/prepjs/tasks/prepjs.js" for details).
|
||||
* in "modules/grunts/prepjs/tasks/prepjs.js" for details).
|
||||
*
|
||||
* With the current version of the Closure Compiler, I don't see any measurable performance benefit
|
||||
* to doing my own inlining, but I still wanted to port the code, partly in case I discover some benefit
|
||||
|
|
@ -312,7 +312,7 @@ module.exports = function(grunt) {
|
|||
"c1pxsl": {
|
||||
files: [
|
||||
{
|
||||
cwd: "./my_modules/shared/templates/",
|
||||
cwd: "./modules/shared/templates/",
|
||||
src: ["common.css", "common.xsl", "document.css", "document.xsl", "machine.xsl", "manifest.xsl", "outline.xsl"],
|
||||
dest: "versions/c1pjs/<%= pkg.version %>/",
|
||||
expand: true
|
||||
|
|
@ -330,7 +330,7 @@ module.exports = function(grunt) {
|
|||
"pcxsl": {
|
||||
files: [
|
||||
{
|
||||
cwd: "./my_modules/shared/templates/",
|
||||
cwd: "./modules/shared/templates/",
|
||||
src: ["common.css", "common.xsl", "document.css", "document.xsl", "machine.xsl", "manifest.xsl", "outline.xsl"],
|
||||
dest: "versions/pcjs/<%= pkg.version %>/",
|
||||
expand: true
|
||||
|
|
@ -348,7 +348,7 @@ module.exports = function(grunt) {
|
|||
"c1pjs": {
|
||||
files: [
|
||||
{
|
||||
cwd: "./my_modules/c1pjs-client/templates/",
|
||||
cwd: "./modules/c1pjs/templates/",
|
||||
src: ["components.*"],
|
||||
dest: "versions/c1pjs/<%= pkg.version %>/",
|
||||
expand: true
|
||||
|
|
@ -365,7 +365,7 @@ module.exports = function(grunt) {
|
|||
"pcjs": {
|
||||
files: [
|
||||
{
|
||||
cwd: "./my_modules/pcjs-client/templates/",
|
||||
cwd: "./modules/pcjs/templates/",
|
||||
src: ["components.*"],
|
||||
dest: "versions/pcjs/<%= pkg.version %>/",
|
||||
expand: true
|
||||
|
|
@ -398,7 +398,7 @@ module.exports = function(grunt) {
|
|||
run: {
|
||||
"delete-indexes": {
|
||||
options: {cwd: "."},
|
||||
cmd: "./my_modules/htmlout/bin/delete_indexes.sh",
|
||||
cmd: "./modules/htmlout/bin/delete_indexes.sh",
|
||||
args: []
|
||||
},
|
||||
"zipify-demos": {
|
||||
|
|
@ -438,8 +438,8 @@ module.exports = function(grunt) {
|
|||
grunt.loadNpmTasks("grunt-run");
|
||||
grunt.loadNpmTasks("grunt-text-replace");
|
||||
|
||||
grunt.loadTasks("my_modules/grunts/manifester/tasks");
|
||||
grunt.loadTasks("my_modules/grunts/prepjs/tasks");
|
||||
grunt.loadTasks("modules/grunts/manifester/tasks");
|
||||
grunt.loadTasks("modules/grunts/prepjs/tasks");
|
||||
|
||||
grunt.registerTask("preCompiler", grunt.option("rebuild")? ["concat:tmp-c1pjs", "concat:tmp-pcjs"] : ["newer:concat:tmp-c1pjs", "newer:concat:tmp-pcjs"]);
|
||||
|
||||
|
|
|
|||
22
README.md
22
README.md
|
|
@ -63,9 +63,9 @@ operation.
|
|||
The project includes:
|
||||
|
||||
- A simple Node-based web server ([server.js](server.js))
|
||||
- Custom Node modules used by the web server ([HTMLOut](my_modules/htmlout/), [MarkOut](my_modules/markout/), [DiskDump](my_modules/diskdump/), [FileDump](my_modules/filedump/))
|
||||
- Custom Node modules used by the web server ([HTMLOut](modules/htmlout/), [MarkOut](modules/markout/), [DiskDump](modules/diskdump/), [FileDump](modules/filedump/))
|
||||
- A variety of IBM PC and C1P configuration and resource files (see [/apps](apps/), [/devices](devices/) and [/disks](disks/))
|
||||
- The [PCjs](my_modules/pcjs-client/lib/) and [C1Pjs](my_modules/c1pjs-client/lib/) client applications, both "compiled" and uncompiled
|
||||
- The [PCjs](modules/pcjs/lib/) and [C1Pjs](modules/c1pjs/lib/) client applications, both "compiled" and uncompiled
|
||||
- A smattering of [PCjs](docs/pcjs/) and [C1Pjs](docs/c1pjs/) documentation, along with [blog posts](blog/), related [publications](pubs/) and more
|
||||
|
||||
The bundled web server is not strictly required. Any web server (Node, Apache, Nginx, etc) that can serve the necessary
|
||||
|
|
@ -77,7 +77,7 @@ included in the project, but unless all the resource files are moved into a sing
|
|||
[Demos](/docs/pcjs/demos/)), your browser will probably be unable to load all of them, due to security restrictions.
|
||||
Using the bundled web server is the preferred solution.
|
||||
|
||||
The project includes a large selection of disk images, and a powerful [DiskDump](my_modules/diskdump/) utility that
|
||||
The project includes a large selection of disk images, and a powerful [DiskDump](modules/diskdump/) utility that
|
||||
runs on both the client and server, featuring a command-line interface (CLI) and web server API. Originally created to dump
|
||||
existing disk images as JSON, **DiskDump** has evolved into a full-featured disk image generator, capable of creating PC-compatible
|
||||
diskette *and* hard disk images from either lists *or* directories of files (including all subdirectories).
|
||||
|
|
@ -189,7 +189,7 @@ Using PCjs
|
|||
The PCjs web server is little more than a file/directory browser for the PCjs project, plus a collection of APIs.
|
||||
|
||||
If a URL corresponds to a PCjs project folder and no "index.html" exists in that folder, the server loads an HTML
|
||||
template ([common.html](my_modules/shared/templates/common.html)) and generates an "index.html" for that folder.
|
||||
template ([common.html](modules/shared/templates/common.html)) and generates an "index.html" for that folder.
|
||||
|
||||
The contents of the "index.html" will vary depending on the contents of the folder; for example, if the folder
|
||||
contains a README.md, then that file is converted to HTML and embedded in the "index.html". Similarly, if the folder
|
||||
|
|
@ -200,16 +200,16 @@ contains a machine XML file, that is embedded as well.
|
|||
The PCjs client app can also be run from the command-line mode using Node, making it possible to script the application,
|
||||
run a series of automated tests, etc:
|
||||
|
||||
cd my_modules/pcjs-client/bin
|
||||
cd modules/pcjs/bin
|
||||
node pcjs
|
||||
|
||||
The [pcjs](my_modules/pcjs-client/bin/pcjs) script in [my_modules/pcjs-client/bin](my_modules/pcjs-client/bin) loads
|
||||
The [pcjs](modules/pcjs/bin/pcjs) script in [modules/pcjs/bin](modules/pcjs/bin) loads
|
||||
all the PCjs browser scripts listed in the root [package.json](/package.json) and then starts a Node REPL ("read-eval-print loop").
|
||||
The REPL handles a few special commands (eg, "load", "quit") and passes anything else to the PCjs Debugger component.
|
||||
If no Debugger component has been created yet, or if the Debugger didn't recognize the command, then it's passed on to *eval()*,
|
||||
like a good little REPL.
|
||||
|
||||
Use the "load" command to load a JSON machine configuration file. A sample [machine.json](my_modules/pcjs-client/bin/machine.json)
|
||||
Use the "load" command to load a JSON machine configuration file. A sample [machine.json](modules/pcjs/bin/machine.json)
|
||||
is provided in the *bin* directory, which is a "JSON-ified" version of the [machine.xml](devices/pc/machine/5150/mda/64kb/machine.xml)
|
||||
displayed on the [pcjs.org](/) home page.
|
||||
|
||||
|
|
@ -242,7 +242,7 @@ Debugging PCjs
|
|||
|
||||
### Server Components
|
||||
|
||||
To help test/debug changes to PCjs server components (eg, [DiskDump](my_modules/diskdump/), [HTMLOut](my_modules/htmlout/)),
|
||||
To help test/debug changes to PCjs server components (eg, [DiskDump](modules/diskdump/), [HTMLOut](modules/htmlout/)),
|
||||
you can start the server with some additional options; eg:
|
||||
|
||||
node server.js --logging --console --debug
|
||||
|
|
@ -320,14 +320,14 @@ closer to being released.
|
|||
In the course of testing PCjs, there may be stale "index.html" files that prevent you from seeing application
|
||||
updates, changes to README.md files, etc. So before running Node, you may want to "touch" the default HTML template:
|
||||
|
||||
touch my_modules/shared/templates/common.html
|
||||
touch modules/shared/templates/common.html
|
||||
|
||||
The [HTMLOut](my_modules/htmlout/) module compares the timestamp of that template file to the timestamp of any
|
||||
The [HTMLOut](modules/htmlout/) module compares the timestamp of that template file to the timestamp of any
|
||||
"index.html" and will regenerate the latter if it's out-of-date.
|
||||
|
||||
There's a TODO to expand that check to include the timestamp of any local README.md file, but there are many other
|
||||
factors that can contribute to stale "index.html" files, so usually the safest thing to do is "touch" the
|
||||
[common.html](my_modules/shared/templates/common.html) template, or delete all existing "index.html" files, either
|
||||
[common.html](modules/shared/templates/common.html) template, or delete all existing "index.html" files, either
|
||||
manually or with the Grunt "clean" task:
|
||||
|
||||
grunt clean
|
||||
|
|
|
|||
|
|
@ -1,12 +1,12 @@
|
|||
Build Tools
|
||||
---
|
||||
This is where all the server-side PHP code used to reside. I've since deleted that code from the project,
|
||||
because it's all been ported to JavaScript as a collection of [Node Modules](/my_modules/); e.g.:
|
||||
because it's all been ported to JavaScript as a collection of [Node Modules](/modules/); e.g.:
|
||||
|
||||
- [HTMLOut](/my_modules/htmlout/)
|
||||
- [MarkOut](/my_modules/markout/)
|
||||
- [DiskDump](/my_modules/diskdump/)
|
||||
- [FileDump](/my_modules/filedump/)
|
||||
- [HTMLOut](/modules/htmlout/)
|
||||
- [MarkOut](/modules/markout/)
|
||||
- [DiskDump](/modules/diskdump/)
|
||||
- [FileDump](/modules/filedump/)
|
||||
|
||||
All that remains here is the version of Google's Closure Compiler (and its associated [README](README)) used
|
||||
to build the client-side JavaScript files -- not because I have any attachment to this particular version, but because
|
||||
|
|
|
|||
|
|
@ -83,7 +83,7 @@ define class constants.
|
|||
While we're talking about constants, it's important to be aware of constants that are not scoped to
|
||||
any particular component.
|
||||
|
||||
In [/my_modules/shared/lib/defines.js](/my_modules/shared/lib/defines.js), **DEBUG** is set to **TRUE**,
|
||||
In [/modules/shared/lib/defines.js](/modules/shared/lib/defines.js), **DEBUG** is set to **TRUE**,
|
||||
enabling all debug-only code by default. It is also declared as a *@define* so that the Closure Compiler can
|
||||
override it, setting it to **FALSE** and disabling debug-only code.
|
||||
|
||||
|
|
@ -101,8 +101,8 @@ However, calls to debug-only instance methods seem to be more problematic, so al
|
|||
|
||||
if (DEBUG) this.log('load("' + sFileURL + '")');
|
||||
|
||||
There are a number of other important shared constants in [/my_modules/shared/lib/defines.js](/my_modules/shared/lib/defines.js)
|
||||
and PCjs-specific constants in [/my_modules/pcjs-client/lib/defines.js](/my_modules/pcjs-client/lib/defines.js); refer
|
||||
There are a number of other important shared constants in [/modules/shared/lib/defines.js](/modules/shared/lib/defines.js)
|
||||
and PCjs-specific constants in [/modules/pcjs/lib/defines.js](/modules/pcjs/lib/defines.js); refer
|
||||
to those files for more information.
|
||||
|
||||
### Braces and Parentheses
|
||||
|
|
|
|||
|
|
@ -5,12 +5,12 @@ The [IBM PC AT "Rev 3"](/devices/pc/machine/5170/ega/1152kb/rev3/) machine confi
|
|||
v1.15.5 of PCjs now, which includes the following fixes:
|
||||
|
||||
+ The BIOS expects memory refresh to occur roughly every 16us, which I've resolved by tying the state
|
||||
of the refresh bit in port 0x61 to bit 6 of the CPU cycle count (see *in8042RWReg()* in [chipset.js](/my_modules/pcjs-client/lib/chipset.js));
|
||||
of the refresh bit in port 0x61 to bit 6 of the CPU cycle count (see *in8042RWReg()* in [chipset.js](/modules/pcjs/lib/chipset.js));
|
||||
the original AT BIOS was satisfied with a refresh bit that merely alternated, whereas the new AT BIOS
|
||||
is much more particular about the rate at which that bit changes, since many hard-coded delay-loops have
|
||||
now been replaced with code that waits for a specific number of refresh cycles.
|
||||
+ The 8042 Keyboard Controller emulation needed a few more tweaks, mainly with respect to what happens
|
||||
when the keyboard's "clock" line is toggled (see *set8042CmdData()* in [chipset.js](/my_modules/pcjs-client/lib/chipset.js)).
|
||||
when the keyboard's "clock" line is toggled (see *set8042CmdData()* in [chipset.js](/modules/pcjs/lib/chipset.js)).
|
||||
+ The Floppy Disk Controller needed to add support for the "READ ID" command, in order for the BIOS
|
||||
"double-stepping" test to work (double-stepping is required on an 80-track drive when attempting to read
|
||||
a 40-track diskette).
|
||||
|
|
@ -23,7 +23,7 @@ with a BIOS that's almost 30 years old.
|
|||
after installing a second hard drive. So, when the CMOS reports only one hard drive installed, the BIOS
|
||||
probes for a second hard drive anyway, and it does so by simply writing the drive number to the ATC's "DRVHD"
|
||||
register and then immediately reading the "STATUS" register, without issuing any intervening command.
|
||||
It was an easy fix to *outATCDrvHd()* in [hdc.js](/my_modules/pcjs-client/lib/hdc.js), but I was surprised
|
||||
It was an easy fix to *outATCDrvHd()* in [hdc.js](/modules/pcjs/lib/hdc.js), but I was surprised
|
||||
to discover that the ATC had this behavior, and now I'm wondering how many other I/O operations require
|
||||
immediate "STATUS" register updates.
|
||||
|
||||
|
|
|
|||
|
|
@ -6,8 +6,8 @@
|
|||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="initial-scale=1">
|
||||
<link rel="shortcut icon" type="image/x-icon" href="../../../../../../versions/images/current/favicon.ico">
|
||||
<link rel="stylesheet" type="text/css" href="../../../../../../my_modules/shared/templates/common.css">
|
||||
<link rel="stylesheet" type="text/css" href="../../../../../../my_modules/c1pjs-client/templates/components.css">
|
||||
<link rel="stylesheet" type="text/css" href="../../../../../../modules/shared/templates/common.css">
|
||||
<link rel="stylesheet" type="text/css" href="../../../../../../modules/c1pjs/templates/components.css">
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
|
@ -52,26 +52,26 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/shared/lib/defines.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/shared/lib/dumpapi.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/shared/lib/reportapi.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/shared/lib/strlib.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/shared/lib/usrlib.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/shared/lib/weblib.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/shared/lib/component.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/c1pjs-client/lib/defines.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/c1pjs-client/lib/panel.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/c1pjs-client/lib/cpu.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/c1pjs-client/lib/rom.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/c1pjs-client/lib/ram.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/c1pjs-client/lib/keyboard.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/c1pjs-client/lib/video.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/c1pjs-client/lib/serial.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/c1pjs-client/lib/disk.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/c1pjs-client/lib/debugger.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/c1pjs-client/lib/computer.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../my_modules/shared/lib/embed.js"></script>
|
||||
<script type="text/javascript">window.embedC1P("c1p8kb","local.xml","../../../../../../my_modules/c1pjs-client/templates/components.xsl");</script>
|
||||
<script type="text/javascript" src="../../../../../../modules/shared/lib/defines.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../modules/shared/lib/dumpapi.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../modules/shared/lib/reportapi.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../modules/shared/lib/strlib.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../modules/shared/lib/usrlib.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../modules/shared/lib/weblib.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../modules/shared/lib/component.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../modules/c1pjs/lib/defines.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../modules/c1pjs/lib/panel.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../modules/c1pjs/lib/cpu.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../modules/c1pjs/lib/rom.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../modules/c1pjs/lib/ram.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../modules/c1pjs/lib/keyboard.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../modules/c1pjs/lib/video.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../modules/c1pjs/lib/serial.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../modules/c1pjs/lib/disk.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../modules/c1pjs/lib/debugger.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../modules/c1pjs/lib/computer.js"></script>
|
||||
<script type="text/javascript" src="../../../../../../modules/shared/lib/embed.js"></script>
|
||||
<script type="text/javascript">window.embedC1P("c1p8kb","local.xml","../../../../../../modules/c1pjs/templates/components.xsl");</script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@ Pre-generated disk images are preferred to dynamically-generated images, and you
|
|||
<link href="http://www.bricklin.com/history/vclicense.htm">VisiCalc License</link>
|
||||
</disk>
|
||||
|
||||
The PCjs [DiskDump](/my_modules/diskdump/) module is used to create all our pre-generated JSON-encoded disk images.
|
||||
The PCjs [DiskDump](/modules/diskdump/) module is used to create all our pre-generated JSON-encoded disk images.
|
||||
In the above example, a pre-generated disk image could be created from the command-line with either the "--dir" option
|
||||
(which will traverse all subdirectories as well):
|
||||
|
||||
|
|
|
|||
|
|
@ -3,6 +3,6 @@ Microsoft C Compiler v4.00
|
|||
|
||||
[Manifest](manifest.xml) updated using:
|
||||
|
||||
find -L private -name "*" -type f -exec node ../../../../../../my_modules/diskdump/bin/diskdump --format=json --output=. --manifest --disk={} \;
|
||||
find -L private -name "*" -type f -exec node ../../../../../../modules/diskdump/bin/diskdump --format=json --output=. --manifest --disk={} \;
|
||||
|
||||
The original diskettes are not part of the repository/website.
|
||||
The original diskettes are not part of the repository/website.
|
||||
|
|
|
|||
|
|
@ -14,4 +14,4 @@ Manifest Details
|
|||
|
||||
[Manifest](manifest.xml) update using:
|
||||
|
||||
find -L private -name "*" -type f -exec node ../../../../../my_modules/diskdump/bin/diskdump --format=json --output=. --manifest --title="SCO Xenix 8086 Operating System v2.1.3" --disk={} \;
|
||||
find -L private -name "*" -type f -exec node ../../../../../modules/diskdump/bin/diskdump --format=json --output=. --manifest --title="SCO Xenix 8086 Operating System v2.1.3" --disk={} \;
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<?xml-stylesheet type="text/xsl" href="/my_modules/c1pjs-client/templates/outline-debug.xsl"?>
|
||||
<?xml-stylesheet type="text/xsl" href="/modules/c1pjs/templates/outline-debug.xsl"?>
|
||||
<outline id="osi-6502-overview">
|
||||
<title>C1Pjs</title>
|
||||
<excerpt>The following document describes the C1Pjs source code.</excerpt>
|
||||
|
|
@ -94,4 +94,4 @@
|
|||
but in general, you'll get much better performance -- both load-time and run-time -- by loading a single "compiled" JavaScript file.</p>
|
||||
<p class="noindent"><em>Jeff Parsons<br/>August 28, 2012</em></p>
|
||||
</content>
|
||||
</outline>
|
||||
</outline>
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!-- author="Jeff Parsons (@jeffpar)" website="http://www.pcjs.org/" created="2012-05-05" modified="2013-01-29" license="http://www.gnu.org/licenses/gpl.html" -->
|
||||
<!DOCTYPE xsl:stylesheet [
|
||||
<!-- XSLT understands these entities only: lt, gt, apos, quot, and amp. Other required entities may be defined below (see http://www.pcjs.org/my_modules/shared/templates/entities.dtd). -->
|
||||
<!-- XSLT understands these entities only: lt, gt, apos, quot, and amp. Other required entities may be defined below (see http://www.pcjs.org/modules/shared/templates/entities.dtd). -->
|
||||
]>
|
||||
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
|
||||
<xsl:param name="rootDir" select="''"/>
|
||||
|
|
@ -11,7 +11,7 @@ files/folders.
|
|||
|
||||
For example, from the root directory of the project, you could run:
|
||||
|
||||
node my_modules/diskdump/bin/diskdump --path="apps/pc/1981/visicalc/README.md" --format=img --output=disk.img
|
||||
node modules/diskdump/bin/diskdump --path="apps/pc/1981/visicalc/README.md" --format=img --output=disk.img
|
||||
|
||||
to produce a `disk.img` containing one file, "README.md", which you could then mount on your local operating
|
||||
system *or* inside a PCjs machine.
|
||||
|
|
@ -19,7 +19,7 @@ system *or* inside a PCjs machine.
|
|||
To make the disk image more useful, you might want to download a copy of [VisiCalc](http://www.bricklin.com/history/vcexecutable.htm)
|
||||
into that folder as well, so that you could then run:
|
||||
|
||||
node my_modules/diskdump/bin/diskdump --path="apps/pc/1981/visicalc/vc.com;README.md" --format=img --output=disk.img
|
||||
node modules/diskdump/bin/diskdump --path="apps/pc/1981/visicalc/vc.com;README.md" --format=img --output=disk.img
|
||||
|
||||
to produce a `disk.img` containing both "VC.COM" and "README.md". In fact, this is exactly how the
|
||||
[disk.json](/apps/pc/1981/visicalc/disk.json) stored in the [VisiCalc](/apps/pc/1981/visicalc/) folder was generated.
|
||||
|
|
@ -47,7 +47,7 @@ var str = require("../../shared/lib/strlib");
|
|||
var usr = require("../../shared/lib/usrlib");
|
||||
var DiskAPI = require("../../shared/lib/diskapi");
|
||||
var DumpAPI = require("../../shared/lib/dumpapi");
|
||||
var X86 = require("../../pcjs-client/lib/x86");
|
||||
var X86 = require("../../pcjs/lib/x86");
|
||||
|
||||
/**
|
||||
* @class exports
|
||||
|
|
@ -292,9 +292,9 @@ DiskDump.aDefaultBPBs = [
|
|||
*
|
||||
* Examples
|
||||
* ---
|
||||
* node my_modules/diskdump/bin/diskdump --disk=../jsmachines/disks/pc/games/infocom/zork1/zork1.dsk
|
||||
* node my_modules/diskdump/bin/diskdump --dir=./apps/pc/1981/visicalc/ --format=img --output=./apps/pc/1981/visicalc/disk.img
|
||||
* node my_modules/diskdump/bin/diskdump --path=./apps/pc/1981/visicalc/bin/vc.com;../README.md --format=json --output=./apps/pc/1981/visicalc/disk.json
|
||||
* node modules/diskdump/bin/diskdump --disk=../jsmachines/disks/pc/games/infocom/zork1/zork1.dsk
|
||||
* node modules/diskdump/bin/diskdump --dir=./apps/pc/1981/visicalc/ --format=img --output=./apps/pc/1981/visicalc/disk.img
|
||||
* node modules/diskdump/bin/diskdump --path=./apps/pc/1981/visicalc/bin/vc.com;../README.md --format=json --output=./apps/pc/1981/visicalc/disk.json
|
||||
*/
|
||||
DiskDump.CLI = function()
|
||||
{
|
||||
|
|
@ -4,19 +4,19 @@
|
|||
*
|
||||
* Copyright (c) 2014 jeffpar
|
||||
* Licensed under the MIT license.
|
||||
*
|
||||
*
|
||||
* Genesis:
|
||||
*
|
||||
* sudo npm install -g grunt-init
|
||||
* git clone git://github.com/gruntjs/grunt-init-gruntplugin.git ~/.grunt-init/gruntplugin
|
||||
* cd ~/Sites/pcjs/my_modules
|
||||
* cd ~/Sites/pcjs/modules
|
||||
* mkdir -p grunts/prepjs
|
||||
* cd grunts/prepjs
|
||||
* grunt-init gruntplugin
|
||||
* npm install
|
||||
*
|
||||
*
|
||||
* This file was generated at the "grunt-init gruntplugin" stage. Here's what that process looked like:
|
||||
*
|
||||
*
|
||||
* Running "init:gruntplugin" (init) task
|
||||
* This task will create one or more files in the current directory, based on the
|
||||
* environment and the answers to a few questions. Note that answering "?" to any
|
||||
|
|
@ -31,9 +31,9 @@
|
|||
* [?] Project name (grunt-prep) grunt-prepjs
|
||||
* [?] Description (The best Grunt plugin ever.) JS Preprocessor
|
||||
* [?] Version (0.1.0)
|
||||
* [?] Project git repository (git://github.com/jeffpar/jsmachines.git)
|
||||
* [?] Project homepage (https://github.com/jeffpar/jsmachines)
|
||||
* [?] Project issues tracker (https://github.com/jeffpar/jsmachines/issues)
|
||||
* [?] Project git repository (git://github.com/jeffpar/jsmachines.git)
|
||||
* [?] Project homepage (https://github.com/jeffpar/jsmachines)
|
||||
* [?] Project issues tracker (https://github.com/jeffpar/jsmachines/issues)
|
||||
* [?] Licenses (MIT)
|
||||
* [?] Author name (jeffpar)
|
||||
* [?] Author email (jeffpar@mac.com)
|
||||
|
|
@ -63,17 +63,17 @@
|
|||
* http://gruntjs.com/getting-started
|
||||
*
|
||||
* Done, without errors.
|
||||
*
|
||||
*
|
||||
* The process was a bit sloppy about trailing commas, though. I've cleaned those up, thanks to PhpStorm.
|
||||
*
|
||||
*
|
||||
* Online tutorials further recommended the following in my project's root:
|
||||
*
|
||||
* npm install my_modules/grunts/prepjs --save-dev
|
||||
*
|
||||
*
|
||||
* npm install modules/grunts/prepjs --save-dev
|
||||
*
|
||||
* However, all that does is make another copy of my "grunt-prepjs" module, inside the "node_modules" folders;
|
||||
* I can avoid that by simply including the following in my root Gruntfile.js:
|
||||
*
|
||||
* grunt.loadTasks("my_modules/grunts/prepjs/tasks");
|
||||
*
|
||||
* grunt.loadTasks("modules/grunts/prepjs/tasks");
|
||||
*/
|
||||
|
||||
'use strict';
|
||||
|
|
@ -132,7 +132,7 @@ var sServerRoot = "/Users/Jeff/Sites/pcjs";
|
|||
* template to use.
|
||||
*/
|
||||
var sDefaultFile = "index.html";
|
||||
var sTemplateFile = "./my_modules/shared/templates/common.html";
|
||||
var sTemplateFile = "./modules/shared/templates/common.html";
|
||||
|
||||
/*
|
||||
* sReadMeFile is the default markdown file to load and convert to HTML when a "readme" token is detected in an
|
||||
|
|
@ -203,8 +203,7 @@ var asFilesNonListed = [
|
|||
"robots.txt",
|
||||
"machine.xml",
|
||||
"manifest.xml",
|
||||
"cache.manifest",
|
||||
"my_modules"
|
||||
"cache.manifest"
|
||||
];
|
||||
|
||||
var asExtsNonListed = [
|
||||
|
|
@ -219,7 +218,6 @@ var asFilesNonServed = [
|
|||
"bin",
|
||||
"debug",
|
||||
"grunts",
|
||||
"lib",
|
||||
"logs",
|
||||
"node.log",
|
||||
"node_modules",
|
||||
|
|
@ -375,7 +373,7 @@ function HTMLOut(sDir, sFile, fRebuild, req, done)
|
|||
*
|
||||
* Examples:
|
||||
*
|
||||
* node my_modules/htmlout/bin/htmlout --dir=/ --console --rebuild
|
||||
* node modules/htmlout/bin/htmlout --dir=/ --console --rebuild
|
||||
*/
|
||||
HTMLOut.CLI = function()
|
||||
{
|
||||
|
|
@ -916,12 +914,12 @@ HTMLOut.prototype.getVersion = function(sToken, sIndent, aParms)
|
|||
* then we should be using "current" CSS and template files (as opposed to version-specific template files).
|
||||
*
|
||||
* NOTE: I used to create a symlink in each app's "versions" directory (eg, /versions/pcjs/current ->
|
||||
* ../../my_modules/shared/templates), so that when fDebug was true, I could simply insert "current" in
|
||||
* ../../modules/shared/templates), so that when fDebug was true, I could simply insert "current" in
|
||||
* place of a version number. However, that symlink didn't get added to the repository, and I'm not sure
|
||||
* all operating systems would deal with it properly even if was added, so now I'm treating the "version"
|
||||
* token as the equivalent of a symlink here.
|
||||
*/
|
||||
this.aTokens[sToken] = this.fDebug? "../../my_modules/shared/templates" : pkg.version;
|
||||
this.aTokens[sToken] = this.fDebug? "../../modules/shared/templates" : pkg.version;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -1341,7 +1339,7 @@ HTMLOut.prototype.getMachineXML = function(sToken, sIndent, aParms, sXMLFile, sS
|
|||
var sStyleSheet = aMatch[1];
|
||||
/*
|
||||
* Recognized machine stylesheets are either "production" stylesheets in ("/versions/pcjs"|"/versions/c1pjs")
|
||||
* or "development" stylesheets in ("/my_modules/pcjs-client/templates"|"/my_modules/c1pjs-client/templates").
|
||||
* or "development" stylesheets in ("/modules/pcjs/templates"|"/modules/c1pjs/templates").
|
||||
*
|
||||
* The common denominator in both sets is either "/pc" or "/c1p", which in turn indicates the class of machine
|
||||
* (ie, "PC" or "C1P").
|
||||
|
|
@ -1687,7 +1685,7 @@ HTMLOut.prototype.getReadMe = function(sToken, sIndent, aParms, sPrevious)
|
|||
*/
|
||||
HTMLOut.prototype.getSocketScripts = function(sToken, sIndent, aParms)
|
||||
{
|
||||
this.aTokens[sToken] = (fSockets? '<script type="text/javascript" src="/socket.io/socket.io.js"></script>\n' + sIndent + '<script type="text/javascript" src="/my_modules/shared/lib/sockets.js"></script>' : "");
|
||||
this.aTokens[sToken] = (fSockets? '<script type="text/javascript" src="/socket.io/socket.io.js"></script>\n' + sIndent + '<script type="text/javascript" src="/modules/shared/lib/sockets.js"></script>' : "");
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -1805,7 +1803,7 @@ HTMLOut.prototype.processMachines = function(aMachines, done)
|
|||
* Step 1: We need to find the client's "defines.js" source file, and follow it with "nodebugger.js".
|
||||
*/
|
||||
for (i = 0; i < asFiles.length; i++) {
|
||||
if (asFiles[i].indexOf("-client/lib/defines.js") >= 0) {
|
||||
if (asFiles[i].indexOf("js/lib/defines.js") >= 0) {
|
||||
asFiles.splice(i + 1, 0, asFiles[i].replace("defines.js", "nodebugger.js"));
|
||||
break;
|
||||
}
|
||||
|
|
@ -141,7 +141,7 @@ function MarkOut(sMD, sIndent, req, aParms, fDebug)
|
|||
*
|
||||
* Examples:
|
||||
*
|
||||
* node my_modules/markout/bin/markout --file=/my_modules/grunts/prepjs/README.md --debug
|
||||
* node modules/markout/bin/markout --file=/modules/grunts/prepjs/README.md --debug
|
||||
*/
|
||||
MarkOut.CLI = function()
|
||||
{
|
||||
|
|
@ -951,7 +951,7 @@ MarkOut.prototype.convertMDMachineLinks = function(sBlock)
|
|||
*/
|
||||
if (!sMachineXSLFile || sMachineXSLFile.indexOf("components.xsl") >= 0) {
|
||||
if (this.fDebug) {
|
||||
sMachineXSLFile = "/my_modules/" + sMachineClass + "js-client/templates/components.xsl";
|
||||
sMachineXSLFile = "/modules/" + sMachineClass + "js/templates/components.xsl";
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -1014,7 +1014,7 @@ MarkOut.prototype.convertMDEmphasis = function(sBlock)
|
|||
*
|
||||
* but we do not. That's because a Markdown link like:
|
||||
*
|
||||
* [my_modules](/my_modules/)
|
||||
* [modules](/modules/)
|
||||
*
|
||||
* would otherwise be misconstrued as containing emphasis (and it doesn't
|
||||
* matter whether we process emphasis BEFORE or AFTER links -- an HTML link
|
||||
|
|
@ -1025,11 +1025,11 @@ MarkOut.prototype.convertMDEmphasis = function(sBlock)
|
|||
* be whitespace, but we make it a bit more flexible, so that you can do things
|
||||
* like place emphasis INSIDE links:
|
||||
*
|
||||
* [*my_modules*](/my_modules/)
|
||||
* [*modules*](/modules/)
|
||||
*
|
||||
* or OUTSIDE links:
|
||||
*
|
||||
* *[my_modules](/my_modules/)*
|
||||
* *[modules](/modules/)*
|
||||
*/
|
||||
if (sBlock.indexOf('*') >= 0 || sBlock.indexOf('_') >= 0) {
|
||||
sBlock = sBlock.replace(/(^|[^a-z0-9])([\*_])\2([\s\S]*?)\2\2([^a-z0-9]|$)/gi, "$1<strong>$3</strong>$4");
|
||||
|
|
@ -27,32 +27,32 @@ At the time of this writing, the order is:
|
|||
* [shared/usrlib.js](../../shared/lib/usrlib.js)
|
||||
* [shared/weblib.js](../../shared/lib/weblib.js)
|
||||
* [shared/component.js](../../shared/lib/component.js)
|
||||
* [pcjs-client/defines.js](defines.js)
|
||||
* [pcjs-client/panel.js](panel.js)
|
||||
* [pcjs-client/bus.js](bus.js)
|
||||
* [pcjs-client/mem.js](mem.js)
|
||||
* [pcjs-client/cpu.js](cpu.js)
|
||||
* [pcjs-client/x86.js](x86.js)
|
||||
* [pcjs-client/x86seg.js](x86seg.js)
|
||||
* [pcjs-client/x86cpu.js](x86cpu.js)
|
||||
* [pcjs-client/x86grps.js](x86grps.js)
|
||||
* [pcjs-client/x86help.js](x86help.js)
|
||||
* [pcjs-client/x86mods.js](x86mods.js)
|
||||
* [pcjs-client/x86op0f.js](x86op0f.js)
|
||||
* [pcjs-client/x86opxx.js](x86opxx.js)
|
||||
* [pcjs-client/chipset.js](chipset.js)
|
||||
* [pcjs-client/rom.js](rom.js)
|
||||
* [pcjs-client/ram.js](ram.js)
|
||||
* [pcjs-client/keyboard.js](keyboard.js)
|
||||
* [pcjs-client/video.js](video.js)
|
||||
* [pcjs-client/serial.js](serial.js)
|
||||
* [pcjs-client/mouse.js](mouse.js)
|
||||
* [pcjs-client/disk.js](disk.js)
|
||||
* [pcjs-client/fdc.js](fdc.js)
|
||||
* [pcjs-client/hdc.js](hdc.js)
|
||||
* [pcjs-client/debugger.js](debugger.js)
|
||||
* [pcjs-client/state.js](state.js)
|
||||
* [pcjs-client/computer.js](computer.js)
|
||||
* [pcjs/defines.js](defines.js)
|
||||
* [pcjs/panel.js](panel.js)
|
||||
* [pcjs/bus.js](bus.js)
|
||||
* [pcjs/mem.js](mem.js)
|
||||
* [pcjs/cpu.js](cpu.js)
|
||||
* [pcjs/x86.js](x86.js)
|
||||
* [pcjs/x86seg.js](x86seg.js)
|
||||
* [pcjs/x86cpu.js](x86cpu.js)
|
||||
* [pcjs/x86grps.js](x86grps.js)
|
||||
* [pcjs/x86help.js](x86help.js)
|
||||
* [pcjs/x86mods.js](x86mods.js)
|
||||
* [pcjs/x86op0f.js](x86op0f.js)
|
||||
* [pcjs/x86opxx.js](x86opxx.js)
|
||||
* [pcjs/chipset.js](chipset.js)
|
||||
* [pcjs/rom.js](rom.js)
|
||||
* [pcjs/ram.js](ram.js)
|
||||
* [pcjs/keyboard.js](keyboard.js)
|
||||
* [pcjs/video.js](video.js)
|
||||
* [pcjs/serial.js](serial.js)
|
||||
* [pcjs/mouse.js](mouse.js)
|
||||
* [pcjs/disk.js](disk.js)
|
||||
* [pcjs/fdc.js](fdc.js)
|
||||
* [pcjs/hdc.js](hdc.js)
|
||||
* [pcjs/debugger.js](debugger.js)
|
||||
* [pcjs/state.js](state.js)
|
||||
* [pcjs/computer.js](computer.js)
|
||||
* [shared/embed.js](../../shared/lib/embed.js)
|
||||
|
||||
Some of the modules *can* be reordered or even omitted (eg, [debugger.js](debugger.js) or
|
||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue