firefox executing .sh scripts

Asked by AndyG

I am currently working on a script that i would like to be executed from a link in an html file. this html file is located on the local machine
as well as the .sh file. The .sh file prints to the terminal as well as accepts inputs from the terminal. When i double click the .sh file or
open it from the terminal window, everything works the way it should. When I click on the link in the html file, i get the save as or open
with diaglog. i do open with and chose /bin/sh. there is a flicker in the screen where the terminal opens up for a split second, and the
disapears, i check and there are no changes to the file system (which the script should do) so i know the script isn't fully running.

Is there anyway to, when clicking on the link in the html file, open the .sh file in the terminal?

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu firefox Edit question
Assignee:
No assignee Edit question
Solved by:
Johannes Pilkahn
Solved:
Last query:
Last reply:
Revision history for this message
Deepak Mishra (dpux) said :
#1

can you please state the functionality of your script ?

Revision history for this message
Johannes Pilkahn (j-pilkahn) said :
#2

can you please state the functionality of your script ?
+1

I'm sorry, but this sounds a bit fishy.

As an aside: why do you prefer the bourne shell?

Revision history for this message
AndyG (aagaeta) said :
#3

the script is to take a tgz file located in the same directory as the html file and the .sh file, move it to the local machine, then extract it, and call another script which is located in the .tgz file( i know i mentioned it is already on the local machine, this is because i am testing it now, it will most likely be put on a cd) the script also echo's the current step along with some other information. Do you need anything else?

Revision history for this message
Ben Klein (kleinb1) said :
#4

It sounds like you are trying to implement a virus or a Trojan horse. Therefore, I ask: Why would you do this?

Revision history for this message
AndyG (aagaeta) said :
#5

This is going to help with the installation of a driver. currently the user has to follow multiple steps to fully install the driver. we are trying to eliminate all the unnecessary steps. For example, for windows, the user just has to open setup.exe. we are trying to do the parallel for linux

I can see how this could look like a Trojan horse, but than again, any user on windows that downloads and runs a .exe could be opening a virus. if a person doesn't trust the source of a file, they should not open it. if you use linux, you probably know that

Revision history for this message
Johannes Pilkahn (j-pilkahn) said :
#6

This functionality exists.

Whatever this application is, offer it as a .deb binary.

The user can now, given that 'gdebi' is installed, choose to either download the file or open it with gdebi directly and install the software.

Revision history for this message
AndyG (aagaeta) said :
#7

Thank you for your help. I will run this by my boss, however, (i'm fairly new to this) how common is gdebi. ideally, this would works on all machines (redhat, suse ... ) is gdebi common on these?

Revision history for this message
Best Johannes Pilkahn (j-pilkahn) said :
#8

The 'gdebi' package installer works with .deb packages. That by nature limits it to Debian and all Debian-based distributions, one of which is Ubuntu. In those, gdebi is pretty common and included in almost all repositories.

RedHat and RedHat-based distributions use the .rpm binary installer format. A package installer exists in these distros also.

Revision history for this message
AndyG (aagaeta) said :
#9

Thanks Johannes Pilkahn, that solved my question.