terminal mac - bash command not found, permission denied and '&gt' in prompt
The &amp;gt; is a syntax error, apparently caused by HTML markup in whatever source you copy/pasted this from.  Where you see &amp;gt; the author intended &gt; and where you see &amp;lt; the author intended &lt;.  If there's an &amp;amp; that will need to be replaced with a literal &amp; etc.

See a listing of HTML entity codes for a somewhat more exhaustive list.