How to set a terminall command to run every time I start firefox? I perfer terminal way, not gui. Thanks!
2 Answers
You could create a custom wrapper for Firefox, like so:
#!/bin/bash
rm -rf ~/.wine-pipelight/*
rm -rf ~/.wine-pipelight/./.*
cp -a ~/viewright_backup/. ~/.wine-pipelight/
firefox $*
and save it as a script somewhere, e.g. in /usr/local/bin/firefox-wrapped
Next, create a custom starter that runs /usr/local/bin/firefox-wrapped
. I use alacarte
to create .desktop
files.
-
And where is the .desktop file located? I'm trying to run the firefox locked to launcher. Will it work? Jul 6, 2014 at 10:30
-
Using alacarte should put it in all the right places automatically. If you prefer to write your .desktop files yourself, you can put them in ~/.local/share/applications. Jul 6, 2014 at 10:33
-
-
many desktop environments and application launchers honor .desktop files in that directory, it's a default location. Jul 6, 2014 at 21:55
edit the firefox lunch properties
command
firefox %u; rm -rf ~/.wine-pipelight/*; rm -rf ~/.wine-pipelight/./.*; cp -a ~/viewright_backup/. ~/.wine-pipelight/
you can check the lunch in terminal but if you close the terminal the firefox shuts down too
-
Ok, so if i change the .desktop file of firefox and replace the command with this, will it work when I run firefox from launcher? Jul 6, 2014 at 10:20
-
So, is it possible to change the .desktop file(using terminal) to have this command? Thank you very much! Jul 6, 2014 at 10:23
-
yea & you are trying to make your brother re install the wine so many times :s– hwezJul 6, 2014 at 10:24
-
No, the problem is that this wine extenssion(pipelight) works only the first time, only after install. So if you want it to run it again, you must reinstall it, which takes several minutes(to download and so on...) So just by doing this, you don't need to wait that long. Jul 6, 2014 at 10:26
-
rm -rf ~/.wine-pipelight/*; rm -rf ~/.wine-pipelight/./.*; cp -a ~/viewright_backup/. ~/.wine-pipelight/
every time I start firefox.