surfplank

Submitted scripts and programs
Forum rules
Your own work only.
User avatar
Alad
should take a shower
Posts: 447
Joined: Wed May 21, 2014 12:52 am

surfplank

Unread post by Alad » Tue May 27, 2014 3:23 am

edit: This sucks. See here for something sensible.

Sets the default browser. Browsers and DEs alike fail on this one, making you second-guess whenever you open a link.

I'm sure there are much better/simpler ways to do this - though it's simpler than convincing DE/browser developers to fix their stuff.

Version 2: http://linuxbbq.org/bbs/viewtopic.php?f ... 377#p26377

https://raw.githubusercontent.com/AladW ... /surfplank
Last edited by Alad on Thu Sep 25, 2014 4:20 pm, edited 5 times in total.
It's funny how we used to be able to do real stuff with rudimentary computers, but now we can't. -- ratcheer

User avatar
wuxmedia
Grasshopper
Posts: 6454
Joined: Wed Oct 17, 2012 11:32 am
Location: Back in Blighty
Contact:

Re: surfplank

Unread post by wuxmedia » Tue May 27, 2014 7:35 am

wow, nice!
Thanks.
"Seek, and Ye shall find"
"Github | Chooons | Site"

machinebacon
Baconator
Posts: 10253
Joined: Thu Sep 16, 2010 11:03 am
Location: Pfälzerwald
Contact:

Re: surfplank

Unread post by machinebacon » Tue May 27, 2014 8:36 am

Thank you, will test later :)
..gnutella..

User avatar
Alad
should take a shower
Posts: 447
Joined: Wed May 21, 2014 12:52 am

Re: surfplank

Unread post by Alad » Sat Jun 21, 2014 10:26 pm

Version 2, featuring extra bloat (and now works on systems without ~/.local/... folder). Also xdg-utils stinks outside DEs, and you might look for a better alternative (like mimeo).

Link because too large.

https://raw.githubusercontent.com/AladW ... /surfplank
It's funny how we used to be able to do real stuff with rudimentary computers, but now we can't. -- ratcheer

User avatar
rhowaldt
Dog
Posts: 4565
Joined: Wed Oct 17, 2012 9:01 am
Contact:

Re: surfplank

Unread post by rhowaldt » Sun Jun 22, 2014 3:34 pm

goeie naam :)
All statements are true in some sense, false in some sense, meaningless in some sense, true and false in some sense, true and meaningless in some sense, false and meaningless in some sense, and true and false and meaningless in some sense.

User avatar
Alad
should take a shower
Posts: 447
Joined: Wed May 21, 2014 12:52 am

Re: surfplank

Unread post by Alad » Thu Sep 25, 2014 4:16 pm

fbt shared a simple xdg-open alternative that uses regex patterns, instead of this convoluted desktop garbage that always misses that one type you need, and is just all over the place.

https://git.fleshless.org/sx-open/about/

Put it in your PATH where it overrides /usr/bin, e.g ~/bin

Code: Select all

export PATH=~/bin:~/.config/alternatives:$PATH
ln -s sx-open xdg-open
The alternatives folder may contain symlinks (e.g "browser" to chrome). sx-open launches the first match in sx-open.cfg, so create patterns from specific to generic.
It's funny how we used to be able to do real stuff with rudimentary computers, but now we can't. -- ratcheer

Post Reply