Skip to content

Instantly share code, notes, and snippets.

@stephenharris
Created April 4, 2015 10:03
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save stephenharris/f78a173e235b8d0a9dd7 to your computer and use it in GitHub Desktop.
Save stephenharris/f78a173e235b8d0a9dd7 to your computer and use it in GitHub Desktop.
Print selected files form the right-click context menu in Nautilus
#!/bin/bash
#
# print-selected.sh
#
# Print files from the right-click context menu in Nautilus.
# Place this script in ~/.local/share/nautilus/scripts & make executable.
#
# @see http://askubuntu.com/questions/319948/printing-multiple-files-from-nautilus
# @see http://www.frenssen.be/content/printing-file-right-click-context-menu-nautilus
for i in $NAUTILUS_SCRIPT_SELECTED_FILE_PATHS
do
lpr $i
done
exit 0
@aliakhtar49
Copy link

can we apply nautilus script to particular directory.

Like
/home/user/Desktop/directory

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment