title: Check if a string matches a certain pattern in tcsh
body: <p>I try to match a user-typed string with a specific pattern, to be exact i want to check if the string starts with an upper case letter and then continues with any upper, lower-case letter or number. I want to do this in tcsh, I know bash is better to use, but I have to use tcsh.</p>
  
  <p>So basically i want the following in tcsh:</p>
  
  <pre><code>if [[ $name =~ ^[A-Z][A-Za-z0-9]*$ ]]
  </code></pre>
  
  <p>Here is my code so far:</p>
  
  <pre><code>    #!/bin/tcsh
      set name
      while ( $name == "" )
         echo 'Give an account name!'
         set name = $&lt;
         if ( $name =~ '^[A-Z][A-Za-z0-9*$]' ) then
             echo 'Name accepted!'
         else
             echo 'Not correct format!'
             set name = ""
         endif
      end
  </code></pre>
  
  <p>I'm continously ending up in the "else" part.
  Thank you very much for the help!</p>