File
modules/ident/pkgIndex.tcl
— part of check-in
[b8873e8d17]
at
2004-07-12 14:01:04
on branch trunk
— * pkgIndex.tcl: Specify Tcl >= 8.2
* ident.test: Added cleanupTests so it reports the test stats.
* ident.tcl: Changed the package name to 'ident' to correspond
with the namespace name. Added license declaration.
(user:
patthoyts
size: 598)
0000: 23 20 54 63 6c 20 70 61 63 6b 61 67 65 20 69 6e # Tcl package in
0010: 64 65 78 20 66 69 6c 65 2c 20 76 65 72 73 69 6f dex file, versio
0020: 6e 20 31 2e 31 0a 23 20 54 68 69 73 20 66 69 6c n 1.1.# This fil
0030: 65 20 69 73 20 67 65 6e 65 72 61 74 65 64 20 62 e is generated b
0040: 79 20 74 68 65 20 22 70 6b 67 5f 6d 6b 49 6e 64 y the "pkg_mkInd
0050: 65 78 22 20 63 6f 6d 6d 61 6e 64 0a 23 20 61 6e ex" command.# an
0060: 64 20 73 6f 75 72 63 65 64 20 65 69 74 68 65 72 d sourced either
0070: 20 77 68 65 6e 20 61 6e 20 61 70 70 6c 69 63 61 when an applica
0080: 74 69 6f 6e 20 73 74 61 72 74 73 20 75 70 20 6f tion starts up o
0090: 72 0a 23 20 62 79 20 61 20 22 70 61 63 6b 61 67 r.# by a "packag
00a0: 65 20 75 6e 6b 6e 6f 77 6e 22 20 73 63 72 69 70 e unknown" scrip
00b0: 74 2e 20 20 49 74 20 69 6e 76 6f 6b 65 73 20 74 t. It invokes t
00c0: 68 65 0a 23 20 22 70 61 63 6b 61 67 65 20 69 66 he.# "package if
00d0: 6e 65 65 64 65 64 22 20 63 6f 6d 6d 61 6e 64 20 needed" command
00e0: 74 6f 20 73 65 74 20 75 70 20 70 61 63 6b 61 67 to set up packag
00f0: 65 2d 72 65 6c 61 74 65 64 0a 23 20 69 6e 66 6f e-related.# info
0100: 72 6d 61 74 69 6f 6e 20 73 6f 20 74 68 61 74 20 rmation so that
0110: 70 61 63 6b 61 67 65 73 20 77 69 6c 6c 20 62 65 packages will be
0120: 20 6c 6f 61 64 65 64 20 61 75 74 6f 6d 61 74 69 loaded automati
0130: 63 61 6c 6c 79 0a 23 20 69 6e 20 72 65 73 70 6f cally.# in respo
0140: 6e 73 65 20 74 6f 20 22 70 61 63 6b 61 67 65 20 nse to "package
0150: 72 65 71 75 69 72 65 22 20 63 6f 6d 6d 61 6e 64 require" command
0160: 73 2e 20 20 57 68 65 6e 20 74 68 69 73 0a 23 20 s. When this.#
0170: 73 63 72 69 70 74 20 69 73 20 73 6f 75 72 63 65 script is source
0180: 64 2c 20 74 68 65 20 76 61 72 69 61 62 6c 65 20 d, the variable
0190: 24 64 69 72 20 6d 75 73 74 20 63 6f 6e 74 61 69 $dir must contai
01a0: 6e 20 74 68 65 0a 23 20 66 75 6c 6c 20 70 61 74 n the.# full pat
01b0: 68 20 6e 61 6d 65 20 6f 66 20 74 68 69 73 20 66 h name of this f
01c0: 69 6c 65 27 73 20 64 69 72 65 63 74 6f 72 79 2e ile's directory.
01d0: 0a 0a 69 66 20 7b 21 5b 70 61 63 6b 61 67 65 20 ..if {![package
01e0: 76 73 61 74 69 73 66 69 65 73 20 5b 70 61 63 6b vsatisfies [pack
01f0: 61 67 65 20 70 72 6f 76 69 64 65 20 54 63 6c 5d age provide Tcl]
0200: 20 38 2e 32 5d 7d 20 7b 72 65 74 75 72 6e 7d 0a 8.2]} {return}.
0210: 70 61 63 6b 61 67 65 20 69 66 6e 65 65 64 65 64 package ifneeded
0220: 20 69 64 65 6e 74 20 30 2e 34 32 20 5b 6c 69 73 ident 0.42 [lis
0230: 74 20 73 6f 75 72 63 65 20 5b 66 69 6c 65 20 6a t source [file j
0240: 6f 69 6e 20 24 64 69 72 20 69 64 65 6e 74 2e 74 oin $dir ident.t
0250: 63 6c 5d 5d 0a 0a cl]]..