Unix and Linux Discussions Tagged with rename |
|
Thread / Thread Starter |
Last Post |
Replies |
Views |
Forum |
|
|
|
3 |
4,261 |
UNIX for Beginners Questions & Answers |
|
|
|
1 |
3,353 |
UNIX for Beginners Questions & Answers |
|
|
|
7 |
106,553 |
Shell Programming and Scripting |
|
|
|
7 |
9,594 |
UNIX for Beginners Questions & Answers |
|
|
|
6 |
16,797 |
Shell Programming and Scripting |
|
|
|
11 |
6,617 |
UNIX for Beginners Questions & Answers |
|
|
|
5 |
3,955 |
UNIX for Beginners Questions & Answers |
|
|
|
1 |
5,473 |
Shell Programming and Scripting |
|
|
|
1 |
18,698 |
Shell Programming and Scripting |
|
|
|
3 |
9,282 |
Shell Programming and Scripting |
|
|
|
14 |
10,181 |
Shell Programming and Scripting |
|
|
|
1 |
2,566 |
Shell Programming and Scripting |
|
|
|
10 |
5,044 |
UNIX for Beginners Questions & Answers |
|
|
|
1 |
2,091 |
Shell Programming and Scripting |
|
|
|
3 |
1,949 |
Shell Programming and Scripting |
|
|
|
3 |
2,750 |
UNIX for Beginners Questions & Answers |
|
|
|
3 |
4,020 |
Shell Programming and Scripting |
|
|
|
4 |
2,357 |
Programming |
|
|
|
4 |
2,149 |
Shell Programming and Scripting |
|
|
|
6 |
2,298 |
Shell Programming and Scripting |
|
|
|
4 |
6,978 |
Shell Programming and Scripting |
|
|
|
12 |
6,831 |
UNIX for Dummies Questions & Answers |
|
|
|
4 |
5,485 |
Shell Programming and Scripting |
|
|
|
5 |
3,881 |
Shell Programming and Scripting |
|
|
|
17 |
5,014 |
Shell Programming and Scripting |
|
|
|
7 |
2,777 |
Shell Programming and Scripting |
|
|
|
8 |
9,227 |
Shell Programming and Scripting |
|
|
|
1 |
7,403 |
Shell Programming and Scripting |
|
|
|
15 |
26,749 |
Shell Programming and Scripting |
|
|
|
4 |
8,110 |
UNIX for Dummies Questions & Answers |
|
|
|
1 |
2,224 |
UNIX for Dummies Questions & Answers |
|
|
|
5 |
7,228 |
UNIX for Dummies Questions & Answers |
|
|
|
2 |
27,561 |
UNIX for Dummies Questions & Answers |
|
|
|
7 |
11,648 |
UNIX for Dummies Questions & Answers |
|
|
|
8 |
5,926 |
Shell Programming and Scripting |
|
|
|
2 |
4,948 |
Shell Programming and Scripting |
|
|
|
4 |
5,792 |
UNIX for Dummies Questions & Answers |
|
|
|
3 |
13,166 |
Shell Programming and Scripting |
|
|
|
0 |
2,818 |
UNIX for Dummies Questions & Answers |
|
|
|
4 |
5,105 |
UNIX for Dummies Questions & Answers |
rename(3tcl) Tcl Built-In Commands rename(3tcl)
__________________________________________________________________________________________________________________________________________________
NAME
rename - Rename or delete a command
SYNOPSIS
rename oldName newName
_________________________________________________________________
DESCRIPTION
Rename the command that used to be called oldName so that it is now called newName. If newName is an empty string then oldName is deleted.
oldName and newName may include namespace qualifiers (names of containing namespaces). If a command is renamed into a different namespace,
future invocations of it will execute in the new namespace. The rename command returns an empty string as result.
EXAMPLE
The rename command can be used to wrap the standard Tcl commands with your own monitoring machinery. For example, you might wish to count
how often the source command is called:
rename ::source ::theRealSource
set sourceCount 0
proc ::source args {
global sourceCount
puts "called source for the [incr sourceCount]'th time"
uplevel 1 ::theRealSource $args
}
SEE ALSO
namespace(3tcl), proc(3tcl)
KEYWORDS
command, delete, namespace, rename
Tcl rename(3tcl)