Skip to content

Commit 181807f

Browse files
committed
Enhance description of quoting behavior in course-definition.yml by detailing specific escape sequences and clarifying which cases are covered and which are not.
1 parent e1d77f3 commit 181807f

1 file changed

Lines changed: 13 additions & 2 deletions

File tree

course-definition.yml

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -562,7 +562,7 @@ stages:
562562
description_md: |-
563563
In this stage, you'll implement support for quoting with single quotes.
564564
565-
Characters enclosed in single quotes are interpreted literally, with no special treatment. Read more about quoting with single quotes [here](https://www.gnu.org/software/bash/manual/bash.html#Single-Quotes).
565+
Every character within single quotes is interpreted literally, with no special treatment. Read more about quoting with single quotes [here](https://www.gnu.org/software/bash/manual/bash.html#Single-Quotes).
566566
567567
### Tests
568568
@@ -730,7 +730,18 @@ stages:
730730
description_md: |-
731731
In this stage, you'll implement support for quoting with backslashes within double quotes.
732732
733-
Within double quotes `"`, a backslash escapes the following characters: `\`, `"`, `$`, and a newline. In all other cases, the backslash is treated as a literal character. Read more about quoting with backslashes within double quotes [here](https://www.gnu.org/software/bash/manual/bash.html#Double-Quotes).
733+
Within double quotes `"`, a backslash escapes the following characters: `"`, `\`, `$`, `` ` ``, or newline. Read more about quoting with backslashes within double quotes [here](https://www.gnu.org/software/bash/manual/bash.html#Double-Quotes).
734+
735+
In this stage, we’ll cover:
736+
737+
- `\"` → escapes double quote, allowing " to appear literally within the quoted string
738+
- `\\` → escapes backslash, resultig in a literal \
739+
740+
We won’t cover the following cases in this stage:
741+
742+
- `\$` → escapes the dollar sign, preventing variable expansion
743+
- `` \` `` → escapes the backtick, preventing command substitution
744+
- `\<newline>` → escapes a newline character, allowing line continuation
734745
735746
### Tests
736747

0 commit comments

Comments
 (0)