home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.cs.arizona.edu
/
ftp.cs.arizona.edu.tar
/
ftp.cs.arizona.edu
/
icon
/
historic
/
v941.tgz
/
icon.v941src.tar
/
icon.v941src
/
ipl
/
progs
/
upper.icn
< prev
next >
Wrap
Text File
|
2000-07-29
|
883b
|
37 lines
############################################################################
#
# File: upper.icn
#
# Subject: Program to map file names to uppercase
#
# Author: Ralph E. Griswold
#
# Date: March 10, 1995
#
############################################################################
#
# This file is in the public domain.
#
############################################################################
#
# This program maps the names of all files in the current directory to
# uppercase.
#
############################################################################
#
# Requires: UNIX
#
############################################################################
procedure main()
local input, old, new
input := open("ls", "p")
while old := read(input) do {
new := map(old, &lcase, &ucase)
if new ~== old then rename(old, new)
}
end