bk glob(7.3ce)              BitKeeper User's Manual             bk glob(7.3ce)

       bk glob - demo program to show glob pattern expansion

       bk glob <pattern> <string> [<string> <string> ...]

       Some  BitKeeper  interfaces  use what are called "glob patterns," some-
       times known as wild cards.  Examples include  the  configuration  file,
       history listing (bk changes), and file name expansion (bk files).

       This command may be used to match a glob against one or more strings to
       see examples of how the pattern matching works.

       A string is a glob pattern if it contains one of  the  characters  "*",
       "?",  "[",  or sometimes "=".  (The last one, "=", is an alias for "*",
       to avoid shell quoting in many cases.  See CONFIGURATION  below.)   The
       glob pattern is used to match one or more strings (or file names), usu-
       ally in a process that takes a glob pattern  and  a  list  of  possible
       matches  and returns the subset of the list which matches the glob pat-
       tern.  Matching works as follows:

       ?      Matches any single character (unless "?" is between brackets).

       *      Matches any string (unless "*" is between brackets).

       [...]  A set of characters enclosed in brackets matches a single  char-
              acter if and only if the character is in the set.

       [^...] As  above  but inverts the set.  In other words "[^abc]" matches
              any character except "a", "b", or "c".

       It is possible to disable all use of globs in file  name  expansion  by
       setting the environment variable BK_NO_FILE_GLOB to any value.

       Since  aliasing  "=" for "*" is not a standard feature and it may cause
       problems when processing files with "=" as part of their name, it  must
       be  explicitly   enabled  by setting BK_GLOB_EQUAL to the value of YES.
       No other value will enable this feature.

       Test a simple pattern match that matches file.c and file.h:

           bk glob '*.[ch]' file.c file.h file.1

       List all files ending in ".1":

           export BK_GLOB_EQUAL=YES
           bk -A files =.1

       See changes in all header files in the current directory:

           bk diff '*.h'

       See the revision history for all C/header files with the phrase  "sccs"
       in their name:

           bk sccslog '*sccs*.[ch]'

       See all changesets which include the phrase "BUGID:" followed by a num-

           bk changes '-/BUGID:[123456789]/'

       Sets of characters, i.e., [A-Z], have only marginal support.   Escaping
       the minus in the set is not supported.

       bk config-etc
       bk changes
       bk files


BitKeeper Inc                        201E1                      bk glob(7.3ce)