Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

shell integration: "open current folder in far manager" in MATE and other shells #95

Open
unxed opened this issue Sep 20, 2016 · 10 comments

Comments

@unxed
Copy link
Contributor

unxed commented Sep 20, 2016

how can it be implemented? should it be done withing far2l project or on the desktop shell's side?

@elfmz
Copy link
Owner

elfmz commented Sep 20, 2016

not sure if such thing is appropriate for far at all

@unxed
Copy link
Contributor Author

unxed commented Sep 20, 2016

I mean "open current folder in far manager". Like commonly used "open current folder in terminal".

@unxed unxed changed the title shell integration: "open in far manager" in MATE and other shells shell integration: "open current folder in far manager" in MATE and other shells Sep 20, 2016
@fleytman
Copy link

Is there a way to open far2l with the selected directory?
Like:
far2l .
far2l ~/Downloads

@stokito
Copy link

stokito commented Sep 27, 2019

@fleytman you can use far2l /cd /path/to/dir but there is some problems that I described in #599 and the fix may change the command so please vote.

@unxed In MATE you can install caja-actions package and then run configuration GUI by System / Preferences / Look and feel / Caja Actions or by terminal:

sudo apt install caja-actions
caja-actions-config-tool

Then create a text file far2l.desktop with content:

[Desktop Entry]
Type=Action
Name[en_US]=Open in Far
Name[en]=Open in Far
Name[C]=Open in Far
Tooltip[en_US]=Open in Far
Tooltip[en]=Open in Far
Tooltip[C]=Open in Far
Icon[en_US]=/usr/share/icons/hicolor/48x48/apps/far2l.svg
Icon[en]=/usr/share/icons/hicolor/48x48/apps/far2l.svg
Icon[C]=/usr/share/icons/hicolor/48x48/apps/far2l.svg
TargetLocation=true
TargetToolbar=true
ToolbarLabel[en_US]=Open in Far
ToolbarLabel[en]=Open in Far
ToolbarLabel[C]=Open in Far
Profiles=profile-zero;

[X-Action-Profile profile-zero]
Name[en_US]=Open Far in current directory
Name[en]=Open Far in current directory
Name[C]=Open Far in current directory
Exec=far2l cd
Path=%f
MimeTypes=inode/directory;
Capabilities=Local;

Then press Tools / Import assistant and import the file. Do not forget to press Ctrl+S or File / Save.
Then open Caja and you'll see a far icon in toolbar and in context menu included into Caja Actions actions .
You may want to see the Far icon directly in context menu without submenu. To do so open caja-actions-config-tool and press Edit / Preferences on Runtime prefs tab uncheck Create a root 'Caja actions' menu.

@stokito
Copy link

stokito commented Sep 27, 2019

Speaking generally far2l should create it's own .desktop file and register it in system as caja or nautilus file manages do.

@unxed
Copy link
Contributor Author

unxed commented Sep 28, 2019

@stokito thanks a lot! Item appeared in folders context menu. Is where any way to add it to menu that is appearing then I make right click on desktop's or folder's free space?

@stokito
Copy link

stokito commented Sep 28, 2019

Well, it should work like that because I checked "Display in location menu" but for some reason, it doesn't work. But there is a workaround: open MIME Types tab and replace inode/directory with *

@stokito
Copy link

stokito commented Sep 28, 2019

[Desktop Entry]
Type=Action
Name[en_US]=Open in Far
Name[en]=Open in Far
Name[C]=Open in Far
Tooltip[en_US]=Open in Far
Tooltip[en]=Open in Far
Tooltip[C]=Open in Far
Icon[en_US]=/usr/share/icons/hicolor/48x48/apps/far2l.svg
Icon[en]=/usr/share/icons/hicolor/48x48/apps/far2l.svg
Icon[C]=/usr/share/icons/hicolor/48x48/apps/far2l.svg
TargetLocation=true
TargetToolbar=true
ToolbarLabel[en_US]=Open in Far
ToolbarLabel[en]=Open in Far
ToolbarLabel[C]=Open in Far
Profiles=profile-zero;

[X-Action-Profile profile-zero]
Name[en_US]=Open Far in current directory
Name[en]=Open Far in current directory
Name[C]=Open Far in current directory
Exec=far2l cd
Path=%f

@unxed
Copy link
Contributor Author

unxed commented Sep 28, 2019

open MIME Types tab and replace inode/directory with *

Works for folders, thanks!
Still no effect on desktop :(

@stokito
Copy link

stokito commented Oct 2, 2019

@unxed to enable it for Desktop:
Open the Capabilities tab and remove the Local condition.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants