From 79c227155bb8fda89c3cd8ff5367687b47a0f074 Mon Sep 17 00:00:00 2001 From: Jeffrey Armstrong Date: Fri, 20 Jun 2025 06:32:41 -0400 Subject: Added batch file and files routines for running on modern Windows under PC-Basic. Added textile workaround for PC-Basic bug. Added ability to use long filenames, specifically using html as an extension, if LFN=1 is set, though PC-Basic doesn't allow it anyways. --- go-w32.bat | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 go-w32.bat (limited to 'go-w32.bat') diff --git a/go-w32.bat b/go-w32.bat new file mode 100644 index 0000000..8dd01ff --- /dev/null +++ b/go-w32.bat @@ -0,0 +1,40 @@ +ECHO OFF +ECHO GW-Blog by Jeff Armstrong + +IF NOT EXIST %1\POSTHDR.HTM GOTO NOLABEL +ECHO 1 SITEDIR$="%1":LFN=1 >> LOC.BAS + +ECHO -- +ECHO Creating the main BASIC program +COPY LOC.BAS+GWBLOG.BAS+RSS.BAS+DATE.BAS+POST.BAS+TXTILE.BAS+TMPLATE.BAS BLOG.TMP +COPY BLOG.TMP+FILESW32.BAS+TSORT.BAS+LINK.BAS+COPY.BAS+CONFIG.BAS BLOG.BAS +DEL BLOG.TMP +ECHO -- +ECHO Launching GW-Blog Using PC-Basic +pcbasic BLOG.BAS --interface=cli --shell=cmd.exe -f=20 +ECHO -- +ECHO Performing cleanup +DEL LOC.BAS +DEL BLOG.BAS + +GOTO CASING + +:NOLABEL +ECHO Usage: GO.BAT [absolute path to blog files] +ECHO -- +ECHO Blog directory should contain: +ECHO PAGES\ - Static pages for the blog +ECHO POSTS\ - Date-encoded posts for the blog +ECHO POSTHDR.HTM - HTML header with template tags +ECHO POSTFTR.HTM - HTML footer with template tags +ECHO -- +GOTO DONE + +:CASING +ECHO Converting output to lowercase +SET CurrentDir=%CD% +CD %1\build +for /f "Tokens=*" %%f in ('dir /l/b/a-d') do (rename "%%f" "%%f") +CD %CurrentDir% + +:DONE -- cgit v1.2.3