Open tom-seddon opened 3 years ago
Regarding sha1sum
, I forgot it prints the file name!
tmbp ~/tmp % sha1sum nops.zip
0ae585f0e92268eb95a6936d8ed72f3ef1c0ae9f nops.zip
So you'll get the PC name for each Beeb file.
More markup? :( - maybe some regexp hell, or something, like the error mechanism in Emacs. Match each output line with regexp, then group 1 = part to replace with Beeb name, group 2 = somethingsomething (etc., etc.). Bit of a pain, but if Python-style named groups are easy to support, this could actually be quite flexible.
Some kind of mechanism for BBC interop with Unix pipeline tools. Along these lines:
*
command on Beeb, passing afsp,*SHA1SUM X.*
sha1sum
, passing in the PC file names*HELP TOOLS
for a list.Example use cases:
sha1sum
,BBCBasicToText
, etc. - syntax<afsp>
, as abovegrep
- takes 1 fixed position option, then file names afterwardsgrep
- has a zillion other options! What do? Beeb commands never really worked like that, aside from the occasional thing like*ACCESS
. Maybe decide the syntax is<afsp> <string> <options>
? - even though this is then the other way round from the PC.Also: tools that take data via stdin. Some kind of pseudo-file that you can
*SPOOL
to, perhaps? This would be suitable as-is for fire-and-forget tools such aspmacs
. Buffer stdin input, then send it to the tool when the file is closed. One open/write/close operation = one invocation of the tool. BREAK cancels. Is it possible to distinguish terminating*SPOOL
andCLOSE#0
?For attempting to approximate pipelines, maybe buffer tool output after invocation, and allow the pseudo-file to be opened to examine the result. Not sure how useful this would actually be though.
Various options. Config file needed.
(Beeblink should be able to reload the config file while running. Check mtime once per second? Or whatever. Like the USB device autodetection.)