swig/Tools/capitalize
Jonah Beckford a2cfa36c80 Solaris /usr/bin/tr does not accept ranges in form "a-z". So put in
explicit abc...xyz range.  Fixes "make check-gifplot" and whatever
else might use 'Tools/capitalize'.


git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@4615 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2003-03-22 11:18:27 +00:00

5 lines
231 B
Bash
Executable file

#!/bin/sh
# usage: capitalize word
# write word to stdout w/ first character upcased
first_char=`echo $1 | sed 's/^\(.\).*/\1/' | tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ`
echo ${first_char}`echo $1 | sed 's/^.//'`