16.5 Startup File Pitfalls

16.5 Startup File Pitfalls

There are a few things you really should avoid in startup files (many have to do with the X Window System):

  • Don't put X commands in a shell startup file.

  • Don't set the DISPLAY environment variable in a shell startup file.

  • Don't set the terminal type in a shell startup file.

  • Don't skimp on descriptive comments in default startup files.

  • Don't run commands in a startup file that print to the standard output.

  • Never set LD_LIBRARY_PATH in a shell startup file (see Section 8.1.4).