rename



rename

NAME
SYNOPSIS
DESCRIPTION
EXAMPLE
SEE ALSO
KEYWORDS

___________________________

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.conf(5), proc(5)

KEYWORDS

command, delete, namespace, rename




More Linux Commands

manpages/gpart.8.html
gpart(8) - guess PC-type hard disk partitions (Man Page)....
gpart tries to guess which partitions are on a hard disk. If the primary partition table has been lost, overwritten or destroyed the partitions still exist on t

manpages/acct.5.html
acct(5) - process accounting file - Linux manual page.......
If the kernel is built with the process accounting option enabled (CONFIG_BSD_PROCESS_ACCT), then calling acct(2) starts process accounting, for example: acct(/

manpages/wborder_set.3ncurses.html
wborder_set(3ncurses) - create curses borders or lines using
The border_set and wborder_set functions draw a border around the edges of the current or specified window. These functions do not change the cursor position, a

manpages/gnutls_session_channel_binding.3.html
gnutls_session_channel_binding(3) - API function (Man Page)
Extract given channel binding data of the cbtype (e.g., GNUTLS_CB_TLS_UNIQUE) type. RETURNS GNUTLS_E_SUCCESS on success, GNUTLS_E_UNIMPLEMENTED_FEATURE if the c

manpages/numa_maps.5.html
numa_maps(5) - overview of Non-Uniform Memory Architecture
Non-Uniform Memory Access (NUMA) refers to multiprocessor systems whose memory is divided into multiple memory nodes. The access time of a memory node depends o

manpages/Tcl_CreateTimerHandler.3.html
Tcl_CreateTimerHandler(3) - call a procedure at a given time
Tcl_CreateTimerHandler arranges for proc to be invoked at a time milliseconds milliseconds in the future. The callback to proc will be made by Tcl_DoOneEvent, s

manpages/vm86.2.html
vm86(2) - enter virtual 8086 mode - Linux manual page.......
The system call vm86() was introduced in Linux 0.97p2. In Linux 2.1.15 and 2.0.28, it was renamed to vm86old(), and a new vm86() was introduced. The definition

manpages/Tcl_CreateFileHandler.3.html
Tcl_CreateFileHandler(3) - associate procedure callbacks wit
Tcl_CreateFileHandler arranges for proc to be invoked in the future whenever I/O becomes possible on a file or an exceptional condition exists for the file. The

manpages/pcre32_assign_jit_stack.3.html
pcre32_assign_jit_stack(3) Perl-compatible regular expressio
This function provides control over the memory used as a stack at run-time by a call to pcre[16|32]_exec() with a pattern that has been successfully compiled wi

manpages/gnutls_openpgp_crt_get_subkey_revoked_status.3.html
gnutls_openpgp_crt_get_subkey_revoked_status.3..............
Get subkey revocation status. A negative error code indicates an error. RETURNS true (1) if the key has been revoked, or false (0) if it has not. SINCE 2.4.0 RE

manpages/Tcl_FSNewNativePath.3.html
Tcl_FSNewNativePath(3) - procedures to interact with any fil
There are several reasons for calling the Tcl_FS API functions (e.g. Tcl_FSAccess and Tcl_FSStat) rather than calling system level functions like access and sta

manpages/glAccum.3gl.html
glAccum(3gl) - operate on the accumulation buffer (ManPage)
The accumulation buffer is an extended-range color buffer. Images are not rendered into it. Rather, images rendered into one of the color buffers are added to t





We can't live, work or learn in freedom unless the software we use is free.