aboutsummaryrefslogtreecommitdiff
path: root/tcl_scripts
diff options
context:
space:
mode:
Diffstat (limited to 'tcl_scripts')
-rw-r--r--tcl_scripts/errors.tcl44
-rw-r--r--tcl_scripts/gnats.tcl95
-rw-r--r--tcl_scripts/mailprocs.tcl115
-rw-r--r--tcl_scripts/wc.tcl16
4 files changed, 0 insertions, 270 deletions
diff --git a/tcl_scripts/errors.tcl b/tcl_scripts/errors.tcl
deleted file mode 100644
index 94a1e6a8c3c9..000000000000
--- a/tcl_scripts/errors.tcl
+++ /dev/null
@@ -1,44 +0,0 @@
-# @(#)errors.tcl 8.2 (Berkeley) 11/18/95
-#
-# File: errors.tcl
-#
-# Author: George V. Neville-Neil
-#
-# Purpose: This file contains vi/tcl code that allows a vi user to parse
-# compiler errors and warnings from a make.out file.
-
-proc findErr {} {
- global errScreen
- global currFile
- global fileScreen
- set errLine [lindex [viGetCursor $errScreen] 0]
- set currLine [split [viGetLine $errScreen $errLine] :]
- set currFile [lindex $currLine 0]
- set fileScreen [viNewScreen $errScreen $currFile]
- viSetCursor $fileScreen [lindex $currLine 1] 1
- viMapKey $viScreenId  nextErr
-}
-
-proc nextErr {} {
- global errScreen
- global fileScreen
- global currFile
- set errLine [lindex [viGetCursor $errScreen] 0]
- set currLine [split [viGetLine $errScreen $errLine] :]
- if {[string match $currFile [lindex $currLine 0]]} {
- viSetCursor $fileScreen [lindex $currLine 1] 0
- viSwitchScreen $fileScreen
- } else {
- viEndScreen $fileScreen
- set currFile [lindex $currLine 0]
- set fileScreen[viNewScreen $errScreen $currFile]
- viSetCursor $fileScreen [lindex $currLine 1] 0
- }
-}
-
-proc initErr {} {
- global viScreenId
- global errScreen
- set errScreen [viNewScreen $viScreenId make.out]
- viMapKey $viScreenId  findErr
-}
diff --git a/tcl_scripts/gnats.tcl b/tcl_scripts/gnats.tcl
deleted file mode 100644
index 61ecb6e2cda0..000000000000
--- a/tcl_scripts/gnats.tcl
+++ /dev/null
@@ -1,95 +0,0 @@
-# @(#)gnats.tcl 8.2 (Berkeley) 11/18/95
-#
-proc init {catFile} {
- global viScreenId
- global categories
- set categories {}
- set categoriesFile [open $catFile r]
- while {[gets $categoriesFile line] >= 0} {
- lappend categories $line
- }
- close $categoriesFile
- viMsg $viScreenId $categories
- viMapKey $viScreenId  next
-}
-
-proc next {} {
- global viScreenId
- set cursor [viGetCursor $viScreenId]
- set lineNum [lindex $cursor 0]
- set line [viGetLine $viScreenId $lineNum]
- viMsg $viScreenId [lindex $line 0]
- if {[lindex $line 0] == ">Confidential:"} {
- confNext $lineNum $line
- } elseif {[lindex $line 0] == ">Severity:"} {
- sevNext $lineNum $line
- } elseif {[lindex $line 0] == ">Priority:"} {
- priNext $lineNum $line
- } elseif {[lindex $line 0] == ">Class:"} {
- classNext $lineNum $line
- } elseif {[lindex $line 0] == ">Category:"} {
- catNext $lineNum $line
- }
-}
-
-proc confNext {lineNum line} {
- global viScreenId
- viMsg $viScreenId [lindex $line 1]
- if {[lindex $line 1] == "yes"} {
- viSetLine $viScreenId $lineNum ">Confidential: no"
- } else {
- viSetLine $viScreenId $lineNum ">Confidential: yes"
- }
-}
-
-proc sevNext {lineNum line} {
- global viScreenId
- viMsg $viScreenId [lindex $line 1]
- if {[lindex $line 1] == "non-critical"} {
- viSetLine $viScreenId $lineNum ">Severity: serious"
- } elseif {[lindex $line 1] == "serious"} {
- viSetLine $viScreenId $lineNum ">Severity: critical"
- } elseif {[lindex $line 1] == "critical"} {
- viSetLine $viScreenId $lineNum ">Severity: non-critical"
- }
-}
-
-proc priNext {lineNum line} {
- global viScreenId
- viMsg $viScreenId [lindex $line 1]
- if {[lindex $line 1] == "low"} {
- viSetLine $viScreenId $lineNum ">Priority: medium"
- } elseif {[lindex $line 1] == "medium"} {
- viSetLine $viScreenId $lineNum ">Priority: high"
- } elseif {[lindex $line 1] == "high"} {
- viSetLine $viScreenId $lineNum ">Priority: low"
- }
-}
-
-proc classNext {lineNum line} {
- global viScreenId
- viMsg $viScreenId [lindex $line 1]
- if {[lindex $line 1] == "sw-bug"} {
- viSetLine $viScreenId $lineNum ">Class: doc-bug"
- } elseif {[lindex $line 1] == "doc-bug"} {
- viSetLine $viScreenId $lineNum ">Class: change-request"
- } elseif {[lindex $line 1] == "change-request"} {
- viSetLine $viScreenId $lineNum ">Class: support"
- } elseif {[lindex $line 1] == "support"} {
- viSetLine $viScreenId $lineNum ">Class: sw-bug"
- }
-}
-
-proc catNext {lineNum line} {
- global viScreenId
- global categories
- viMsg $viScreenId [lindex $line 1]
- set curr [lsearch -exact $categories [lindex $line 1]]
- if {$curr == -1} {
- set curr 0
- }
- viMsg $viScreenId $curr
- viSetLine $viScreenId $lineNum ">Class: [lindex $categories $curr]"
-}
-
-init abekas
diff --git a/tcl_scripts/mailprocs.tcl b/tcl_scripts/mailprocs.tcl
deleted file mode 100644
index eccb9cdfcf74..000000000000
--- a/tcl_scripts/mailprocs.tcl
+++ /dev/null
@@ -1,115 +0,0 @@
-# @(#)mailprocs.tcl 8.3 (Berkeley) 4/29/96
-#
-proc validLine {} {
- global viScreenId
- set line [viGetLine $viScreenId [lindex [viGetCursor $viScreenId] 0]]
- if {[string compare [lindex [split $line :] 0] "To"] == 0} {
- set addrs [lindex [split $line :] 1]
- foreach name [split $addrs ,] {
- isValid [string trim $name]
- }
- }
-}
-
-proc valid {target} {
- set found 0
- set aliasFile [open "~/Mail/aliases" r]
- while {[gets $aliasFile line] >= 0} {
- set name [lindex [split $line :] 0]
- set address [lindex [split $line :] 1]
- if {[string compare $target $name] == 0} {
- set found 1
- break
- }
- }
- close $aliasFile
- if {$found == 1} {
- return $address
- } else {
- return $found
- }
-}
-
-proc isValid {target} {
- global viScreenId
- set address [valid $target]
- if {$address != 0} {
- viMsg $viScreenId "$target is [string trim $address]"
- } else {
- viMsg $viScreenId "$target not found"
- }
-}
-
-proc isAliasedLine {} {
- global viScreenId
- set line [viGetLine $viScreenId [lindex [viGetCursor $viScreenId] 0]]
- if {[string match [lindex [split $line :] 0] "*To"] == 0} {
- set addrs [lindex [split $line :] 1]
- foreach name [split $addrs ,] {
- isAliased [string trim $name]
- }
- }
-}
-
-proc aliased {target} {
- set found 0
- set aliasFile [open "~/Mail/aliases" r]
- while {[gets $aliasFile line] >= 0} {
- set name [lindex [split $line :] 0]
- set address [lindex [split $line :] 1]
- if {[string compare $target [string trim $address]] == 0} {
- set found 1
- break
- }
- }
- close $aliasFile
-
- return $found
-}
-
-proc isAliased {target} {
- global viScreenId
- set found [aliased $target]
-
- if {$found} {
- viMsg $viScreenId "$target is aliased to [string trim $name]"
- } else {
- viMsg $viScreenId "$target not aliased"
- }
-}
-
-proc appendAlias {target address} {
- if {![aliased $target]} {
- set aliasFile [open "~/Mail/aliases" a]
- puts $aliasFile "$target: $address"
- }
- close $aliasFile
-}
-
-proc expand {} {
- global viScreenId
- set row [lindex [viGetCursor $viScreenId] 0]]
- set column [lindex [viGetCursor $viScreenId] 1]]
- set line [viGetLine $viScreenId $row]
- while {$column < [string length $line] && \
- [string index $line $column] != ' '} {
- append $target [string index $line $column]
- incr $column
- }
- set found [isValid $target]
-}
-
-proc cite {} {
- global viScreenId
- global viStartLine
- global viStopLine
- for {set i $viStartLine} {$i <= $viStopLine} {incr i} {
- set newLine "> "
- append newLine [viGetLine $viScreenId $i]
- viSetLine $viScreenId $i $newLine
- }
-}
-
-global viScreenId
-viMapKey $viScreenId  isAliasedLine
-viMapKey $viScreenId  validLine
diff --git a/tcl_scripts/wc.tcl b/tcl_scripts/wc.tcl
deleted file mode 100644
index 25d0f6254391..000000000000
--- a/tcl_scripts/wc.tcl
+++ /dev/null
@@ -1,16 +0,0 @@
-# @(#)wc.tcl 8.2 (Berkeley) 11/18/95
-#
-proc wc {} {
- global viScreenId
- global viStartLine
- global viStopLine
-
- set lines [viLastLine $viScreenId]
- set output ""
- set words 0
- for {set i $viStartLine} {$i <= $viStopLine} {incr i} {
- set outLine [split [string trim [viGetLine $viScreenId $i]]]
- set words [expr $words + [llength $outLine]]
- }
- viMsg $viScreenId "$words words"
-}