]> Lady’s Gitweb - Shushe/commitdiff
Disallow backslash in filenames; filter out spaces
authorLady <redacted>
Mon, 22 Jan 2024 01:36:38 +0000 (20:36 -0500)
committerLady <redacted>
Mon, 22 Jan 2024 01:36:38 +0000 (20:36 -0500)
Space characters will break this make·file, so like other characters
which might break it should be filtered out by `find`. Backslashes feel
very fraught, especially under secondary expansion, and should be
dis·allowed for simplicity.

GNUmakefile
README.markdown

index 79049c848aee37ac7e68c97d908f9d41237c8b19..bcaa00d92459bae0c478e8233df8d6b58b14693b 100644 (file)
@@ -145,7 +145,7 @@ MAGICDIR := $(patsubst ./%,%,$(THISDIR)/magic)
 # Configuration of `find´.
 #
 # By default, `find´ will ignore files which begin with a period and those which are likely to cause problems for `make´.
 # Configuration of `find´.
 #
 # By default, `find´ will ignore files which begin with a period and those which are likely to cause problems for `make´.
-FINDRULES := ! '(' '(' -name '[.-]*' -o -name '*[][*?:|$$%\#;]*' ')' -a -prune ')'
+FINDRULES := ! '(' '(' -name '[.-]*' -o -name '*[][*?:|$$%\#\\; ]*' ')' -a -prune ')'
 FINDINCLUDERULES := $(FINDRULES)
 
 # The list of parsers for plaintext file types.
 FINDINCLUDERULES := $(FINDRULES)
 
 # The list of parsers for plaintext file types.
index 3801b7eedeb3ca36e6783cc7f10d4020598502b1..0941b52095f1609285389d7663537562abfa57d6 100644 (file)
@@ -162,7 +162,7 @@ The following additional variables can be used to control the behaviour
   Rules to use with `find` when searching for source files.
   The default ignores files that start with a period or hyphen‐minus
     and those which contain a hash, buck, percent, asterisk, colon,
   Rules to use with `find` when searching for source files.
   The default ignores files that start with a period or hyphen‐minus
     and those which contain a hash, buck, percent, asterisk, colon,
-    semi, eroteme, bracket, or pipe.
+    semi, eroteme, bracket, backslash, or pipe.
 
 - **`FINDINCLUDERULES`:**
   Rules to use with `find` when searching for includes (default:
 
 - **`FINDINCLUDERULES`:**
   Rules to use with `find` when searching for includes (default:
@@ -211,8 +211,8 @@ Source files whose media type does not have an associated X·S·L·T
 **☡ For compatibility with this program, source file·names must not
   contain Ascii white·space, colons (`:`), semis (`;`), pipes (`|`),
   bucks (`$`), percents (`%`), hashes (`#`), asterisks (`*`), brackets
 **☡ For compatibility with this program, source file·names must not
   contain Ascii white·space, colons (`:`), semis (`;`), pipes (`|`),
   bucks (`$`), percents (`%`), hashes (`#`), asterisks (`*`), brackets
-  (`[` or `]`), erotemes (`?`), or control characters, and must not
-  begin with a hyphen‐minus (`-`).**
+  (`[` or `]`), erotemes (`?`), backslashes (`\`), or control
+  characters, and must not begin with a hyphen‐minus (`-`).**
 The former characters have the potential to conflict with make syntax,
   and a leading hyphen‐minus is confusable for a command‐line argument.
 
 The former characters have the potential to conflict with make syntax,
   and a leading hyphen‐minus is confusable for a command‐line argument.
 
This page took 0.029275 seconds and 4 git commands to generate.