zsh-workers
 help / color / mirror / code / Atom feed
From: Wayne Davison <wayned@users.sourceforge.net>
To: Peter Stephenson <pws@pwstephenson.fsnet.co.uk>
Cc: Zsh hackers list <zsh-workers@sunsite.dk>
Subject: Re: PATCH: Re: Globbing for Empty Directories?
Date: Tue, 6 Apr 2004 10:55:07 -0700	[thread overview]
Message-ID: <20040406175507.GC10632@blorf.net> (raw)
In-Reply-To: <20040401184336.DC34B8646@pwstephenson.fsnet.co.uk>

[-- Attachment #1: Type: text/plain, Size: 143 bytes --]

I thought it would be nice to test the new 'F'ull-directory glob
modifier, so I'm planning to commit these changes to D02glob.ztst.

..wayne..

[-- Attachment #2: globtest.patch --]
[-- Type: text/plain, Size: 1656 bytes --]

--- Test/D02glob.ztst	3 Dec 2003 10:54:36 -0000	1.3
+++ Test/D02glob.ztst	6 Apr 2004 17:33:46 -0000
@@ -2,8 +2,8 @@
 
 %prep
   mkdir glob.tmp
-  mkdir glob.tmp/dir1
-  mkdir glob.tmp/dir2
+  mkdir glob.tmp/dir{1,2,3,4}
+  mkdir glob.tmp/dir3/subdir
   : >glob.tmp/{,{dir1,dir2}/}{a,b,c}
 
   globtest () { $ZTST_testdir/../Src/zsh -f $ZTST_srcdir/../Misc/$1 }
@@ -265,11 +265,11 @@
   ( regress_absolute_path_and_core_dump )
 0:exclusions regression test
 >
->glob.tmp/a glob.tmp/b glob.tmp/c glob.tmp/dir1 glob.tmp/dir1/a glob.tmp/dir1/b glob.tmp/dir1/c glob.tmp/dir2 glob.tmp/dir2/a glob.tmp/dir2/b glob.tmp/dir2/c
+>glob.tmp/a glob.tmp/b glob.tmp/c glob.tmp/dir1 glob.tmp/dir1/a glob.tmp/dir1/b glob.tmp/dir1/c glob.tmp/dir2 glob.tmp/dir2/a glob.tmp/dir2/b glob.tmp/dir2/c glob.tmp/dir3 glob.tmp/dir3/subdir glob.tmp/dir4
 
  print glob.tmp/*(/)
 0:Just directories
->glob.tmp/dir1 glob.tmp/dir2
+>glob.tmp/dir1 glob.tmp/dir2 glob.tmp/dir3 glob.tmp/dir4
 
  print glob.tmp/*(.)
 0:Just files
@@ -281,7 +281,7 @@
 
  print glob.tmp/**/(:h) 
 0:Head modifier
->. glob.tmp glob.tmp
+>. glob.tmp glob.tmp glob.tmp glob.tmp glob.tmp/dir3
 
  print glob.tmp(:r)
 0:Remove extension modifier
@@ -289,5 +289,16 @@
 
  print glob.tmp/*(:s/./_/)
 0:Substitute modifier
->glob_tmp/a glob_tmp/b glob_tmp/c glob_tmp/dir1 glob_tmp/dir2
+>glob_tmp/a glob_tmp/b glob_tmp/c glob_tmp/dir1 glob_tmp/dir2 glob_tmp/dir3 glob_tmp/dir4
 
+ print glob.tmp/*(F)
+0:Just full dirs
+>glob.tmp/dir1 glob.tmp/dir2 glob.tmp/dir3
+
+ print glob.tmp/*(^F)
+0:Omit full dirs
+>glob.tmp/a glob.tmp/b glob.tmp/c glob.tmp/dir4
+
+ print glob.tmp/*(/^F)
+0:Just empty dirs
+>glob.tmp/dir4

      parent reply	other threads:[~2004-04-06 17:55 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <9E7AF602-8085-11D8-AA68-000502631FBD@louisville.edu>
2004-04-01 18:43 ` Peter Stephenson
2004-04-01 19:26   ` DervishD
2004-04-01 22:49   ` Geoff Wing
2004-04-02  2:02     ` Geoff Wing
2004-04-06 17:27   ` Wayne Davison
2004-04-06 17:41     ` Peter Stephenson
2004-04-06 17:55   ` Wayne Davison [this message]

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=20040406175507.GC10632@blorf.net \
    --to=wayned@users.sourceforge.net \
    --cc=pws@pwstephenson.fsnet.co.uk \
    --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).