config:nemo-performance
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| config:nemo-performance [2020/11/14 18:51] – Wulf Rajek | config:nemo-performance [2025/09/17 21:22] (current) – Wulf Rajek | ||
|---|---|---|---|
| Line 35: | Line 35: | ||
| Global action scripts need to be placed in ''/ | Global action scripts need to be placed in ''/ | ||
| + | |||
| + | < | ||
| A full description of the syntax is available in the sample file ''/ | A full description of the syntax is available in the sample file ''/ | ||
| - | More examples can be found at https:// | + | More examples |
| The sample file is also here:\\ | The sample file is also here:\\ | ||
| https:// | https:// | ||
| + | |||
| + | === Mass renaming === | ||
| + | |||
| + | < | ||
| + | sudo apt-get install gprename | ||
| + | </ | ||
| + | <code - bulk-rename.nemo_action> | ||
| + | [Nemo Action] | ||
| + | Name=Bulk Rename | ||
| + | Comment=Multiple Rename with GPRename. | ||
| + | Exec=gprename %F | ||
| + | Selection=m | ||
| + | Extensions=any; | ||
| + | EscapeSpaces=true | ||
| + | Dependencies=gprename; | ||
| + | </ | ||
| + | |||
| + | === Image convert / rotate ==== | ||
| + | |||
| + | < | ||
| + | sudo apt-get install nemo-image-converter | ||
| + | </ | ||
| + | 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 92: | Line 117: | ||
| chmod 755 .local/ | chmod 755 .local/ | ||
| </ | </ | ||
| + | |||
| + | === Copy Full Path to clipboard === | ||
| + | |||
| + | <code - ~/ | ||
| + | [Nemo Action] | ||
| + | Name=Copy Full Filepath | ||
| + | Comment=Full Path: %F | ||
| + | Exec=sh -c " | ||
| + | Icon-Name=gtk-copy | ||
| + | Selection=notnone | ||
| + | Extensions=dir; | ||
| + | Separator=, | ||
| + | Dependencies=readlink; | ||
| + | </ | ||
| + | |||
| ==== Nemo Performance ==== | ==== Nemo Performance ==== | ||
| Line 112: | Line 152: | ||
| nemo -q | nemo -q | ||
| </ | </ | ||
| + | |||
| + | ==== Save/ | ||
| + | |||
| + | Execute nemo_save.sh to save list of opened nemo windows in ~/ | ||
| + | |||
| + | Launch nemo_restore.sh to reopen saved list of windows. | ||
| + | |||
| + | Restrictions : the script cannot save opened tabs, and won't save a folder whose name is too long. For special folders like Trash, you can replace the window title name in nemo_save.sh if you know the full path. Also, only the currently active pane in two-pane mode is being saved. | ||
| + | |||
| + | Original source: https:// | ||
| + | |||
| + | <code - ~/ | ||
| + | #!/bin/bash | ||
| + | declare -x DISPLAY=": | ||
| + | sleep 5 | ||
| + | PATHS=$(wmctrl -lx | grep nemo.Nemo | sed -e " | ||
| + | if [ " | ||
| + | then | ||
| + | echo "" | ||
| + | else | ||
| + | echo " | ||
| + | fi | ||
| + | </ | ||
| + | |||
| + | <code - ~/ | ||
| + | #!/bin/bash | ||
| + | sleep 2 | ||
| + | IFS=$' | ||
| + | |||
| + | for dir in " | ||
| + | nemo " | ||
| + | sleep 0.5 | ||
| + | done | ||
| + | </ | ||
| + | |||
| + | < | ||
| + | chmod 755 ~/ | ||
| + | #Add to current user's crontab | ||
| + | (crontab -l ; echo "*/5 * * * * / | ||
| + | </ | ||
| + | |||
| + | Auto-save on Cinnamon shutdown: | ||
| + | < | ||
| + | echo " | ||
| + | </ | ||
| + | |||
| + | Restore session on Cinnamon start: | ||
| + | < | ||
| + | / | ||
| + | [Desktop Entry] | ||
| + | Version=1.0 | ||
| + | Type=Application | ||
| + | Encoding=UTF-8 | ||
| + | Name=Restore Nemo Session | ||
| + | Exec=/ | ||
| + | Terminal=false | ||
| + | StartupNotify=false | ||
| + | Categories=Application; | ||
| + | X-GNOME-Autostart-enabled=true | ||
| + | X-GNOME-Autostart-Delay=10 | ||
| + | EOD | ||
| + | </ | ||
| + | |||
| + | ==== Action Scripts ==== | ||
| + | |||
| + | https:// | ||
| + | |||
| + | Attach file to email Thunderbird: | ||
| + | < | ||
| + | / | ||
| + | [Nemo Action] | ||
| + | Name=_Attach to email | ||
| + | Comment=Attach %F to email in Thunderbird | ||
| + | Exec=thunderbird -compose to=, | ||
| + | Icon-Name=mail-attachment-symbolic | ||
| + | Selection=notnone | ||
| + | Extensions=nodirs | ||
| + | Separator=, | ||
| + | Dependencies=thunderbird; | ||
| + | EOD | ||
| + | </ | ||
| + | |||
| + | Attach file to email general: | ||
| + | < | ||
| + | / | ||
| + | [Nemo Action] | ||
| + | Name=_Attach to email | ||
| + | Comment=Attach %F to email in default mail application | ||
| + | Exec=< | ||
| + | Icon-Name=mail-attachment-symbolic | ||
| + | Selection=notnone | ||
| + | Extensions=nodirs | ||
| + | Quote=double | ||
| + | Dependencies=xdg-email; | ||
| + | EOD | ||
| + | |||
| + | mkdir -p ~/ | ||
| + | |||
| + | / | ||
| + | #!/bin/bash | ||
| + | COMMAND=" | ||
| + | for file in " | ||
| + | do | ||
| + | COMMAND=" | ||
| + | done | ||
| + | sh -c " | ||
| + | EOD | ||
| + | </ | ||
| + | |||
| + | Edit with xed as superuser: | ||
| + | < | ||
| + | / | ||
| + | [Nemo Action] | ||
| + | |||
| + | Name=_Xed (Sudoedit) | ||
| + | Comment=Open %F with xed opening as different user when needed via sudoedit. | ||
| + | Exec=< | ||
| + | Icon-Name=text-editor-symbolic | ||
| + | #Stock-Id= | ||
| + | Selection=s | ||
| + | # | ||
| + | Mimetypes=text/ | ||
| + | # | ||
| + | #Quote= | ||
| + | Dependencies=sudoedit; | ||
| + | # | ||
| + | EscapeSpaces=true | ||
| + | Terminal=false | ||
| + | EOD | ||
| + | |||
| + | mkdir -p ~/ | ||
| + | |||
| + | / | ||
| + | #!/bin/bash | ||
| + | FILEOWNER=$(stat -c %U " | ||
| + | if [ " | ||
| + | xed " | ||
| + | else | ||
| + | export SUDO_EDITOR=" | ||
| + | export SUDO_ASKPASS=" | ||
| + | sudoedit -A -u " | ||
| + | fi | ||
| + | EOD | ||
| + | |||
| + | sudo apt-get install zenity | ||
| + | |||
| + | / | ||
| + | #!/bin/bash | ||
| + | zenity --password --title=" | ||
| + | EOD | ||
| + | </ | ||
| + | |||
| + | Edit with vi as superuser: | ||
| + | < | ||
| + | / | ||
| + | [Nemo Action] | ||
| + | |||
| + | Name=_vi (Sudoedit) | ||
| + | Comment=Open %F with vi opening as different user when needed via sudoedit. | ||
| + | Exec=< | ||
| + | Icon-Name=text-editor-symbolic | ||
| + | #Stock-Id= | ||
| + | Selection=s | ||
| + | # | ||
| + | Mimetypes=text/ | ||
| + | # | ||
| + | #Quote= | ||
| + | Dependencies=sudoedit; | ||
| + | # | ||
| + | EscapeSpaces=true | ||
| + | Terminal=false | ||
| + | EOD | ||
| + | |||
| + | mkdir -p ~/ | ||
| + | |||
| + | / | ||
| + | #!/bin/bash | ||
| + | FILEOWNER=$(stat -c %U " | ||
| + | if [ " | ||
| + | vi " | ||
| + | else | ||
| + | export SUDO_EDITOR=" | ||
| + | sudoedit -A -u " | ||
| + | fi | ||
| + | EOD | ||
| + | </ | ||
| + | |||
| + | Show dpkg package of file or folder: | ||
| + | < | ||
| + | / | ||
| + | [Nemo Action] | ||
| + | Name=Show _Parent Package | ||
| + | Comment=Display a dialogue that shows which package %F is from | ||
| + | Exec=< | ||
| + | Icon-Name=package-x-generic-symbolic | ||
| + | Selection=s | ||
| + | Extensions=any; | ||
| + | EscapeSpaces=true | ||
| + | Dependencies=zenity; | ||
| + | EOD | ||
| + | |||
| + | mkdir -p ~/ | ||
| + | sudo apt-get install zenity | ||
| + | |||
| + | / | ||
| + | #!/bin/dash | ||
| + | OUTPUT=$(dpkg -S " | ||
| + | if [ -z " | ||
| + | zenity --info --ellipsize --text=" | ||
| + | else | ||
| + | zenity --info --ellipsize --text=" | ||
| + | fi | ||
| + | EOD | ||
| + | </ | ||
| + | |||
| + | Various Nautilus scripts can be found here: | ||
| + | https:// | ||
| + | |||
| + | ==== Action Submenus ==== | ||
| + | |||
| + | {{: | ||
| + | |||
| + | GUI change through Nemo -> Edit -> Preferences -> Plugins -> Edit Layout: | ||
| + | {{: | ||
| + | |||
| + | |||
| + | |||
| + | Example of submenu for action scripts: | ||
| + | |||
| + | <code - ~/ | ||
| + | , | ||
| + | { | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | { | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | }, | ||
| + | { | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | }, | ||
| + | { | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | }, | ||
| + | { | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | }, | ||
| + | { | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | }, | ||
| + | { | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | } | ||
| + | ] | ||
| + | }, | ||
| + | </ | ||
| + | |||
| + | ==== Python Extensions ==== | ||
| + | |||
| + | Open TortoiseHG here context menu: | ||
| + | < | ||
| + | sudo apt-get install nemo-python | ||
| + | mkdir -p ~/ | ||
| + | wget https:// | ||
| + | mv tortoisehg-here.py ~/ | ||
| + | </ | ||
| + | |||
config/nemo-performance.1605379890.txt.gz · Last modified: (external edit)