From 361cdd941ea5eaf9b5656f13c4776285582c2849 Mon Sep 17 00:00:00 2001 From: Jeremy Rand Date: Tue, 13 Apr 2021 23:53:20 -0400 Subject: [PATCH] Add a readme and license file. --- LICENSE | 21 +++++++++++++++++++++ README.md | 7 +++++++ md2teach.xcodeproj/project.pbxproj | 4 ++++ md2teach/main.c | 2 ++ 4 files changed, 34 insertions(+) create mode 100644 LICENSE create mode 100644 README.md diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..97a368b --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2020 Jeremy Rand + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..cf29504 --- /dev/null +++ b/README.md @@ -0,0 +1,7 @@ +# md2teach + +This repository is work-in-progress to try to use [md4c](https://github.com/mity/md4c) to create a markdown to Teach text converter ORCA shell program for the Apple //GS. You should not try to use this tool because it doesn't work yet. + +The goal really is to use this shell command from GoldenGate as part of my [Apple2GSBuildPipeline](https://github.com/jeremysrand/Apple2GSBuildPipeline) in order to write documentation for GS projects in a more modern file format. Also, markdown is trivial to commit to git repositories but the presence of the resource fork in Teach files make them problematic. + +The files md4c.c and md4c.h are (hopefully) slightly modified versions of the files from the md4c project. It is shocking how portable that code was and it worked almost immediately. I am marking up my changes with the comment tag GS_SPECIFIC. diff --git a/md2teach.xcodeproj/project.pbxproj b/md2teach.xcodeproj/project.pbxproj index 333e338..143d738 100644 --- a/md2teach.xcodeproj/project.pbxproj +++ b/md2teach.xcodeproj/project.pbxproj @@ -49,6 +49,8 @@ 9D6532FC2626240800105D50 /* md2teach.xcscheme */ = {isa = PBXFileReference; lastKnownFileType = text.xml; name = md2teach.xcscheme; path = ../../md2teach.xcodeproj/xcshareddata/xcschemes/md2teach.xcscheme; sourceTree = ""; }; 9D65330B2626246700105D50 /* md4c.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = md4c.h; sourceTree = ""; }; 9D65330C2626246700105D50 /* md4c.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = md4c.c; sourceTree = ""; }; + 9DDFC7B026269D23006D6E71 /* LICENSE */ = {isa = PBXFileReference; lastKnownFileType = text; path = LICENSE; sourceTree = ""; }; + 9DDFC7B126269D3F006D6E71 /* README.md */ = {isa = PBXFileReference; lastKnownFileType = net.daringfireball.markdown; path = README.md; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -65,6 +67,8 @@ 9D6532DD2626240800105D50 = { isa = PBXGroup; children = ( + 9DDFC7B126269D3F006D6E71 /* README.md */, + 9DDFC7B026269D23006D6E71 /* LICENSE */, 9D6532EB2626240800105D50 /* md2teach */, 9D6532E52626240800105D50 /* Products */, ); diff --git a/md2teach/main.c b/md2teach/main.c index f0cb252..710a53e 100644 --- a/md2teach/main.c +++ b/md2teach/main.c @@ -13,6 +13,8 @@ #include "md4c.h" +#pragma memorymodel 1 + // GS_TODO - Scan all of the code looking at uses of int and unsigned and // consider changing them to long and unsigned long if they need to use // numbers > 64K.