LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 01-27-2007, 11:56 PM   #1
ashishjen
LQ Newbie
 
Registered: Jan 2007
Posts: 25

Rep: Reputation: 15
default application


how to know that which is the default application for a particular program like in which application should we open .jpg, .pdf etc.
 
Old 01-28-2007, 12:34 AM   #2
Hitboxx
Senior Member
 
Registered: Mar 2006
Location: India
Distribution: Fedora
Posts: 1,562
Blog Entries: 3

Rep: Reputation: 68
What distro are you using and what is your DE(KDE,Gnome,etc..)??
 
Old 01-28-2007, 12:49 AM   #3
ashishjen
LQ Newbie
 
Registered: Jan 2007
Posts: 25

Original Poster
Rep: Reputation: 15
what do u mean by distro???
i am using fedora core 5....
 
Old 01-28-2007, 03:02 AM   #4
basileus
Member
 
Registered: Nov 2004
Location: Turku, Finland
Distribution: Debian, Ubuntu, Gentoo
Posts: 388

Rep: Reputation: 30
I'm not sure about Fedora Core, but Debian has an "alternatives" system, which uses generic aliases for several program types. For example, you can define which www-browser to launch while in X. These can be edited with a program called "galternatives". I guess Fedora Core has something similar.

Then the Desktop environment... you are most likely using Gnome, if you have not specifically installed KDE or something else. You can choose some "default applications" via the Gnome settings. When opening a file, you can also right click it and select "Open with alternative application". Then select the application which is usually in /usr/bin. Next you right-click a similar file, you will see your new application in the menu automatically.
 
Old 01-28-2007, 11:14 AM   #5
ashishjen
LQ Newbie
 
Registered: Jan 2007
Posts: 25

Original Poster
Rep: Reputation: 15
well i want to open the file from terminal (so no GUI or right clicks...)and i want to know the applications with which i can open different files on my box ....
 
Old 01-28-2007, 11:40 AM   #6
b0uncer
LQ Guru
 
Registered: Aug 2003
Distribution: CentOS, OS X
Posts: 5,131

Rep: Reputation: Disabled
As said, it's the job of a desktop environment (KDE, Gnome, XFCE, ...) usually to determine which program to use to open different types of files. When working on console, you just launch a program and if it lets you to, pass the filename to it as a parameter. Like to view a plain text file
Code:
less myfile.txt
or to edit it, one of these
Code:
nano myfile.txt
vi myfile.txt
pico myfile.txt
joe myfile.txt
or to launch a website (might work for .html and such files too)
Code:
links www.google.com
(or try lynx if that isn't installed)
and so on. It depends on which files you want to open, and which programs you have installed. For mp3 files there are, depending on what you have installed, available
Code:
mpg123 somemusic.mp3
mpg321 somemusic.mp3
Usually if you're lost, try
Code:
apropos keyword
man -k keyword
where 'keyword' is some word, for example
Code:
man -k whatis
and you should be presented (hopefully) with a list of some manpages (manual pages of certain programs or pieces of ssoftware) that may be related. An example:
Code:
man -k mp3
lame-libs           (rpm) - LAME MP3 encoding library
so, mp3 "lookaround" produced a manpage of lame-libs. I could read that, but as it seems to only talk about libraries, let's try
Code:
man lame
instead, and if you have lame installed, you should get it's usage instructions (lame = Lame Ain't an Mp3 Encoder). You might not be after the instructions, but the above method might help you find program names that can do something with certain files. It surely won't, however, take long before you are familiar with some of the most common tools of your system and can work with different types of files without wondernig which program to open them with.
 
Old 01-28-2007, 12:21 PM   #7
ashishjen
LQ Newbie
 
Registered: Jan 2007
Posts: 25

Original Poster
Rep: Reputation: 15
thanx a lot... man -k keyword thing is of great help....
 
  


Reply



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



Similar Threads
Thread Thread Starter Forum Replies Last Post
choosing default application painless Linux - Newbie 3 10-02-2006 10:07 AM
Default Application Change tendonut Ubuntu 10 06-13-2006 10:27 AM
Ubuntu Default Application tendonut Linux - Software 3 06-09-2006 01:46 PM
How to make it a default application? jethind Linux - Newbie 8 11-17-2005 06:36 AM
audio CD default application hildog Linux - Newbie 1 10-04-2003 05:50 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:06 PM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration