User Tools

Site Tools


config:nemo-performance

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
config:nemo-performance [2023/03/28 00:33] Wulf Rajekconfig:nemo-performance [2024/11/12 10:59] (current) Wulf Rajek
Line 35: Line 35:
  
 Global action scripts need to be placed in ''/usr/share/nemo/actions'' and user actions can be placed in ''~/.local/share/nemo/actions/''. File extension has to be ''.nemo_action''. Global action scripts need to be placed in ''/usr/share/nemo/actions'' and user actions can be placed in ''~/.local/share/nemo/actions/''. File extension has to be ''.nemo_action''.
 +
 +<code>cd ~/.local/share/nemo/actions/</code>
  
 A full description of the syntax is available in the sample file ''/usr/share/nemo/actions/sample.nemo_action'' A full description of the syntax is available in the sample file ''/usr/share/nemo/actions/sample.nemo_action''
Line 57: Line 59:
 Dependencies=gprename; Dependencies=gprename;
 </code> </code>
 +
 +=== Image convert / rotate ====
 +
 +<code>
 +sudo apt-get install nemo-image-converter
 +</code>
 +Then restart nemo to activate the plugin. Right-click context menu entries for images will be available.
  
 === MP3 Tagging example scripts === === MP3 Tagging example scripts ===
Line 107: Line 116:
 <code> <code>
 chmod 755 .local/share/nemo/actions/beets_import_album.sh chmod 755 .local/share/nemo/actions/beets_import_album.sh
 +</code>
 +
 +=== Copy Full Path to clipboard ===
 +
 +<code - ~/.local/share/nemo/actions/copy_full_filepath.nemo_action>
 +[Nemo Action]
 +Name=Copy Full Filepath
 +Comment=Full Path: %F
 +Exec=sh -c "readlink -f %F | xclip -selection clipboard"
 +Icon-Name=gtk-copy
 +Selection=notnone
 +Extensions=dir;nodirs
 +Separator=,
 +Dependencies=readlink;xclip;
 </code> </code>
  
Line 177: Line 200:
 Restore session on Cinnamon start: Restore session on Cinnamon start:
 <code> <code>
-cat > ~/.config/autostart/nemo_restore.desktop << EOD+/usr/bin/cat > ~/.config/autostart/nemo_restore.desktop << EOD
 [Desktop Entry] [Desktop Entry]
 Version=1.0 Version=1.0
Line 198: Line 221:
 Attach file to email Thunderbird: Attach file to email Thunderbird:
 <code> <code>
-cat > ~/.local/share/nemo/actions/attach_to_email_tbird.nemo_action << "EOD"+/usr/bin/cat > ~/.local/share/nemo/actions/attach_to_email_tbird.nemo_action << "EOD"
 [Nemo Action] [Nemo Action]
 Name=_Attach to email Name=_Attach to email
 Comment=Attach %F to email in Thunderbird Comment=Attach %F to email in Thunderbird
-Exec=thunderbird -compose to=,"attachment='%F'"+Exec=thunderbird -compose to=,attachment=%F
 Icon-Name=mail-attachment-symbolic Icon-Name=mail-attachment-symbolic
 Selection=notnone Selection=notnone
Line 213: Line 236:
 Attach file to email general: Attach file to email general:
 <code> <code>
-cat > ~/.local/share/nemo/actions/attach_to_email_xdg-email.nemo_action << "EOD"+/usr/bin/cat > ~/.local/share/nemo/actions/attach_to_email_xdg-email.nemo_action << "EOD"
 [Nemo Action] [Nemo Action]
 Name=_Attach to email Name=_Attach to email
Line 227: Line 250:
 mkdir -p ~/.local/share/nemo/actions/action_scripts mkdir -p ~/.local/share/nemo/actions/action_scripts
  
-cat > ~/.local/share/nemo/actions/action_scripts/attach_to_email_xdg-email.sh << "EOD"+/usr/bin/cat > ~/.local/share/nemo/actions/action_scripts/attach_to_email_xdg-email.sh << "EOD"
 #!/bin/bash #!/bin/bash
 COMMAND="xdg-email" COMMAND="xdg-email"
Line 235: Line 258:
 done done
 sh -c "$COMMAND" sh -c "$COMMAND"
 +EOD
 </code> </code>
  
 Edit with xed as superuser: Edit with xed as superuser:
 <code> <code>
-cat > ~/.local/share/nemo/actions/xed_sudoedit.nemo_action << "EOD"+/usr/bin/cat > ~/.local/share/nemo/actions/xed_sudoedit.nemo_action << "EOD"
 [Nemo Action] [Nemo Action]
  
Line 260: Line 284:
 mkdir -p ~/.local/share/nemo/actions/action_scripts mkdir -p ~/.local/share/nemo/actions/action_scripts
  
-cat > ~/.local/share/nemo/actions/action_scripts/xed_sudoedit_check.sh << "EOD"+/usr/bin/cat > ~/.local/share/nemo/actions/action_scripts/xed_sudoedit_check.sh << "EOD"
 #!/bin/bash #!/bin/bash
 FILEOWNER=$(stat -c %U "$1") FILEOWNER=$(stat -c %U "$1")
Line 274: Line 298:
 sudo apt-get install zenity sudo apt-get install zenity
  
-cat > ~/.local/share/nemo/actions/action_scripts/zenity_askpass.sh << "EOD"+/usr/bin/cat > ~/.local/share/nemo/actions/action_scripts/zenity_askpass.sh << "EOD"
 #!/bin/bash #!/bin/bash
 zenity --password --title="Authenticate" zenity --password --title="Authenticate"
Line 282: Line 306:
 Edit with vi as superuser: Edit with vi as superuser:
 <code> <code>
-cat > ~/.local/share/nemo/actions/vi_sudoedit.nemo_action << "EOD"+/usr/bin/cat > ~/.local/share/nemo/actions/vi_sudoedit.nemo_action << "EOD"
 [Nemo Action] [Nemo Action]
  
Line 303: Line 327:
 mkdir -p ~/.local/share/nemo/actions/action_scripts mkdir -p ~/.local/share/nemo/actions/action_scripts
  
-cat > ~/.local/share/nemo/actions/action_scripts/vi_sudoedit_check.sh << "EOD"+/usr/bin/cat > ~/.local/share/nemo/actions/action_scripts/vi_sudoedit_check.sh << "EOD"
 #!/bin/bash #!/bin/bash
 FILEOWNER=$(stat -c %U "$1") FILEOWNER=$(stat -c %U "$1")
Line 317: Line 341:
 Show dpkg package of file or folder: Show dpkg package of file or folder:
 <code> <code>
-cat > ~/.local/share/nemo/actions/show_parent_package.nemo_action << "EOD"+/usr/bin/cat > ~/.local/share/nemo/actions/show_parent_package.nemo_action << "EOD"
 [Nemo Action] [Nemo Action]
 Name=Show _Parent Package Name=Show _Parent Package
-Comment=Display a dialogue that shows which package %F'is from+Comment=Display a dialogue that shows which package %F is from
 Exec=<action_scripts/show_parent_package.sh %F> Exec=<action_scripts/show_parent_package.sh %F>
 Icon-Name=package-x-generic-symbolic Icon-Name=package-x-generic-symbolic
Line 332: Line 356:
 sudo apt-get install zenity sudo apt-get install zenity
  
-cat > ~/.local/share/nemo/actions/action_scripts/show_parent_package.sh << "EOD"+/usr/bin/cat > ~/.local/share/nemo/actions/action_scripts/show_parent_package.sh << "EOD"
 #!/bin/dash #!/bin/dash
 OUTPUT=$(dpkg -S "$1" | cut -f1 -d:) OUTPUT=$(dpkg -S "$1" | cut -f1 -d:)
Line 342: Line 366:
 EOD EOD
 </code> </code>
 +
 +Various Nautilus scripts can be found here:
 +https://github.com/cfgnunes/nautilus-scripts
 +
 +==== Action Submenus ====
 +
 +{{:config:pasted:20241112-105830.png}}\\ 
 +
 +GUI change through Nemo -> Edit -> Preferences -> Plugins -> Edit Layout:\\ 
 +{{:config:pasted:20241112-105501.png}}
 +
 +
 +
 +Example of submenu for action scripts:
 +
 +<code - ~/.config/nemo/actions-tree.json>
 +,
 +    {
 +      "uuid": "Video Manipulations",
 +      "type": "submenu",
 +      "user-label": "Video Manipulations",
 +      "user-icon": null,
 +      "children": [
 +        {
 +          "uuid": "video_bitrate.nemo_action",
 +          "type": "action",
 +          "user-label": null,
 +          "user-icon": null
 +        },
 +        {
 +          "uuid": "video_downscale.nemo_action",
 +          "type": "action",
 +          "user-label": null,
 +          "user-icon": null
 +        },
 +        {
 +          "uuid": "video_merge.nemo_action",
 +          "type": "action",
 +          "user-label": null,
 +          "user-icon": null
 +        },
 +        {
 +          "uuid": "video_hflip.nemo_action",
 +          "type": "action",
 +          "user-label": null,
 +          "user-icon": null
 +        },
 +        {
 +          "uuid": "video_vflip.nemo_action",
 +          "type": "action",
 +          "user-label": null,
 +          "user-icon": null
 +        },
 +        {
 +          "uuid": "video_mergechapters.nemo_action",
 +          "type": "action",
 +          "user-label": null,
 +          "user-icon": null
 +        }
 +      ]
 +    },
 +</code>
 +
  
config/nemo-performance.1679959999.txt.gz · Last modified: 2023/05/29 11:53 (external edit)