Jump to content

Copy + Print


nullArray

Recommended Posts

I TA a UNIX class for my school and this week I'm grading papers.

Our online homework hand-in tool arranges documents like the photo depicts.

post-12442-1233335249_thumb.png

I'd like a convenient way to print all of these documents..., but they must be printed separately for the the finisher to staple them. Note, documents are .doc, .docx, and .pdf and there are about 150 "student username" folders..., which is about how many documents there are too.

First I tried this:

ls */*/*.docx > docxs

Then using a substitute in vi to replace spaces with backslashes (everyone's filename is different), then to add lpr -printername in front of all the lines. Then I sh'ed that to execute, but it obviously didn't work because lpr won't print any of those files on our UNIX server (duh). It is supposed to print PDFs but we've been having postscript errors lately, according to my boss...,

Then I tried:

mkdir docs
cp */*/*.docs docs

My intention was just to FTP into the disk and print the copied files, conveniently in one directory, from my computer instead of the shell..., would have worked...but some students used the exact same file name, ex: "Homework1.pdf" and there were dozens of files that weren't copied. Worse, is that not all of them put their names on their assignments, and "Homework1" doesn't tell me who they are.

Any suggestions? Other wise, it looks like I'll be going thru folder by folder printing them one by one....

For the next assignment, we have stricter rules for naming...(username_homework#.pdf), which will allow me to use my second idea without any worry of messing someone up.

Thanks.

Link to comment
Share on other sites

This might seem kinda harsh, but seriously...

Throw away the assignments for whose owners couldn't be bothered with indentifying themselves. Is this a college class? At that stage of the game they should know.

Can't you just copy w/e with cp *.* instead of specifying the extensions since thier all in a patiular directory? Don't know about cp, but xcopy has a switch to copy all sub-dirs and thier files too.

Link to comment
Share on other sites

This might seem kinda harsh, but seriously...

Throw away the assignments for whose owners couldn't be bothered with indentifying themselves. Is this a college class? At that stage of the game they should know.

Can't you just copy w/e with cp *.* instead of specifying the extensions since thier all in a patiular directory? Don't know about cp, but xcopy has a switch to copy all sub-dirs and thier files too.

Printing the pdf's isn't a problem (asuming you are using Linux):

lpr -P "printerName" document.pdf.

You can actually print from the command line with OOo, but you need version 3 for docx support (ok, not too much of a problem), but then you have to worry about formatting. I'd be tempted to mass convert all submitted doc's and docx's to pdf (and in future ask your students to submit both doc/docx and pdf (less work for you, 2 clicks for them), then just command line them out.

Assuming your printer driver can be configured to stable each document by default this should work.

Link to comment
Share on other sites

Printing the pdf's isn't a problem (asuming you are using Linux):

lpr -P "printerName" document.pdf.

You can actually print from the command line with OOo, but you need version 3 for docx support (ok, not too much of a problem), but then you have to worry about formatting. I'd be tempted to mass convert all submitted doc's and docx's to pdf (and in future ask your students to submit both doc/docx and pdf (less work for you, 2 clicks for them), then just command line them out.

Assuming your printer driver can be configured to stable each document by default this should work.

The printer isn't configured for "post script 3" (2 only)..., which is what our UNIX server uses. For whatever reason, pdf, doc and docx uses 3 and my boss hasn't or can't change it.

Annoying, but I used my second plan and when the cp command yelled at me for copying the same file twice, I just went and found the uncopied files manually. Next assignment, this won't happen.

Printing the documents was a pain: select all, right click, print, "Printing 200 documents will slow down your computer, are you sure you want to do this?," okay, open word, print, close word, open word, print, close word, open word, print, close word, open word, print, close word, open word, print, close word, open word, print, close word, open word, print, close word, open word, print, close word, open word, print, close word, open word, print, close word, x 200.

Windows is bizarre.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...