[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH]: (2/2) [bash-style-guide.mdwn]: fix square brackets rendering
From: |
bill-auger |
Subject: |
[PATCH]: (2/2) [bash-style-guide.mdwn]: fix square brackets rendering |
Date: |
Tue, 12 Dec 2023 20:39:51 -0500 |
From ebe3dc520ce26b3dca1281b146b87d924fd551ac Mon Sep 17 00:00:00 2001
From: bill-auger <mr.j.spam.me@gmail.com>
Date: Tue, 12 Dec 2023 19:52:45 -0500
Subject: [PATCH 2/2] [bash-style-guide.mdwn]: fix square brackets rendering
---
sviki/fsf/bash-style-guide.mdwn | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/sviki/fsf/bash-style-guide.mdwn b/sviki/fsf/bash-style-guide.mdwn
index 5f5ffaf..f72d112 100644
--- a/sviki/fsf/bash-style-guide.mdwn
+++ b/sviki/fsf/bash-style-guide.mdwn
@@ -439,13 +439,10 @@ Prefer `$var` except when `${var}` is necessary or adds
clarity, like `"comb${x}
Never use `[`. `[[` is a special syntax which doesn't do variable expansion
and avoids edge cases.
-Note: ikiwiki has trouble formatting the double bracket below, get the
-raw page with `git svn clone --stdlayout
svn://svn.savannah.gnu.org/administration/`
-
```
-[[ "$filename" == *.png ]] # right-hand globs over left-hand - matches
filename with .png extension
+\[[ "$filename" == *.png ]] # right-hand globs over left-hand - matches
filename with .png extension
# Quote only the right-hand side when globbing is not desired.
-[[ "$filename" == "*.png" ]] # matches filename with literal asterisk "*.png"
+\[[ "$filename" == "*.png" ]] # matches filename with literal asterisk "*.png"
```
Use double-equal for string equality, eg: `[[ "$x" == 2 ]]`.
--
2.42.1
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [PATCH]: (2/2) [bash-style-guide.mdwn]: fix square brackets rendering,
bill-auger <=