Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 49347
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 10, 20262026-05-10T16:25:21+00:00 2026-05-10T16:25:21+00:00

in tcsh I’m trying to redirect STDERR from a command from my .aliases file.

  • 0

in tcsh I’m trying to redirect STDERR from a command from my .aliases file.

I found that I can redirect STDERR from the command line like this. . .

$ (xemacs > /dev/tty) >& /dev/null 

. . . but when I put this in my .aliases file I get an alias loop. . .

$ cat .aliases alias xemacs '(xemacs > /dev/tty ) >& /dev/null' $ xemacs & Alias loop. $ 

. . . so I put a backslash before the command in .aliases, which allows the command to run. . .

$ cat .aliases alias xemacs '(\xemacs > /dev/tty ) >& /dev/null' $ xemacs & [1] 17295 $  

. . . but now I can’t give the command any arguments:

$ xemacs foo.txt & Badly placed ()'s. [1]    Done                          ( \xemacs > /dev/tty ) >& /dev/null $  

Can anyone offer any solutions? Thank you in advance!


UPDATE: I’m still curious if it’s possible to redirect STDERR in tcsh from .aliases, but as has been suggested here, I ended up with a shell script:

#!/bin/sh # wrapper script to suppress messages sent to STDERR on launch # from the command line. /usr/bin/xemacs '$@' 2>/dev/null 
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-10T16:25:21+00:00Added an answer on May 10, 2026 at 4:25 pm

    I suspect this is a case where NOT using an alias is the best option – try using a shell script instead:

    #!/bin/tcsh  (xemacs $* > /dev/tty ) >& /dev/null 
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm using tcsh, and I'm trying to grep a path from a file with
Given this variable in tcsh: set i = ~/foo/bar.c how can I get just
I've got this line my .cshrc.user (using tcsh) set prompt = %{\033[36m%}%m%{\033[32m]%}{`echo $CLEARCASE_ROOT |
I have a tcsh script that generates a text file. One of the lines
Is there a one line command in tcsh to change the extension of a
I'm writing a shell script that uses ANSI color characters on the command line.
I'm trying to make an alias in .alias file for tcsh. Alias is something
I am looking at a tcsh script that has the following shebang line: #!/bin/tcsh
I'm trying to translate a tcsh script to a bash one. This script invokes
I am using /bin/tcsh as my default shell. However, the tcsh style command os.system('setenv

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.