right click association of gnuplot plot files



I have a program for some mathematical calculations. I use gnuplot to
plot the results.
My program creates files with the extension .plt, e.g. U10.plt. To plot
the results in this file, I open a terminal, cd to the directory of
where U10.plt resides, and I type the command
gnuplot U10.plt
That works OK. But it would be easier if I can plot the data in the .plt
files by clicking on it in the Nautilus file manger. However, simply
associating the file with gnuplot (using the properties of U10.plt) does
not work.
How can I start gnuplot by clicking on a .plt file in the Nautilus file
manger (Ubuntu)?

Directly associating a .plt file to gnuplot doesn't seem to work.
Therefore I tried the following sript file as a work around:

#!/bin/csh
gedit $1
#/usr/bin/gnuplot
#/usr/bin/gnuplot $1

If I associate .plt file with this script, the .plt file will be opened
by gedit.
However, if I change the script into:

#!/bin/csh
#gedit $1
/usr/bin/gnuplot
#/usr/bin/gnuplot $1

nothing happens...
(In a terminal /usr/bin/gnuplot starts gnuplot)
It seems that gnuplot is not started by Nautilus

Obviously, for
#!/bin/csh
#gedit $1
#/usr/bin/gnuplot
/usr/bin/gnuplot $1

nothing happens.

How to resolve this?







[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]