97

When I execute a script in a Linux shell, I get this output:

dquote>

What does this mean?

DimiDak
  • 3,891
  • 2
  • 22
  • 26
Leonardo
  • 1,101
  • 1
  • 7
  • 6

9 Answers9

123

It means you've executed a line of code with only one double-quote character, like this:

echo "Hello

The shell is waiting for the other quote.

RichieHindle
  • 258,929
  • 46
  • 350
  • 392
  • 3
    And I found that CTRL+G was the only way to undo my command. As entering " will execute something you maybe had mistyped. – Pierre Maoui Jun 27 '17 at 14:05
  • I was working in MobaXTerm w/ OhMyZSH shell and this worked perfectly for me. – Roralee Jun 29 '17 at 21:07
  • This worked for me. Just added one more " and pressed enter. – jimmyplaysdrums Jun 15 '19 at 00:39
  • This can also occur in those cases when you use two different type of quotation mark. Therefore it's worth to replace the quotation marks if you copied the command from somewhere else on the net. – Crepkey Sep 07 '21 at 06:45
  • 1
    @PierreMaoui - you should add your as a full-blown answer, as it's the safest way to get out of the situation, and it's easy to miss here in the comments. (And thanks for pointing it out - was exactly what I needed!) – Katie Byers Jan 21 '22 at 20:11
26

If you have an ! in a quoted string like password="this1smyp4ssword!" it will also end with dquote>

Rico Neitzel
  • 806
  • 8
  • 9
12

When you have "dquote>" on terminal, do not worry just press double quotes button on keyboard for EXIT:

"

Screenshot example:

enter image description here

Nameless
  • 4,186
  • 29
  • 29
3
dquote> 

The above prompt surely means that you have to de-quote the starting of the quote, i.e. ", with another quote: ".

Please write a letter i.e another: " in the dquote> prompt.

a stone arachnid
  • 1,250
  • 1
  • 15
  • 27
3

The shell is waiting for the other quote of an unfinished command.

CTRL+G will leave that state and undo the command.

Entering " and pressing enter is an other way to leave but it will execute something you may had mistyped.

Pierre Maoui
  • 5,528
  • 2
  • 24
  • 28
2

If we have an exclamation symbol in the password, for example like password="passwordhas!symbol" it will also end with dquote>

To get rid of dquote, use a single quote, as shown below. password='passwordhas!symbol'

0

NB: check the double quotes in your line are ordinary ASCII double quotes.

I had a command cut from an e-mail, and was getting the 'dquote>' prompt. It turns out the text editors had replaced the final double quote with a double backquote, which can look almost identical. If in doubt, delete and retype all double quotes.

Richard Kirk
  • 109
  • 8
0

Use "Hello world"'!'""

0

Try this ' and enter. it worked for me

Oxkr
  • 1
  • 1
  • As it’s currently written, your answer is unclear. Please [edit] to add additional details that will help others understand how this addresses the question asked. You can find more information on how to write good answers [in the help center](/help/how-to-answer). – Community May 03 '22 at 03:28