1

I tried to install homebrew (OSX 10.9.5) using the recommended

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

but got

Illegal variable name.

I do have macports installed, so perhaps some commands do not what they are meant to?? But note that ruby is /usr/bin/ruby and curl is /usr/bin/curl.

How can I overcome this problem?

4

The problem lies with usage of tcsh as underlying shell. tcsh does not support $() as a syntax for command substituion. When using bash instead, it works just fine.

-2

in terminal preferences, change /bin/tcsh to /bin/bash

We're looking for long answers that provide some explanation and context. Don't just give a one-line answer; explain why your answer is right, ideally with citations. Answers that don't include explanations may be removed.

  • Presumably the OP is using tcsh because they want to use it in preference to bash! They don't need to (semi)permanently change their shell - just drop into bash to install brew, then exit bash and return to tcsh. And that'll work even if they're using iTerm2, or another terminal emulator, not just Terminal.app. – John N Dec 9 '16 at 10:03
-2

in terminal just type 'bash' and then enter now run the same command. I works fine.

We're looking for long answers that provide some explanation and context. Don't just give a one-line answer; explain why your answer is right, ideally with citations. Answers that don't include explanations may be removed.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .