Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to use `amp;` & `gt;` commands in linux-shell?

I downloaded a Bash script from Internet. However, when I try to run it, it fails because of the && commands and prints the following error message:

No command 'amp' found

What is amp ? What is gt ? What do they do?

like image 643
user3523781 Avatar asked Apr 11 '14 13:04

user3523781


People also ask

How do you use the amp simulator?

A PC can be used as a guitar amp by installing an amp sim (guitar amp simulator). Then, connect your guitar to an audio interface input, and the audio interface via USB to the PC running the amp sim. Finally, connect speakers or headphones to the audio interface output, for a working guitar amp.


3 Answers

I suspect this has undergone an HTML entity translation. You want to reverse this e.g.

& becomes &

and

> becomes >

So (for example)

cd /dir && ls > filename

would become

cd /dir && ls > filename
like image 155
Brian Agnew Avatar answered Oct 02 '22 21:10

Brian Agnew


in other word, & is the character reference for "An ampersand". While gt is simply we call it as (greater than).

like image 41
Ling Loeng Avatar answered Oct 02 '22 23:10

Ling Loeng


&amp and &gt are html escape codes for & and > respectively.

Either you have downloaded a script that has been htmlized, or you've accidentally downloaded a webpage with the script on.

Check the top line of the file. if it starts with something like #!/usr/bin/bash then it's the former and you just need to reverse the changes. If it has something like a <html> tag as the start, then you've downloaded the webpage - go back to where you got it and look for something like a 'raw' link

like image 43
Oliver Matthews Avatar answered Oct 02 '22 23:10

Oliver Matthews