LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices

Reply
 
LinkBack Search this Thread
Old 01-17-2006, 07:23 PM   #1
zaid
LQ Newbie
 
Registered: Jan 2006
Posts: 5

Rep: Reputation: 0
file extensions??


hello!
what the replacement of windows file extensions in linux
how could someone recognize whta type pf file this is and run it using the suitable application?

thanks
 
Old 01-17-2006, 07:30 PM   #2
IBall
Senior Member
 
Registered: Nov 2003
Location: Perth, Western Australia
Distribution: Ubuntu, Debian, Various using VMWare
Posts: 2,088

Rep: Reputation: 55
Some linux files do have extensions - such as .odt for Open Document, .html for HTML, just like in windows.

Executable files dont need extensions, they are made executable by setting the execute permission - see man chmod.

See the manual page for the "file" command. file will tell you what type of file it is.

But really, I don't know what you are asking. Can you post more details?

--Ian
 
Old 01-17-2006, 07:32 PM   #3
pixellany
LQ Veteran
 
Registered: Nov 2005
Location: Annapolis, MD
Distribution: back to Arch
Posts: 16,661

Rep: Reputation: 425Reputation: 425Reputation: 425Reputation: 425Reputation: 425
File type extensions are the same across platforms---ie pdf is pdf, jpg is jpg etc.

You will of course find some extensions that are only used on one platform or the other.

There are typically configuration setting that tell the system what default app to use with a given extension. This will depend on the system you are using.
 
Old 01-17-2006, 07:48 PM   #4
frob23
Senior Member
 
Registered: Jan 2004
Location: Roughly 29.467N / 81.206W
Distribution: FreeBSD, NetBSD
Posts: 1,446

Rep: Reputation: 46
IBall is correct, for the most part files are determined by their magic number (which is the pattern at the start of a file) and not by extension. "man file" does a good job of explaining this.

There are applications which are aware of extensions and use them for easily location files which belong to them.
 
Old 01-17-2006, 10:28 PM   #5
SciYro
Senior Member
 
Registered: Oct 2003
Location: hopefully not here
Distribution: Gentoo
Posts: 2,038

Rep: Reputation: 51
actually, extension matter in the GUI land. The popular DE's (and all file managers iv every tried, besides worker) dont use magic numbers to determine file type (which is really sad), this makes extensions needed for users documents. On the lower levels of the system (traditional UNIX), file type is meaningless, as the user is the one who opens the file in whatever program they want.

the command "file" can be used to see what type of file something is, but it wont match files to programs or extentions.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Linux File Extensions kompact Linux - Newbie 3 04-18-2005 09:15 AM
Need help with File Extensions Linux nooB 454 Linux - Newbie 3 04-10-2005 05:41 PM
File Extensions!!! rejeK Linux - Software 5 12-20-2004 07:30 PM
File Extensions RpgActioN Slackware 1 09-22-2004 10:20 PM
GIMP file extensions Crashed_Again Linux - General 4 02-01-2003 04:05 PM


All times are GMT -5. The time now is 11:21 AM.

Main Menu
 
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration