Character Sets | Unix Linux Forums | Shell Programming and Scripting

  Go Back    


Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here.

Character Sets

Shell Programming and Scripting


Closed Thread    
 
Thread Tools Search this Thread Display Modes
    #1  
Old 10-07-2006
PradeepRed PradeepRed is offline
Registered User
 
Join Date: Dec 2005
Last Activity: 17 March 2008, 3:55 AM EDT
Posts: 25
Thanks: 0
Thanked 0 Times in 0 Posts
Character Sets

Hi

I was just wondering if there was a way in which i could find out the character set used in a file in HP-UX. ie Whether it is Unicode, UTF-8,ascii etc.

Regards
Sponsored Links
    #2  
Old 10-10-2006
Andrek Andrek is offline
Registered User
 
Join Date: Aug 2006
Last Activity: 27 April 2010, 9:08 PM EDT
Posts: 122
Thanks: 0
Thanked 0 Times in 0 Posts
Don't know how helpfull this is but the "locale" command will list out your current local env and show what character set is in place.
There is a perl function called perllocale which may help?
Sponsored Links
    #3  
Old 10-10-2006
Ygor's Avatar
Ygor Ygor is offline Forum Advisor  
Advisor
 
Join Date: Oct 2003
Last Activity: 2 May 2014, 7:14 AM EDT
Location: 54.23, -4.53
Posts: 1,801
Thanks: 1
Thanked 111 Times in 98 Posts
Perhaps just use file, e.g...
Code:
$ file file1.txt file2.txt
file1.txt:    ASCII English text
file2.txt:    UTF-8 Unicode text

    #4  
Old 10-10-2006
PradeepRed PradeepRed is offline
Registered User
 
Join Date: Dec 2005
Last Activity: 17 March 2008, 3:55 AM EDT
Posts: 25
Thanks: 0
Thanked 0 Times in 0 Posts
Yup

file command works fine.

Thanks
Sponsored Links
Closed Thread

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
FSS and processor sets fugitive Solaris 2 06-11-2009 10:45 AM
How to translate character and font sets ? jack2 Shell Programming and Scripting 2 03-27-2009 11:03 AM
differentiating two sets skyineyes Shell Programming and Scripting 15 12-16-2008 01:13 AM
Clouds (Partially Order Sets) - Streams (Linearly Ordered Sets) - Part 2 Linux Bot Virtualization and Cloud Computing 0 07-28-2007 06:40 AM



All times are GMT -4. The time now is 02:57 PM.