LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Print Directory command (https://www.linuxquestions.org/questions/linux-newbie-8/print-directory-command-691870/)

catholiclibertarian 12-20-2008 06:29 AM

Print Directory command
 
I'm looking to find a command from within terminal that will give me something along the lines of

print all images /entire-path/to-directory

ideally bringing up the GUI to allow me to choose which printer etc. (so I can choose if I want to print to PDF or to CUPS) it simply takes too long to open each photo, FILE, PRINT

megerdin 12-20-2008 09:12 AM

i thinks not. U can use lpr command to print a single OR more.

Quote:

lpr file1 file2 file 3

catholiclibertarian 12-20-2008 09:03 PM

is there not a way to edit lpr to allow it to print the whole directory, at least if the directory only includes images?

how about an option of selecting multiple files in thunar (or konqueror, etc.) and then right clicking and select print.

Could creating a shortcut to lpr within the right click menu give me this option?

megerdin 12-21-2008 06:33 AM

I m confused some other may help you.

Disillusionist 12-21-2008 06:53 AM

With Nautilus you can right-click "open with" choose "open with another application" type lpr

Then when you right-click "open with" choose "open with lpr"

From a command line if you wanted to print all jpg files you could:
Code:

for file in $(ls *.jpg); do
  lpr $file
done


PTrenholme 12-21-2008 07:24 AM

Or, even simpler, lpr *.jpg. But that assumes that all you image files have a jpg extension.

If, instead, you wanted to print every file in, say, an "images" sub-directory of your current directory, you could do a lpr images/* or something similar. See info bash under "Basic Shell Features" in the "Shell Expansion" section for a description of how the shell expands things like "*" and so on.

Also, look at man lpr for a description of the lpr command options.

shane25119 12-21-2008 11:47 AM

It seems what you want is a graphical program to select which images to print- kind of like WinXP does.

Try Picassa for Linux- I'm pretty sure it allows you to do that.

upchucky 12-21-2008 06:51 PM

i think fspot also lets u do that and name time date stamp them too

catholiclibertarian 12-22-2008 05:41 PM

I actually would prefer to do it from the command line. Thanks for the assistance! I can't wait to try it.


All times are GMT -5. The time now is 04:23 PM.