Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a problem with a shell script, which looks like:

#!/bin/csh -f
setenv Test

The problem is that it worked until I installed Ubuntu 12.04.
The respond tells me that the command setenv is not found.

My idea is that the bash does not change to the csh but how can I fix it?

share|improve this question

This happens because the line

#!/bin/csh -f

is not the very first line in your script file. If it is the first line, then please post the exact error message that is being printed in terminal when you execute the script.

Please verify also that csh/tcsh is actually installed. You can do this by typing the following into terminal:

dpkg -l | grep csh

If this command produces no output at all, then you can install tcsh by entering following command:

sudo apt-get install tcsh
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.