0

the screenshot I mentionedSo I was experimenting with the terminal in Wsl and happened to enter something that started with "can't" (I don't remember what it was). After that, I entered some sort of note-taking tool or program to execute multiple commands at once.

As you can see, I'm pretty new to Linux and confused as to what "can't" actually does.

I'll add a screenshot in case my explanation confuses you.

UDONTO
  • 47

1 Answers1

0

Bash triggers on can't because of single alone quote inside.

So you entered a single quote ('), say opening quote, the first.
Bash waits for the second one and shows > as temporary prompt to remind you.

Compare the following:

$ x='y
> '
$

with

$ x='y'
$

The same will happen with double quotes.


To understand BASH you have to read the docs like https://tldp.org/LDP/Bash-Beginners-Guide/html/index.html .

N0rbert
  • 99,918