Operating System - HP-UX
1823175 Members
3688 Online
109647 Solutions
New Discussion юеВ

Simple script question...

 
SOLVED
Go to solution
Gene Laoyan
Super Advisor

Simple script question...

I am enumerating the hostname of my host like this...

HOSTNAME=$(hostname)

The contents of the variable will be "ITANIUM4".
How can I force the variable to be in all lower case "itanium4"?
2 REPLIES 2
James R. Ferguson
Acclaimed Contributor
Solution

Re: Simple script question...

Hi Gene:

# typeset -l HOSTNAME=$(hostname)

See the manpages for 'sh-posix(1)' for more information on the 'typeset' declaration.

Regards!

...JRF...
Gene Laoyan
Super Advisor

Re: Simple script question...

Big Thanks!
It worked fine.