zsh-workers
 help / color / mirror / code / Atom feed
From: Guillaume Chazarain <gfc@altern.org>
To: zsh-workers@sunsite.dk
Subject: du(1) completion and a little $RANDOM problem
Date: Wed, 16 Jul 2003 13:16:31 +0200	[thread overview]
Message-ID: <WMLXW933VXMGWU3V62QML52GE5YB7.3f15340f@monpc> (raw)

Hi list,

Zsh's default completion on the du(1) command is to show only the
directories, but why? since du can also be used on files.

Here is what I mean, against zsh-4.1.1.

--- Completion/Unix/Type/_directories.old
+++ Completion/Unix/Type/_directories
@@ -1,4 +1,4 @@
-#compdef rmdir df du dircmp -P -value-,*path,-default-
+#compdef rmdir df dircmp -P -value-,*path,-default-
 
 local expl
 

Another problem I have deals with $RANDOM. Using echo $RANDOM works as
expected, a new random value is printed each time.

[g ~]$ echo $RANDOM
29407
[g ~]$ echo $RANDOM
31292
[g ~]$ echo $RANDOM
11843
[g ~]$ echo $RANDOM
22883
[g ~]$ echo $RANDOM
20814

But if I do echo `echo $RANDOM` then the random value is always the same.

[g ~]$ echo `echo $RANDOM`
6853
[g ~]$ echo `echo $RANDOM`
6853
[g ~]$ echo `echo $RANDOM`
6853
[g ~]$ echo `echo $RANDOM`
6853
[g ~]$ echo `echo $RANDOM`
6853


And the behaviour is the same if zsh is called as sh.

Thanks
Guillaume







             reply	other threads:[~2003-07-16 11:15 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-07-16 11:16 Guillaume Chazarain [this message]
2003-07-16 11:30 ` Peter Stephenson
2003-07-16 11:46   ` Bart Schaefer
2003-07-16 12:09     ` Sven Wischnowsky
2003-07-17 10:17     ` Oliver Kiddle
2003-08-20 10:35   ` PATCH: " Oliver Kiddle
2003-08-20 14:22     ` Doug Kearns
2003-08-21 12:35       ` Oliver Kiddle

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=WMLXW933VXMGWU3V62QML52GE5YB7.3f15340f@monpc \
    --to=gfc@altern.org \
    --cc=zsh-workers@sunsite.dk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).