WishList revision 131963
1
2                                [Home] WishList
3
4   Home | RecentChanges | Preferences
5     _________________________________________________________________
6
7   Surprised by this behavior...is this a bug?
8
9   (Goal:  e.g.  distinguish  between  completely  numeric args/names and
10   those containing non-numerics)
11
12 % touch 1023 pex103 pex103a 104a z101 16a02 1999 2001 2001_A_Space_Odyssey
13 % ls -1 *[^0-9]*
14 104a
15 16a02
16 2001_A_Space_Odyssey
17 pex103
18 pex103a
19 z101
20 # (great, looks good to me. Got everything containing a nonnumeric, no more, n
21o less.)
22
23 % foreach p ( 1023 pex103 pex103a 104a z101 16a02 1999 2001 2001_A_Space_Odyss
24ey )
25 foreach? if ( $p !~ *[^0-9]* ) echo $p
26 foreach? end
27 # (no output. Huh?)
28
29 % foreach p ( 1023 pex103 pex103a 104a z101 16a02 1999 2001 2001_A_Space_Odyss
30ey )
31 foreach? if ( $p =~ *[^0-9]* ) echo $p
32 foreach? end
33 1023           (!)
34 pex103
35 pex103a
36 104a
37 z101
38 16a02
39 1999           (!)
40 2001           (!)
41 2001_A_Space_Odyssey
42 # (Huh?)
43
44   The [MAN page description] for =~ and !~ just refer to "(see [Filename
45   substitution])',  but  evidently  there is a (unexplained) difference.
46   The  actual  filename  globbing  looks  correct to me, but the pattern
47   matching   operator   behavior  is  unexpected,  if  I'm  not  missing
48   something.
49
50   tcsh 6.09.00
51
52   - bhooglan
53     _________________________________________________________________
54
55   I'm a long-time faithful user of tcsh, and one thing has always bugged
56   me -- the need to type "rehash" at a prompt when adding a new command.
57   My  suggestions  is  to  change  tcsh  so before printing "Command not
58   found.",  it  first  searches  its  entire  path and rebuilds its hash
59   table.  Only  after doing this, and if the command is still not in the
60   path,  then  print  "Command  not  found.".  I  realize there are some
61   extreme  cases  in  which  this  is suboptimal, but in most cases with
62   normal  users  this  would  be  a big win, and simplify the manual and
63   perhaps even the code.
64     _________________________________________________________________
65
66   Wish "tcsh -l" would accept other flags. At least "-c".
67
68   Currently I can't get ssh to have the right environment unless it is a
69   login  shell. The .ssh/environment doesn't work for me because I login
70   to  different  machines  with  different environments. One thing to do
71   would  be  to not have the different environment for login compared to
72   other shells, but what I would really like is something like...
73
74   ssh remote_application_server "tcsh -l -c application"
75
76   The "ssh -t" doesn't work for me and I don't know why.
77
78   Thanks Tim
79
80   Fix limit vmemoryuse in Linux
81
82   In  Linux  tcsh  is  unable  to  limit  vmemoryuse.  This  is  because
83   RLIMIT_VMEM isn't defined, instead Linux has RLIMIT_AS which means the
84   same.  On  Google  groups  I  found  patches  suggested by Komazaki at
85   http://groups.google.com/groups?hl=sv&lr=&ie=UTF-8&oe=ISO-2022-JP&selm
86   =m3snmczvfc.wl%40thinkpad.osk.3web.ne.jp.osk.3web.ne.jp    and   Ogawa
87   Hirofumi suggests a patch at
88   http://groups.google.com/groups?hl=sv&lr=&ie=UTF-8&selm=87snmba4id.fsf
89   %40devron.myhome.or.jp  None  of  these  patches  seems  to  have been
90   included in version 6.12 as 6.12 still has this problem.
91
92   /Henrik??
93
94   New  idea:  use  last  line  (or  n'th line) of output as input to new
95   command.
96
97   I often find myself typing something like:
98
99   >locate lshort
100   /usr/local/stow/share/texmf/doc/latex/general/lshort.dvi    .    .   .
101   /usr/local/store/share/texmf/doc/latex/general/lshort.dvi
102
103   >xdvi /usr/local/store/share/texmf/doc/latex/general/lshort.dvi
104
105   Now the way I accomplish writing the last line, is by moving the mouse
106   over  the  last line, and the copy paste it. It would be very nice, if
107   the  shell could keep the last n lines of output in a buffer. This way
108   one could avoid using the mouse by typing something like:
109
110   >xdvi <M-1>
111
112   which  would  insert  the  last  line of output, similarly <M-2> could
113   insert  the second last line of output. (the exact commands used is of
114   course configured via bindkey).
115
116   This  could  save  me  a  couple  of  times  to  the  mouse everyday -
117   di010070@diku.dk
118
119          The shell does not capture any output from commands it runs, so
120          this  is really more a feature for the terminal (be it hardware
121          or software). --Kim
122
123   Fix  memory  leak  related  to  aliasrun().  Precmd,  Cwdcmd etc. leak
124   memory.
125
126   Fix migrate -site $$... Seems to hang... (aix370)
127
128   Fix history in loops.
129
130   New idea: sed operations on variables.
131
132   Lots  of  people  seem  to  like  the  idea  to be able to do sed type
133   operations  on  shell variables. Maybe we can extend the syntax of the
134   variable  editing  to understand string operations. So I would like to
135   be able to use:
136
137> set a="this is a STRING"
138> echo $a:[3-]
139is is a STRING
140> echo $a:[#]
14116
142> echo $a:[6-7]
143is
144> echo $a:[-2]
145ng
146> echo $a:[-20]
147Subscript out of bounds.
148> echo $a:[2-20]
149Subscript out of bounds.
150> echo $a:[1-1]:u$a:[2-].
151This is a string.
152
153   </blockquote>
154
155   Fix pipelines that contain builtins so that they behave correctly.
156
157   I  tried  to  fix  that (most of the code is in sh.sem.c, but it works
158   only  for  non  POSIX  machines  cause otherwise the setpgid() I added
159   fails).
160
161   Fix the correct code... How to do that involves A.I....
162
163   Rewrite  the  whole  thing.  It  has  taken  to  much beating over the
164   years...
165
166   Add  another  hook  like  precmd  to  be executed after the prompt but
167   before the command.
168
169   Add instructions for using configure in the README file.
170
171   Make manual page references links in the HTML version of the manual.
172
173   It is possible to match the words with ([0-9]) after them. Links could
174   be  using the manual page CGI at http://www.tac.eu.org/cgi-bin/man-cgi
175   for content.
176
177   Add OpenBSD?? to the Makefile, etc.
178
179   A  Csh compatability mode would be nice: I know tcsh is supposed to be
180   fully  csh  compatible,  but csh scripts containing such constructs as
181   '$<'  ,  'if  ( -d $file ) cd $file' or any of a great number of other
182   valid  csh commands, will produce syntax errors or the like with tcsh,
183   which  is  frustrating when writing/maintaining csh scripts which have
184   to  run on systems with only tcsh and systems with only csh. If such a
185   thing  exists, I couldn't find it after searching the man page for two
186   hours, and it should be better documented
187
188   Add  hooks  for  command  completion  Either  for a dynamically loaded
189   library,  or a callback to another program that allows another pass to
190   complete the command. As a trivial example, the module could duplicate
191   the  functionality of aliases. A tcsh_mud.so could define sigh, groan,
192   cheer,  lol,  etc  to  produce  output  if they weren't actually valid
193   commands.
194
195   Properly deal with : in filename substitution
196
197   Given something like
198
199   blah.foo:*.foo
200
201   expand it properly to something like
202
203   blah.foo:baz.foo:bob.foo:bar.foo
204
205   It already does this, if you have a file named like that... --Kim
206
207   Directory  commands  don't  handle  blanks  in filenames. If I have an
208   environment variable such as:
209
210% setenv TOMCAT '/c/Program? Files/Apache? Software Foundation/Tomcat? 5.0'
211and then do the following, setenv complains that it has too many arguments.
212% cd /tmp
213% cd "$TOMCAT"
214setenv: Too many arguments
215% dirs
216/c/Program? Files/Apache? Software Foundation/Tomcat? 5.0 /tmp
217% pushd "$TOMCAT"
218/c/Program? Files/Apache? Software Foundation/Tomcat? 5.0
219setenv: Too many arguments.
220% pushd /tmp
221/tmp /c/Program? Files/Apache? Software Foundation/Tomcat? 5.0
222% pushd
223/c/Program? Files/Apache? Software Foundation/Tomcat? 5.0 /tmp
224setenv: Too many arguments.
225
226   Wish  tcsh  would feature fc (fix command) as in bash !Wish tcsh would
227   featuer fc (fix command) as in bash !
228
229   i  wish  for  read-only  CVS  access  to  the  sources (as i am on the
230   bleeding egde)
231
232   Functions  would be useful! As would being able to redirect stderr (or
233   other file descriptors) independently of stdout! -- Rohan Talip
234
235   Don't  complete  commands  with non-executable files. For example if I
236   have a file called README in a directory in the PATH, and I type R TAB
237   tcsh will complete README as a command. But README does not have the x
238   bit set, so it's kind of pointless to have that completion.
239
240   -->  Setting the shell variable "recognize_only_executables" will give
241   you this behavior. --Waz
242
243   If  I  have  in  my  .tcshrc:  complete  {cd,pushd}  p/1/d/ and I type
244   "complete cd" at the shell prompt nothing is printed. It would be nice
245   if {cd,pushd} p/1/d/ was printed.
246
247   -->  I  had programmed this feature a while ago but have not submitted
248   it  because  the implementation is not robust enough to keep TCSH from
249   crashing  when  special  characters  are part of the pattern. I'll get
250   back to it at some point! --Waz
251
252   It would be nice if "set autolist" would be on by default.
253
254   ---
255
256   Unicode  (UTF-8) doesn't seem to work. It's not even possible to "make
257   catalogs"  in  unicode  environment.  Also  unicode support (and other
258   multibyte   encodings)   should   depend   on   environment  variables
259   (LC_CTYPE),  not  on  "set dspmbyte". On unicode terminal translations
260   show empty characters instead of messages.
261
262   In addition to message catalogs, there are more problems:
263ipi:~/test/tcsh/bin> ls
264tcsh  ���
265ipi:~/test/tcsh/bin> set dspmbyte utf8
266ipi:~/test/tcsh/bin> ls ???
267ls: No match.
268
269   Unicode is used more and more, and is default on many environments, so
270   this really should be fixed. --mpaananen
271     _________________________________________________________________
272
273   When I have a script called from complete I would like to have the the
274   existing  text  from the command line passed to that script so that it
275   can  look  at  all existing words to detemine what it should output as
276   the completion list.
277
278   For example:
279
280   complete prog 'n/-x/`myscript`'
281
282   Then when I do this:
283
284   > prog -a A -b B -x <TAB>
285
286   The script would get 'prog -a A -b B -x ' which would allow the script
287   to  base  its -x completions on the options given for -a and -b (or if
288   they  aren't  present give nothing - or a message saying that they are
289   required).  Setting  a temporary environment variable before executing
290   the command would also work and would probably be safer.
291
292   Perhaps  this info is already available as a special variable that can
293   be  manually  passed  to  the  script:  complete  prog 'n/-x/`myscript
294   $cmd_line`'?
295
296   Update:  I  looked  into this further by actually downloading the code
297   and  looking  through  it.  It  doesn't  seem that this information is
298   available  anywhere,  but  I  did  manage  to achieve what I wanted by
299   adding  the  following  two lines around the call to tw_complete (line
300   278, tw.parse.c 6.12.00):
301
302   added> tsetenv(STRCURRCMDLINE, (Char *)&qline);
303        looking = tw_complete(cmd_start, &wordp, &pat, looking, &suf);
304
305   added> Unsetenv(STRCURRCMDLINE);
306
307   And I added a definition for STRCURRCMDLINE to be "CURRCMDLINE".
308
309   This   provides   the   environment   variable   CURRCMDLINE   to  any
310   script/program running under complete. The only issue I see is picking
311   a  sufficiently obscure environment variable that noone else is likely
312   to  use,  but have it readable enough to understand what it is for. It
313   also  shouldn't overwrite an existing ENV variable if it is already in
314   use.
315     _________________________________________________________________
316
317   Home | RecentChanges | Preferences
318   Edit text of this page | View other revisions
319   Last edited March 25, 2004 10:27 (diff)
320   Search: ____________________
321