You are not logged in.

#1 2016-04-19 14:15:08

Pibosz
Member
Registered: 2016-04-19
Posts: 1

Firefox and ranger

Hello everyone,
I'm struggling with a little problem. I used to work on ubuntu/mint for about 6 year, yet I wanted to go deeper and try Arch with lightweight i3 window manager. I configured almost everything by my own thanks to archwiki and this forum, but I'm struggling with a simple thing. I'm trying to set ranger as file manager for "Downloads" directory in firefox. I was trying by manualy selecting ranger from /bin. Nothing. Then I've tried to make a bash script. Still nothing. After that I found that xdg-open is "aplication chooser" for each file/directory type. So I made ~./.local/share/applications/ranger.desktop file and added a proper line in ~/.config/mimeapps.list. Then I choose xdg-open as directory opener in firefox. That make only firefox opening directory itself. What am I doing wrong? Those are my entries:

#~./.local/share/applications/ranger.desktop
[Desktop Entry]
Encoding=UTF-8
Version=1.0
Type=Application
Exec=xterm ranger %u
Name=ranger
Comment=filebrowser
#~/.config/mimeapps.list
[Default Applications]
inode/directory=ranger.desktop
x-scheme-handler/http=userapp-Firefox-R0B3FY.desktop
x-scheme-handler/https=userapp-Firefox-R0B3FY.desktop
x-scheme-handler/ftp=userapp-Firefox-R0B3FY.desktop
x-scheme-handler/chrome=userapp-Firefox-R0B3FY.desktop
text/html=userapp-Firefox-R0B3FY.desktop
application/x-extension-htm=userapp-Firefox-R0B3FY.desktop
application/x-extension-html=userapp-Firefox-R0B3FY.desktop
application/x-extension-shtml=userapp-Firefox-R0B3FY.desktop
application/xhtml+xml=userapp-Firefox-R0B3FY.desktop
application/x-extension-xhtml=userapp-Firefox-R0B3FY.desktop
application/x-extension-xht=userapp-Firefox-R0B3FY.desktop

[Added Associations]

Maybe it is something wrong with those files? I will appreciate any kind of help.

Offline

#2 2020-02-11 23:48:41

dirdi
Member
Registered: 2020-02-11
Posts: 2
Website

Re: Firefox and ranger

Your mimeapps.list seems fine to me. Modify your ranger.desktop to:

[Desktop Entry]
Type=Application
Name=ranger
Comment=Launches the ranger file manager
Icon=utilities-terminal
Terminal=true
Exec=ranger
Categories=ConsoleOnly;System;FileTools;FileManager
MimeType=inode/directory;
Keywords=File;Manager;Browser;Explorer;Launcher;Vi;Vim;Python

Afterwards configure Firefox to use xdg-open for directories. xdg-open will then in turn fire up ranger.

(I am aware that this thread is ~4 years old. However, it ranks high on Google and thus I want to provide a solution.)

Offline

#3 2020-02-12 14:13:48

2ManyDogs
Forum Moderator
Registered: 2012-01-15
Posts: 4,645

Re: Firefox and ranger

Thanks for the contribution, but as you noted, this thread is four years old.

Closing.


How to post. A sincere effort to use modest and proper language and grammar is a sign of respect toward the community.

Offline

Board footer

Powered by FluxBB