LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 09-24-2003, 10:40 PM   #1
BajaNick
Senior Member
 
Registered: Jul 2003
Location: So. Cal.
Distribution: Slack 11
Posts: 1,737

Rep: Reputation: 46
running script question


I wrote a very tiny script and when i double click on it i get the dialog box that asks if you want to open the file, run it in console and whatever else it asks.
I would like to know how i can just have it run when i click on it and not have the dialog box popup. Thanks
 
Old 09-25-2003, 09:01 PM   #2
BajaNick
Senior Member
 
Registered: Jul 2003
Location: So. Cal.
Distribution: Slack 11
Posts: 1,737

Original Poster
Rep: Reputation: 46
Anyone? hello.... hello....
 
Old 09-26-2003, 02:58 AM   #3
pe2338
Member
 
Registered: Dec 2002
Location: Bucharest,RO
Distribution: debian etch, sarge and sid
Posts: 407

Rep: Reputation: 30
MIME types???

chmod +x tinyscript ???
 
Old 09-27-2003, 12:12 AM   #4
BajaNick
Senior Member
 
Registered: Jul 2003
Location: So. Cal.
Distribution: Slack 11
Posts: 1,737

Original Poster
Rep: Reputation: 46
What do mean by mime types?
 
Old 09-27-2003, 03:00 AM   #5
then
Member
 
Registered: Oct 2002
Location: FDR India
Distribution: RH9, Knoppix, MEPIS
Posts: 65

Rep: Reputation: 15
Hi

Try registering an application to open a particular file extension.

In the case of your script (guessing its a shell script), register it run with /bin/bash in the dialog box. I guess you can also register the script to run in console. AFAIK for most standard Linux installs, /bin is in the path.

regards
theN
 
Old 09-27-2003, 07:14 PM   #6
BajaNick
Senior Member
 
Registered: Jul 2003
Location: So. Cal.
Distribution: Slack 11
Posts: 1,737

Original Poster
Rep: Reputation: 46
Yes its a bash script, I dont know what you mean by registering it?
 
Old 09-27-2003, 09:59 PM   #7
trickykid
LQ Guru
 
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 269Reputation: 269Reputation: 269
What happens if you run the script on a console or terminal?

./script

Does it run? When your double clicking, most likely there's a chance your script is running but most scripts like a simple bash script runs in a terminal or at the command line. Unless you associate your script in whatever GUI your using, you can't or won't see nothing when double clicking it there....
 
Old 09-29-2003, 01:49 AM   #8
then
Member
 
Registered: Oct 2002
Location: FDR India
Distribution: RH9, Knoppix, MEPIS
Posts: 65

Rep: Reputation: 15
Quote:
Originally posted by BajaNick
Yes its a bash script, I dont know what you mean by registering it?
Preferences >> File Types and Programs (RH9).

Registering = letting the OS know which application to use to open a particular file type.

regards
theN
 
Old 09-29-2003, 07:45 PM   #9
BajaNick
Senior Member
 
Registered: Jul 2003
Location: So. Cal.
Distribution: Slack 11
Posts: 1,737

Original Poster
Rep: Reputation: 46
When i double click on its icon it brings up a dialog box that asks if you want to run it, display it, run it in console. It runs when i choose how i want it to run i just want it to run in the console without asking me how to run it.
 
  


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
Newbie question - running a script at boot time Napalm Llama Red Hat 8 04-19-2005 03:11 PM
Running a script spacemonk Linux - Newbie 4 07-30-2004 04:02 AM
Running a script from the desktop... distortedstar Linux - Software 5 02-04-2004 08:47 PM
Question on running a script zael Programming 1 09-30-2003 01:59 PM
no result from running script cowardnewbie Programming 1 09-09-2001 07:26 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 09:41 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