Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Changes In Branch sak-work-review
Excluding Merge-Ins
This is equivalent to a diff from
728f8dc82c
to a87b318066
2013-02-07
| | |
04:40 |
|
check-in: 309ead7ea9 user: aku tags: trunk
|
04:37 |
|
Closed-Leaf
check-in: a87b318066 user: aku tags: sak-work-review
|
02:15 |
|
check-in: a5cab9fbf7 user: andreask tags: sak-work-review
|
2013-02-06
| | |
19:32 |
|
check-in: 7eba32ada7 user: andreask tags: embedded-doc-work
|
05:46 |
|
check-in: 411c419016 user: aku tags: trunk, tcllib-1-15, release
|
2013-02-02
| | |
01:54 |
|
check-in: c6bf264826 user: andreask tags: sak-work-review
|
2013-02-01
| | |
08:14 |
|
check-in: a9514707b9 user: aku tags: tcllib-1-15-rc
|
08:10 |
|
check-in: 728f8dc82c user: aku tags: trunk
|
2013-01-30
| | |
23:28 |
|
check-in: 4eec538864 user: andreask tags: trunk
|
| | |
Changes to modules/doctools/changelog.man.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
-
-
+
+
-
+
|
[comment {-*- tcl -*- doctools manpage}]
[manpage_begin doctools::changelog n 1]
[copyright {2003-2008 Andreas Kupries <[email protected]>}]
[manpage_begin doctools::changelog n 1.1]
[copyright {2003-2013 Andreas Kupries <[email protected]>}]
[moddesc {Documentation tools}]
[titledesc {Processing text in Emacs ChangeLog format}]
[category {Documentation tools}]
[require Tcl 8.2]
[require textutil]
[require doctools::changelog [opt 1]]
[require doctools::changelog [opt 1.1]]
[description]
This package provides Tcl commands for the processing and reformatting
of text in the [file ChangeLog] format generated by [syscmd emacs].
[section API]
|
︙ | | |
47
48
49
50
51
52
53
54
55
56
57
58
59
60
|
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
|
+
+
+
+
+
+
+
|
...
}
}
{...}
}
}]
[call [cmd ::doctools::changelog::flatten] [arg entries]]
This command converts a list of entries as generated by
[cmd change::scan] above into a simpler list of plain
text blocks each containing all the information of a
single entry.
[call [cmd ::doctools::changelog::toDoctools] [arg title] [arg module] [arg version] [arg entries]]
This command converts the pre-parsed ChangeLog [arg entries] as
generated by the command [cmd ::doctools::changelog::scan] into a
document in [term doctools] format and returns it as the result of the
command.
|
︙ | | |
Changes to modules/doctools/changelog.tcl.
︙ | | |
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
|
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
|
package require Tcl 8.2
package require textutil
namespace eval ::doctools {}
namespace eval ::doctools::changelog {
namespace export scan toDoctools
namespace export scan flatten merge toDoctools
}
proc ::doctools::changelog::flatten {entries} {
# Reformat the entries into a simpler structure.
set result {}
foreach entry $entries {
foreach {date user sections} $entry break
set f {}
set t {}
foreach sec $sections {
foreach {files text} $sec break
foreach file $files { lappend f $file }
append t \n $text
}
set t [textutil::adjust::indent [textutil::adjust $t] " "]
lappend result \
"$date $user\n [join $f ", "]:\n$t"
}
return $result
}
# ::doctools::changelog::scan --
#
# Scan a ChangeLog generated by 'emacs' and extract the relevant information.
#
# Result
# List of entries. Each entry is a list of three elements. These
# are date, author, and commentary. The commentary is a list of
# sections. Each section is a list of two elements, a list of
# files, and the associated text.
proc ::doctools::changelog::scan {text} {
set text [split $text \n]
set n [llength $text]
set entries [list]
set clist [list]
|
︙ | | |
253
254
255
256
257
258
259
260
|
274
275
276
277
278
279
280
281
|
-
+
|
lappend linebuffer [q manpage_end]
return [join $linebuffer \n]
}
#------------------------------------
# Module initialization
package provide doctools::changelog 1
package provide doctools::changelog 1.1
|
Changes to modules/doctools/pkgIndex.tcl.
1
2
3
4
5
6
|
1
2
3
4
5
6
|
-
+
|
if {![package vsatisfies [package provide Tcl] 8.2]} {return}
package ifneeded doctools 1.4.13 [list source [file join $dir doctools.tcl]]
package ifneeded doctools::toc 1.1.3 [list source [file join $dir doctoc.tcl]]
package ifneeded doctools::idx 1.0.4 [list source [file join $dir docidx.tcl]]
package ifneeded doctools::cvs 1 [list source [file join $dir cvs.tcl]]
package ifneeded doctools::changelog 1 [list source [file join $dir changelog.tcl]]
package ifneeded doctools::changelog 1.1 [list source [file join $dir changelog.tcl]]
|
Changes to sak.tcl.
︙ | | |
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
|
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
|
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
|
proc __provided {} {
array set packages [ppackages]
nparray packages
return
}
proc __vcompare {} {
global argv
set oldplist [lindex $argv 0]
pkg-compare $oldplist
return
}
proc __rstatus {} {
global distribution approved
catch {
set f [file join $distribution .APPROVE]
set f [open $f r]
while {![eof $f]} {
if {[gets $f line] < 0} continue
set line [string trim $line]
if {$line == {}} continue
set approved($line) .
}
close $f
}
pkg-compare [location_PACKAGES]
return
}
proc pkg-compare {oldplist} {
global approved ; array set approved {}
getpackage struct::set struct/sets.tcl
array set curpkg [ipackages]
array set oldpkg [loadpkglist $oldplist]
array set mod {}
array set changed {}
foreach m [modified-modules] {
set mod($m) .
}
foreach p [array names curpkg] {
set __($p) .
foreach {vlist module} $curpkg($p) break
set curpkg($p) $vlist
set changed($p) [info exists mod($module)]
}
foreach p [array names oldpkg] {set __($p) .}
set unified [lsort [array names __]]
unset __
set maxl 0
foreach name $unified {
if {[string length $name] > $maxl} {
set maxl [string length $name]
}
}
set maxm 0
foreach m [modules] {
if {[string length $m] > $maxm} {
set maxm [string length $m]
}
}
set lastm ""
foreach m [lsort -dict [modules]] {
set packages {}
foreach {p ___} [ppackages $m] {
lappend packages $p
}
foreach name [lsort -dict $packages] {
set skip 0
set suffix ""
set prefix " "
if {![info exists curpkg($name)]} {set curpkg($name) {}}
if {![info exists oldpkg($name)]} {
set oldpkg($name) {}
set suffix " NEW"
set prefix "Nn "
set skip 1
}
if {!$skip} {
# Draw attention to changed packages where version is
# unchanged.
set vequal [struct::set equal $oldpkg($name) $curpkg($name)]
if {$changed($name)} {
if {$vequal} {
# Changed according to ChangeLog, Version is not. ALERT.
set prefix "!! "
set suffix "\t<<< MISMATCH. Version ==, ChangeLog ++"
} else {
# Both changelog and version number indicate a change.
# Small alert, have to classify the order of changes.
set prefix "cv "
set suffix "\t=== Classify changes."
}
} else {
if {$vequal} {
# Versions are unchanged, changelog also indicates no change.
# No particular attention here.
} else {
# Versions changed, but according to changelog nothing in code. ALERT.
set prefix "!! "
set suffix "\t<<< MISMATCH. ChangeLog ==, Version ++"
}
}
if {[info exists approved($name)]} {
set prefix " "
set suffix ""
}
}
# To handle multiple versions we match the found versions up
# by major version. We assume that we have only one version
# per major version. This allows us to detect changes within
# each major version, new major versions, etc.
array set om {} ; foreach v $oldpkg($name) {set om([lindex [split $v .] 0]) $v}
array set cm {} ; foreach v $curpkg($name) {set cm([lindex [split $v .] 0]) $v}
set all [lsort -dict [struct::set union [array names om] [array names cm]]]
sakdebug {
puts @@@@@@@@@@@@@@@@
parray om
parray cm
puts all\ $all
puts @@@@@@@@@@@@@@@@
}
foreach v $all {
if {![string equal $m $lastm]} {
set mdis $m
} else {
set mdis ""
}
set lastm $m
if {[info exists om($v)]} {set ov $om($v)} else {set ov "--"}
if {[info exists cm($v)]} {set cv $cm($v)} else {set cv "--"}
puts stdout ${prefix}[format "%-*s %-*s %-*s %-*s" \
$maxm $mdis $maxl $name 8 $ov 8 $cv]$suffix
}
unset om cm
}
}
return
}
proc checkmod {} {
global argv
package require sak::util
return [sak::util::checkModules argv]
}
# -------------------------------------------------------------------------
|
︙ | | |
2402
2403
2404
2405
2406
2407
2408
2409
2410
2411
2412
2413
2414
2415
2416
2417
2418
2419
2420
2421
2422
2423
2424
2425
2426
2427
2428
2429
2430
2431
|
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
|
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
|
set fh [open $f w] ; puts -nonewline $fh $notice$data ; close $fh
}
gd-gen-packages
return
}
proc __approve {} {
global argv distribution
# Record the package as approved. This will suppress any alerts
# for that package by rstatus. Required for packages which have
# been classified, and for packages where a MISMATCH is bogus (due
# to several packages sharing a ChangeLog)
set f [open [file join $distribution .APPROVE] a]
foreach package $argv {
puts $f $package
}
close $f
return
}
# --------------------------------------------------------------
# Documentation
proc __desc {} {
global argv ; if {![checkmod]} return
array set pd [getpdesc]
|
︙ | | |
Deleted support/devel/sak/note/cmd.tcl.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
|
|
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
|
# -*- tcl -*-
# Implementation of 'note'.
# Available variables
# * argv - Cmdline arguments
# * base - Location of sak.tcl = Top directory of Tcllib distribution
# * cbase - Location of all files relevant to this command.
# * sbase - Location of all files supporting the SAK.
package require sak::util
package require sak::note
set raw 0
set log 0
set stem {}
set tclv {}
if {![llength $argv]} {
sak::note::show
return
}
if {[llength $argv] == 1} {
set f [lindex $argv 0]
if {![file exists $f] ||
![file isfile $f] ||
![file readable $f]
} {
sak::note::usage
}
set c [open $f]
set d [string trimright [read $c]]
close $c
foreach line [split $d \n] {
if {[llength $line] < 3} {
puts stdout "\tBad line: '$line'"
exit 1
}
foreach {m p} $line break
set notes [lrange $line 2 end]
sak::note::run $m $p $notes
}
return
} elseif {[llength $argv] < 3} {
sak::note::usage
}
foreach {m p} $argv break
set notes [lrange $argv 2 end]
sak::note::run $m $p $notes
##
# ###
|
Deleted support/devel/sak/note/help.txt.
1
2
3
4
5
6
7
8
9
10
11
12
|
|
-
-
-
-
-
-
-
-
-
-
-
-
|
note -- enter tags for the README generated by 'sak readme'.
sak note module package tag...
sak note path
This command saves tags for use by 'sak readme'.
The single tag '---' shows that the package is unchanged.
The tags 'D' and 'T', alone or in combination show that
the package is changed, but not in a visible way.
This is a support command for the release manager.
|
Deleted support/devel/sak/note/note.tcl.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
|
|
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
|
# -*- tcl -*-
# (C) 2009 Andreas Kupries <[email protected]>
##
# ###
namespace eval ::sak::note {}
# ###
proc ::sak::note::usage {} {
package require sak::help
puts stdout \n[sak::help::on note]
exit 1
}
proc ::sak::note::run {m p tags} {
global distribution
variable notes
LoadNotes
set k [list $m $p]
set notes($k) $tags
set f [file join $distribution .NOTE]
set f [open $f w]
foreach k [array names notes] {
puts $f [list $k $notes($k)]
}
close $f
return
}
proc ::sak::note::show {} {
variable notes
LoadNotes
getpackage struct::matrix struct/matrix.tcl
struct::matrix M ; M add columns 3
foreach k [lsort -dict [array names notes]] {
M add row [linsert $k end $notes($k)]
}
puts " [join [split [M format 2string] \n] "\n "]\n"
return
}
proc ::sak::note::LoadNotes {} {
global distribution
variable notes
array set notes {}
catch {
set f [file join $distribution .NOTE]
set f [open $f r]
while {![eof $f]} {
if {[gets $f line] < 0} continue
set line [string trim $line]
if {$line == {}} continue
foreach {k t} $line break
set notes($k) $t
}
close $f
}
return
}
##
# ###
package provide sak::note 1.0
|
Deleted support/devel/sak/note/pkgIndex.tcl.
1
2
|
|
-
-
|
if {![package vsatisfies [package provide Tcl] 8.2]} return
package ifneeded sak::note 1.0 [list source [file join $dir note.tcl]]
|
Deleted support/devel/sak/note/topic.txt.
1
|
|
-
|
note Enter tags for the README generated by 'readme'
|
Changes to support/devel/sak/old/help.txt.
︙ | | |
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
+
-
-
-
|
lmodules - See above, however one module per line
imodules - Return list of modules known to the installer.
critcl-modules - Return a list of modules with critcl enhancements.
packages - Return indexed packages in the bundle, plus versions,
one package per line. Extracted from the
package indices found in the modules.
provided - Return list and versions of provided packages
(in contrast to indexed).
vcompare pkglist - Compare package list of previous 'packages'
call with current packages. Marks all new
and unchanged packages for higher attention.
critcl ?module? - Build a critcl module [default is @@].
bench ?opt? ?module..?
- Run benchmark scripts (*.bench).
Options: -throwerrors 0|1 Propagate errors if set.
|
︙ | | |
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
|
96
97
98
99
100
101
102
|
-
-
-
-
-
-
-
-
|
gentip55 - Generate a TIP55-style DESCRIPTION.txt file.
yml - Generate a YAML description file.
release name sf-user-id
- Marks the current state of all files as a new
release. This updates all ChangeLog's, and
regenerates the contents of PACKAGES
rstatus - Determines the status of the code base with regard
to the last release.
approve pkg - Suppress named package in rstatus output.
I.e. mark the packages which are done while going
over all of them for a release.
|
Changes to support/devel/sak/readme/help.txt.
1
2
3
4
5
6
7
8
9
10
11
12
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
+
+
|
readme -- Generate a readme listing changes to modules and packages.
sak readme
This command compares the current state of the modules and
packages and against information from the last release
(support/releases/PACKAGES) and generates a README.txt listing
the relevant changes (new modules/packages, package version
changes, unchanged packages).
The generated README is written to stdout.
This is a support command for the release manager.
|
Changes to support/devel/sak/readme/readme.tcl.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
+
+
-
+
+
+
+
+
|
# -*- tcl -*-
# (C) 2009 Andreas Kupries <[email protected]>
##
# ###
package require sak::color
namespace eval ::sak::readme {}
namespace eval ::sak::readme {
namespace import ::sak::color::*
}
# ###
proc ::sak::readme::usage {} {
package require sak::help
puts stdout \n[sak::help::on readme]
exit 1
}
proc ::sak::readme::run {} {
global package_name package_version
getpackage struct::set struct/sets.tcl
getpackage struct::matrix struct/matrix.tcl
getpackage textutil::adjust textutil/adjust.tcl
set issues {}
# package -> list(version)
set old_version [loadoldv [location_PACKAGES]]
array set releasep [loadpkglist [location_PACKAGES]]
array set currentp [ipackages]
# Determine which packages are potentially changed, from the set
|
︙ | | |
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
|
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
|
+
+
+
+
|
# Both changelog and version number indicate a
# change. Small alert, have to classify the order of
# changes. But not if there is a note, this is assumed
# to be the classification.
if {$note eq {}} {
set note "\t=== Classify changes."
lappend issues [list $m $name "Classify changes"]
}
Enter $m $name $note
lappend chgm $m
lappend chgp $name
continue
}
# Changed according to ChangeLog, Version is not. ALERT.
# or: Versions changed, but according to changelog nothing
# in the code. ALERT.
# Suppress the alert if we have a note, and dispatch per
# the note's contents (some tags are special, instructions
# to us here).
if {($note eq {})} {
if {$changed($name)} {
# Changed according to ChangeLog, Version is not. ALERT.
set note "\t<<< MISMATCH. Version ==, ChangeLog ++"
} else {
set note "\t<<< MISMATCH. ChangeLog ==, Version ++"
}
lappend issues [list $m $name [string range $note 5 end]]
}
Enter $m $name $note
lappend chgm $m
lappend chgp $name
}
}
|
︙ | | |
222
223
224
225
226
227
228
229
230
231
232
233
234
235
|
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
|
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
|
puts ""
puts [Indent " " [textutil::adjust::adjust \
[join [lsort -dict $UCH] {, }] -length 64]]
}
variable legend
puts $legend
if {![llength $issues]} return
puts stderr [=red "Issues found ([llength $issues])"]
puts stderr " Please run \"./sak.tcl review\" to resolve,"
puts stderr " then run \"./sak.tcl readme\" again."
puts stderr Details:
struct::matrix ISS ; ISS add columns 3
foreach issue $issues {
foreach {m p w} $issue break
set m " $m"
ISS add row [list $m $p $w]
}
puts stderr [ISS format 2string]
puts stderr [=red "Issues found ([llength $issues])"]
puts stderr " Please run \"./sak.tcl review\" to resolve,"
puts stderr " then run \"./sak.tcl readme\" again."
return
}
proc ::sak::readme::Header {s {sep =}} {
puts $s
puts [string repeat $sep [string length $s]]
return
|
︙ | | |
396
397
398
399
400
401
402
403
404
405
|
427
428
429
430
431
432
433
434
435
436
437
438
|
+
+
|
Patch B : Bug fixes.
EX : New examples.
P : Performance enhancement.
None T : Testsuite changes.
D : Documentation updates.
}
variable review {}
}
package provide sak::readme 1.0
|
Added support/devel/sak/review/cmd.tcl.
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
|
# -*- tcl -*-
# Implementation of 'review'.
# Available variables
# * argv - Cmdline arguments
# * base - Location of sak.tcl = Top directory of Tcllib distribution
# * cbase - Location of all files relevant to this command.
# * sbase - Location of all files supporting the SAK.
package require sak::util
package require sak::review
set raw 0
set log 0
set stem {}
set tclv {}
if {[llength $argv]} {
sak::review::usage
}
sak::review::run
##
# ###
|
| | | | | | | | | | | | | | | | | | | | | | | |
Added support/devel/sak/review/help.txt.
|
1
2
3
4
5
6
7
8
9
10
|
+
+
+
+
+
+
+
+
+
+
|
review -- Interactively review changed modules and packages
sak review
This command scans the system for changes and then enters
a sub-shell where the caller can interactively review and
tag these changes.
This is a support command for the release manager.
|
| | | | | | | | |
Added support/devel/sak/review/pkgIndex.tcl.
|
1
2
|
+
+
|
if {![package vsatisfies [package provide Tcl] 8.2]} return
package ifneeded sak::review 1.0 [list source [file join $dir review.tcl]]
|
|
Added support/devel/sak/review/review.tcl.