"Fossies" - the Fresh Open Source Software Archive
As a special service "Fossies" has tried to format the requested text file into HTML format (style: standard
) with prefixed line numbers.
Alternatively you can here view
the uninterpreted source code file.
2 There should be a tutorial that explains all the nice functionalities of TCSH.
3 And it should be written in DocBook also (to make a nice HowTo).
4 Well, it is not here yet. Your choices are:
6 a. Use this FAQ, if you have a question send it to the mailling list
7 so that when it is answered it will be added to this FAQ
9 b. Check the .tcshrc.* files, read the comments and try them at the same time!
11 c. Read "man tcsh". This is the definite solution and will make you wise.
12 I personally did this several years ago (tcsh 6.05), perhaps you will new
13 functionality to add to the list.
15 d. Check http://www.tcsh.org/. It has online tcsh books (in PostScript and PDF formats)
16 that are available for free. No excuse not to learn tcsh.
20 FAQ FAQ FAQ FAQ FAQ FAQ FAQ FAQ FAQ FAQ FAQ FAQ FAQ FAQ FAQ FAQ FAQ FAQ
22 1. When I try the completion, it does not work!
25 You are doing:
26 cp /etc/passwd /etc/pa<TAB>
28 The behaviour set in the .tcshrc files is to complete only in safe mode.
29 This means that it is not sane to complete on existing files in this case.
31 % cp /etc/passwd<ENTER>
32 cp: error blah blah
33 % <UP ARROW>
34 % cp /etc/passwd <F7>
35 % cp /etc/passwd /etc/passwd
36 % cp /etc/passwd /etc/passwd<.old>
38 2. When I do "cd<TAB>", I only see directories. This is nice!
41 This is part of the "completion" functionality, and it is configured
42 in .tcshrc.complete
44 3. I want slashdot on lynx quickly. How? (NOT AVAILABLE IN THIS VERSION)
48 % ly<TAB>
49 % lynx
50 % lynx <TAB>
51 slashdot.org www.freshmeat.net ...
52 % lynx sl<TAB>
53 % lynx slashdot.org
54 % lynx slashdot.org<ENTER>
56 Should not take you more than one second.
58 4. Auto-correction confuses me.
61 Try this:
62 % cd /usr/locl/bin<ENTER>
64 CORRECT> cd /usr/local/bin (y|n|e)?<SPACE> or <y>
67 For the opposite, suppose you really want to make the directory /usr/locall
69 % mkdir /usr/locall<ENTER>
71 CORRECT> mkdir /usr/local (y|n|e)?<ENTER> or <n>
74 5. Tell me about F7!
77 Without F7, you would do:
79 % cd /tmp
80 % ls demodir
81 not found blah blah
82 % mkdir demodir
83 % cd demodir
85 With F7, you do:
87 % cd /tmp
88 % ls demodir
89 not found blah blah
90 % mkdir <F7>
91 % mkdir demodir
92 % cd <F7>
93 % cd demodir
95 Try several times to get used to it.
96 <F7> prints the last argument of the previous command.
98 6. What do these lines mean?
100 root has logged on pts/0 from :0.
101 root has logged on pts/1 from :0.
102 root has logged on tty1 from local.
104 A: They are part of the "watch" facility.
105 Whenever you run a command in tcsh, tcsh checks if someones has
106 logged on/off the system. If so, it will print it here.
107 It is quite handy to know what is going on your system.
108 It is even handy if you run a non-networked system, to know where you
109 have shells open.
111 7. I was compiling an application and at the end of it I got
112 Time spent in user mode (CPU seconds) : 8.810s
113 Time spent in kernel mode (CPU seconds) : 1.030s
114 Total time : 0:11.66s
115 CPU utilisation (percentage) : 84.3%
116 Times the process was swapped : 0
117 Times of major page faults : 29424
118 Times of minor page faults : 28521
120 A: These are some statistics that TCSH can provide (in a human readable manner)
121 using a special command (time).
122 With the current configuration, it is printed automatically whenever
123 a process takes quite a bit of time to complete. It shows the time
124 the process spent in kernel and user mode, the total time used for the
125 process, the CPU utilisation (user+kernel time / total time) in %.
126 The swapped times is the times the whole process was swapped.
127 If you have plenty of memory, you usually get 0 here.
128 For the page faults, a small operating system tutorial. In modern operating
129 systems, memory is used in chunks called pages. These pages can be swapped
130 to the swap partition to make space for other processes. When our process
131 is running and it cannot find one of its "pages", it issues a "fault", or
132 a "page fault" and makes arrangements to have the page up. The fewer the page
133 faults, the better. The "page fault" terminology is a bit wierd and it comes
134 from long time ago.
135 NOTE: the amount of page faults look to me rather a lot, perhaps they are
136 faults regarding the presense of the page in the memory cache and not the
137 swap. If a kernel hacker knows about this stuff and can have a look in the
138 source code of TCSH, please clarify this issue.
140 8. I find it a bit awkward when I change back and forth directories.
141 Any nice trick?
143 A: You can use the "cd -" command. It takes you to the previous directory.
144 Try it once more to take you to the initial directory.
146 9. How can I access that "cd /usr/local/samba/lib/" command I type ages ago?
148 As long as you remember the beginning of the command that resides in the
149 history, you can access it quickly.
154 cd /usr/local/samba/lib/
156 cd /usr/bin/
158 cd /etc/
161 Now you want to go to samba/lib.
163 % cd <ESC p>
164 % cd /etc/<ESC p>
165 % cd /usr/bin/<ESC p>
166 % cd /usr/local/samba/lib/<ENTER>
168 That is, you press several times ESC p to go to the Previous occurence
169 of a similar command. If at some point you want to go to the next command
170 in the history, hit ESC n
172 10. What does ^G mean?
174 Means you press Ctrl-G.
175 Speaking of ^G, try
177 % echo <^V><^G><ENTER>
179 You will hear a BEEP.
180 ^V is used to "mask" the next character pressed.
182 11. I want F12 to beep to me!
184 You need to bind F12 with the beep. The beep is ^G.
187 % bindkey <^V><F12> <^G><ENTER>
189 That's it.
192 For more information, contact Simos Xenitellis <email@example.com>.