How to examine and open a text file?


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers How to examine and open a text file?
# 1  
Old 12-05-2010
How to examine and open a text file?

Hi
I am a new to linux, i was faced a file to know is a text file but its type isnt text document and i can not open it please guide me.
Regards

---------- Post updated at 02:52 AM ---------- Previous update was at 02:40 AM ----------

Thank you for your cooperation, my OS is a centOS 5.5 and works with bshell
# 2  
Old 12-05-2010
to get some clue about what do contains a a file, just use the commande file :
example below to get some clue about my file whose name start by m* o* q* or ti* :

Code:
$ file {[moq]*,ti*}
men:       Bourne-Again shell script text executable
myd:       a /usr/bin/ksh script text executable
myscript:  a /usr/bin/ksh script text executable
output:    ASCII text
questions: UTF-8 Unicode English text
tick:      Korn shell script text executable
titi:      ASCII text

---------- Post updated at 10:17 AM ---------- Previous update was at 10:14 AM ----------

I don't know Cent OS, but if it is a Unix-like" operating system :
to get some clue about which user/group it belongs to, and read/write/execute permission overview :
Code:
$ ls -l {[moq]*,ti*}
-rw-------  1 ctsgnb  users  1289 Nov 27 17:39 men
-rw-------  1 ctsgnb  users   764 Nov 22 16:41 myd
-rw-------  1 ctsgnb  users   319 Nov 27 00:49 myscript
-rw-------  1 ctsgnb  users    90 Dec  2 15:05 output
-rw-------  1 ctsgnb  users  1082 Nov 27 06:56 questions
-rw-------  1 ctsgnb  users  1301 Nov 27 10:12 tick
-rw-------  1 ctsgnb  users    28 Nov 30 16:52 titi

 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

how to open the linux text file in windows

Hi friends, help me i downloaded some file from the Linux and i copied it to windows.Now i am unable to open those file. please help me how to open those file. the files are something like test.tcl note.tcl Thanking you Praveen (2 Replies)
Discussion started by: prakumar
2 Replies

2. Shell Programming and Scripting

Open Text file input data and save it.

Hi Guys, I have blank file A.txt I will run the script xyz.sh First i want to open a.txt file... Now i will enter some data like XYZ ABC PQR .. Save it and keep continue my script.... END of my script. Thanks (1 Reply)
Discussion started by: asavaliya
1 Replies

3. UNIX and Linux Applications

Notepad++ hang when open file edited in other text editor

Hi, I would like to ask about the notepad++ text editor application, Although there are alternative and more great text editor in linux (gedit, geany, jedit) im still using the notepad++ sometimes cause for some of my own reason one of those is the minimalist text(what i mean is notepad++ has a... (2 Replies)
Discussion started by: jao_madn
2 Replies

4. Shell Programming and Scripting

How to open a huge text file?

Hi. I have a 10 Gb text file.the default text editor in ubuntu doens't open it. Does anyone know how can i open it?? Thanks (4 Replies)
Discussion started by: stalaei
4 Replies

5. Shell Programming and Scripting

Open the file and edit/append the text

Hi i have a file like this mailboxnum 20 filename <to subsitute> fileloaction /home/dd234/ filetype txt in a directory i have set of files for ex: TT45.1.2 TT45.1.3 TT45.1.4 . . in for loop i have to take this files and subsitute one by one ex: (1 Reply)
Discussion started by: greenworld123
1 Replies

6. UNIX Desktop Questions & Answers

cannot open text file

Hi I am a new to linux, I was faced a file to know is a text file but its type isn't text document and I cannot open it, please guide me. Regards. (2 Replies)
Discussion started by: mkhorami76
2 Replies

7. UNIX for Advanced & Expert Users

script to open the specified url in a browser from a text file

Hi All, here i am struc (6 Replies)
Discussion started by: gsp
6 Replies

8. UNIX for Advanced & Expert Users

examine core file after abort()

I'm running Red Hat Linux 2.6.7 on a x86_64 box. I have a core file from a program that called abort(). Does anyone here know how can I get a backtrace? (Re-creating the error with svd running inside gdb has proved impossible). % gdb svd core.25223 GNU gdb Red Hat Linux... (2 Replies)
Discussion started by: svact
2 Replies

9. UNIX for Dummies Questions & Answers

how to open a text file using some tool such as gedit under gtk

how to open a text file using some tool such as gedit under gtk I list some text file names in a GtkCList . I want to open the file on when users click on the row. How to implement this ? Thanks (0 Replies)
Discussion started by: cy163
0 Replies

10. UNIX for Dummies Questions & Answers

how to open a text file by double clicking on the file name in gtk+

how to open a text file by double clicking on the file name shown in a label widget in gtk+. thanks (0 Replies)
Discussion started by: cy163
0 Replies
Login or Register to Ask a Question