Re: Letters?

From: utbtwcou.gwhuofpvyq@zsttk.ru
Date: Sun Jul 02 2000 - 08:02:10 EEST

  • Next message: ron jochems: "Re: SCC Card + Baycom 1k2 Modem ???"

    Message-Id: 81_kb2shu
    From: kb2shu@kb2shu.#sca.ca.usa.noam
    To: twyf@colostate.edu

    Someone on this list gave me this a while back, and will do what
    you need:

    #Here's a Unix shell script I have used for several years -- it will do the
    #conversion in either direction depending upon the -u|-l flag.
    # mvcase
    # asw 17.10.94

    # based on idea
    #From: terhi.victor@logonet.com (Max Heffler)
    #Subject: Re: How to rename files with wildcard
    #Organization: Texas Systems
    #Date: Wed, 5 Oct 1994 01:00:16 GMT
    #Max Heffler, Senior Software Design Engineer home: zoi@kerailya.tunkki.fi
    #
    #! /bin/sh
    #ls | while read i
    #do
    # mv $i `echo $i | tr '[a-z]' '[A-Z]'`
    #done

    if [ $2xx = xx ]
    then
      echo "Usage mvcase -l|u filespec"
    else
      case $1 in
        -l)
           for f in $*
           do
             if [ -s $f ]
             then mv $f `echo $f | tr '[A-Z]' '[a-z]'`
             fi
           done ;;
        -u)
           for f in $*
           do
             if [ -s $f ]
             then mv $f `echo $f | tr '[a-z]' '[A-Z]'`
             fi
           done ;;
        *)
          echo "Usage mvcase -l|u filespec"
      esac
    fi

    **********************

    73 for now de Paul.
    kb2shu@kb2shu.#sca.ca.usa.noam
    fmakgwhm@mailit.tunk.net
    qpzb.tktoor@tullett.co.uk
    www.moonlink.net/~paul



    This archive was generated by hypermail 2b29 : Sun Jul 02 2000 - 08:06:57 EEST