]> git.xolatile.top Git - emil-bake.git/commitdiff
Document
authorEmil Williams <emilemilemil@cock.li>
Sat, 4 Jan 2025 21:39:14 +0000 (14:39 -0700)
committerEmil Williams <emilemilemil@cock.li>
Sat, 4 Jan 2025 21:39:14 +0000 (14:39 -0700)
README
bake.1

diff --git a/README b/README
index 53e7498259a2fbbc313c0e0485e9b25bb43f1cd2..d8a09166e1ee234a3b0c10406a9d3d26706f33a7 100755 (executable)
--- a/README
+++ b/README
@@ -10,17 +10,19 @@ install by running ./install.sh
 
 bake [-chln] [-s <n>] <FILENAME> [ARGS...]; version 20240930
 
-Bake is a simple tool meant  to execute embedded shell commands within
-any file.   It executes with /bin/sh  the command after a  "@BAKE " to
-the end of the line (a UNIX newline: '\n') or to the first instance of
-@STOP.
+Bake is a simple tool meant to execute embedded shell commands within
+any file. It executes with /bin/sh the command after a "@BAKE " to
+the end of the line (a UNIX newline: '\n') or to the first instance
+of @STOP. All @BAKE ... @STOP statements must become before any @BAKE
+... EOLs.
 
 It expands some macros,
   @FILENAME @FILE @NAME - filename
   @SHORT                - filename without suffix (abc.x.txt \-> abc.x)
   @SHORT:N              - removes N suffixes, so (a.b.c 2 -> a)
   @ARGS                 - other arguments to the program
-  @ARGS:N               - Provides the Nth argument, starting from 0
+  @ARGS:N               - Provides the Nth argument, starting from
+0
   @ARGS:N+              - All arguments at and after Nth
   @RECURS               - the full path name to the executable
   @LINE                 - line number at the selected @BAKE
@@ -44,17 +46,14 @@ Licensed under the public domain.
 
 Shake
 
-Bake was inspired by the  Bash-based Shake utility (formerly eMake, he
-liked my suggestion  for a name).  It is  included under authorization
-of  its creator.   The  original version  of Shake  may  be found  at:
+Bake was inspired by the Bash-based Shake utility (formerly eMake,
+he liked my suggestion for a name). It is included under authorization
+of its creator. The original version of Shake may be found at:
 <http://bis64wqhh3louusbd45iyj76kmn4rzw5ysawyan5bkxwyzihj67c5lid.onion/anon/shake>
 
-Bake  includes a  modified Shake,  both  after installation  and as  a
-bootstrapper.  The modified version includes all features of Bake with
-the  exceptions  of   multi-line  commands.   It  is   not  a  general
-replacement for Bake.
-
-Shake doesn't support multi-line commands.
+Bake includes a modified Shake, optionally installation and as the
+old bootstrapper. The modified version includes all features of Bake
+with the exceptions of multi-line commands and usable expunge.
 
 Changelog
 
@@ -62,16 +61,17 @@ Bake was created on 2023/09/13, and complete as of 2024/03/02.
 
 2024-09-27
 
-Lex. As adviced  by the original creator, I learned  and implemented a
-Bake with lex. It's fully featured, and has new stuff.
+Lex. As adviced by the original creator, I learned and implemented
+Bake with lex. It's fully featured, and has new stuff.
 
-2024-10-24 - Awake
+2024-10-24
+- Awake
 
-Egor (some dead guy) made a AWK implementation of Bake, it's POSIX.
+Egor (some dead guy) made an AWK implementation of Bake, it's POSIX.
 It doesn't support multi-line, expunge, parses options after filename,
 or changing directory to file's directory - it's compatible with Bake
-otherwise.
-
- cd /dir/of/file; awake file
+otherwise. It's the new bootstrapper as AWK should be more portable
+to the BSDs.
 
-See ./awake --help
+cd /dir/of/file; awake file
+See --help
diff --git a/bake.1 b/bake.1
index 209d51822532e40aca6efe8a1d24c1bf855c3c96..241df3026ff642013d5c25ef709321043cf6d61c 100755 (executable)
--- a/bake.1
+++ b/bake.1
@@ -8,9 +8,10 @@
 .SH DESCRIPTION
 
 bake is a simple tool meant to execute embedded shell commands within
-any file.  It executes with /bin/sh the command after a "\fB@BAKE\fP "
-to the end of the line (a UNIX newline: '\fB\\n\fP') or to the first
-instance of @STOP.
+any file. It executes with /bin/sh the command after a "\fB@BAKE\fP
+" to the end of the line (a UNIX newline: '\fB\\n\fP') or to the first
+instance of @STOP. All @BAKE ... @STOP statements must become before
+any @BAKE ... EOLs.
 
 This format may be embedded within \fBany file\fP.
 
@@ -57,11 +58,22 @@ Additional Features And Notes
 
 Shell execution may be disabled with the \fB-n\fP or \fB--dry-run\fP option.
 
-Expunge removes exactly one file specified in the @{TEXT} format, and
-is not recursive. Expunge simply outputs rm 'TEXT...', where text
-expands any instance of ' to \\'.
+Expunge removes exactly one file specified in the @{FILENAME} format,
+and the action is nonrecursive. Expunge simply outputs rm 'FILENAME...',
+where the FILENAME expands any instance of ' to \\'.
+
+.PP
+Other Implementations (NONDEFAULT)
+
+Shake - Bash based, The modified version includes all features with
+the exceptions of multi-line (as in to @STOP), select, and usable expunge.
+
+Awake - AWK based, does not support multi-line (as in to @STOP), expunge,
+parses options after filename, color, or changing directory to file's
+directory - it's compatible with Bake otherwise.
 
 .SH EXAMPLE
+
 .\" SRC BEGIN (example.c)
 .EX
 // example.c @BAKE cc -o @SHORT @NAME @ARGS