user3523781 user3523781 - 11 days ago 6
Linux Question

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

i downloaded a script from Internet.
when i run it, it stops because of

&&
command and says
No command 'amp' found


what is
amp
?
what is
gt
?
what does they do?

Answer

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
Comments