1 # $Id: .zshrc,v 1.17 2003/07/03 18:51:22 dope Exp dope $
6 # Purpose : setup file for the shell 'zsh'
7 # Author : Christian Schneider <strcat@gmx.net>
8 # Homepage : http://www.strcat.de/zsh/
9 # Latest release : <http://strcat.neessen.net/dotfiles/#zsh>
10 # Needed files : <http://strcat.neessen.net/dotfiles/zsh/dot-zsh.tar.gz>>
12 # Structure of this file:
13 # Lines starting with '#' are comments.
15 # Take a quick (haha) look on zshbuiltins(1), zshcompwid(1),
16 # zshcompsys(1), zshcompctl(1), zshexpn(1), zshmisc(1), zshmodules(1),
17 # zshoptions(1), zshparam(1), zshzle(1) or - for hardliner -
19 # ,----[ Overview (Zsh 4.2.1) ]
20 # | [dope@dreckskind:~]% man -k zsh
21 # | zsh (1) - the Z shell (330 lines)
22 # | zshall (1) - the Z shell meta-man page (18348 lines)
23 # | zshcompwid (1) - zsh completion widgets (1320 lines)
24 # | zshcompsys (1) - zsh completion system (3432 lines)
25 # | zshzftpsys (1) - zftp function front-end (858 lines)
26 # | zshbuiltins (1) - zsh built-in commands (1716 lines)
27 # | zshoptions (1) - zsh options (1254 lines)
28 # | zshzle (1) - zsh command line editor (1320 lines)
29 # | zshparam (1) - zsh parameters (1056 lines)
30 # | zshmodules (1) - zsh loadable modules (2442 lines)
31 # | zshmisc (1) - everything and then some (1782 lines)
32 # | zshcompctl (1) - zsh programmable completion (858 lines)
33 # | zshexpn (1) - zsh expansion and substitution (1914 lines)
36 # Zsh start up sequence:
37 # 1) /etc/zshenv -> Always run for every zsh. (login + interactive + other)
38 # 2) ~/.zshenv -> Usually run for every zsh. (login + interactive + other)
39 # 3) /etc/zprofile -> Run for login shells. (login)
40 # 4) ~/.zprofile -> Run for login shells. (login)
41 # 5) /etc/zshrc -> Run for interactive shells. (login + interactive)
42 # 6) ~/.zshrc -> Run for interactive shells. (login + interactive)
43 # 7) /etc/zlogin -> Run for login shells. (login)
44 # 8) ~/.zlogin -> Run for login shells. (login)
46 # Last modified: [ 2004-09-15 02:43:09 ]
49 # THIS FILE IS NOT INTENDED TO BE USED AS /etc/zshrc, NOR WITHOUT
52 # This file is based on ideas of:
53 # Sven Guckes...: <http://www.guckes.net/setup/zshrc>
54 # Michael Prokop: <http://www.michael-prokop.at/computer/config/.zshrc>
55 # Marijan Peh...: <http://free-po.hinet.hr/MarijanPeh/files/zshrc>
56 # Adam Spiers...: <http://adamspiers.org/computing/shells/>
58 # Tested and used unter {Net,Open}BSD, Slackware, Gentoo and LFS
59 # with Zsh 4.0.7, 4.0.9, 4.1.1, 4.2.0 and 4.2.1
61 # Login shell? If you want to know, you can type the following which will
62 # do nothing it's a login shell or warn you if not.
63 #--------------------------------------------------
64 # if [[ ! -o login ]]; then
65 # print "Warning: It is *not* a login-Shell\!"
67 #--------------------------------------------------
69 # -f true if file exists and is a regular file. See
70 # | man zshmisc | less -p "^CONDITIONAL EXPRESSIONS"
73 # Test and then source exported variables.
74 if [ -f ~/.zsh/zshexports ]; then
75 source ~/.zsh/zshexports
77 print "Note: ~/.zsh/zshexports is unavailable."
80 # painless is my "what-happend-when" - box (for debugging and so on)
81 if [ ${HOSTNAME} = painless ] && [ -e ~/.zsh/zshdevel ]; then
82 source ~/.zsh/zshdevel
85 # Test and then source some options
86 if [ -f ~/.zsh/zshoptions ]; then
87 source ~/.zsh/zshoptions
89 print "Note: ~/.zsh/zshoptions is unavailable."
92 # Test and then source alias definitions.
93 if [ -f ~/.zsh/zshaliases ]; then
94 source ~/.zsh/zshaliases
96 print "Note: ~/.zsh/zshaliases is unavailable."
99 # Test and then source the functions.
100 if [ -f ~/.zsh/zshfunctions ]; then
101 source ~/.zsh/zshfunctions
103 print "Note: ~/.zsh/zshfunctions is unavailable."
106 # Test and then source the lineeditor
107 if [ -f ~/.zsh/zshzle ]; then
110 print "Note: ~/.zsh/zshzle is unavailable."
113 # Test and then source the "Statusbar-Functions"
114 #--------------------------------------------------
115 # if [ -f ~/.zsh/zshstatusbar ];then
116 # source ~/.zsh/zshstatusbar
118 # print "Note: ~/.zsh/zshstatusbar is unavailable."
120 #--------------------------------------------------
122 # Test and then source the keybindings
123 if [ -f ~/.zsh/zshbindings ]; then
124 source ~/.zsh/zshbindings
126 print "Note: ~/.zsh/zshbindings is not available."
129 # Test and then source the completionsystem
130 if [ -f ~/.zsh/zshcompctl ]; then
131 source ~/.zsh/zshcompctl
133 print "Note: ~/.zsh/zshcompctl is unavailable."
136 # Test and then source the zstyles
137 if [ -f ~/.zsh/zshstyle ]; then
138 source ~/.zsh/zshstyle
140 print "Note: ~/.zsh/zshstyle is unavailable."
143 # Test and then source the wretched rest
144 if [ -f ~/.zsh/zshmisc ]; then
145 source ~/.zsh/zshmisc
147 print "Note: ~/.zsh/zshmisc is unavailable."