Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #64144

Re: Converting folders of jpegs to single pdf per folder

Path csiph.com!usenet.pasdenom.info!news.albasani.net!news.stack.nl!newsfeed.xs4all.nl!newsfeed2.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail
Return-Path <mail@timgolden.me.uk>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.017
X-Spam-Evidence '*H*': 0.97; '*S*': 0.00; '16,': 0.03; 'python': 0.11; '05:42,': 0.16; 'drag': 0.16; 'from:addr:timgolden.me.uk': 0.16; 'from:name:tim golden': 0.16; 'golden': 0.16; 'message- id:@timgolden.me.uk': 0.16; 'received:74.55.86': 0.16; 'received:74.55.86.74': 0.16; 'received:smtp.webfaction.com': 0.16; 'received:webfaction.com': 0.16; 'subject:Converting': 0.16; 'subject:folder': 0.16; 'temp': 0.16; 'textfile': 0.16; 'tjg': 0.16; 'thursday,': 0.16; 'wrote:': 0.18; 'creating': 0.23; 'header :User-Agent:1': 0.23; 'directory.': 0.24; 'example.': 0.24; 'received:192.168.100': 0.24; 'header:In-Reply-To:1': 0.27; 'tim': 0.29; 'code': 0.31; 'lines': 0.31; 'directory,': 0.31; 'helpful.': 0.31; 'python).': 0.31; 'subject:per': 0.31; 'file': 0.32; 'weeks': 0.32; 'run': 0.32; 'text': 0.33; 'worked': 0.33; 'created': 0.35; 'useful': 0.36; 'thanks': 0.36; 'should': 0.36; 'january': 0.37; 'to:addr:python-list': 0.38; 'files': 0.38; 'pdf': 0.39; 'to:addr:python.org': 0.39; 'how': 0.40; 'easy': 0.60; 'future': 0.60; 'back': 0.62; 'email addr:gmail.com': 0.63; 'great': 0.65; 'sample': 0.67; 'useful.': 0.68; 'walk': 0.74; '250': 0.78; '100': 0.79; 'from:addr:mail': 0.83; 'glad': 0.83
Date Fri, 17 Jan 2014 08:53:21 +0000
From Tim Golden <mail@timgolden.me.uk>
User-Agent Mozilla/5.0 (Windows NT 6.1; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.0
MIME-Version 1.0
To python-list@python.org
Subject Re: Converting folders of jpegs to single pdf per folder
References <CAJ3b0o828ZOAYM8Gt0BsLcZ97beGAnQWT9C+_7yFE4HSjiiU3Q@mail.gmail.com> <mailman.5602.1389901256.18130.python-list@python.org> <0c648d2d-d8b3-4848-8b37-1e5e1ae40327@googlegroups.com> <mailman.5604.1389902872.18130.python-list@python.org> <96cfad0d-143f-4084-827f-a67006bf6db2@googlegroups.com>
In-Reply-To <96cfad0d-143f-4084-827f-a67006bf6db2@googlegroups.com>
Content-Type text/plain; charset=ISO-8859-1
Content-Transfer-Encoding 7bit
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.5625.1389948805.18130.python-list@python.org> (permalink)
Lines 20
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1389948805 news.xs4all.nl 2970 [2001:888:2000:d::a6]:57410
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:64144

Show key headers only | View raw


On 17/01/2014 05:42, vasishtha.spier@gmail.com wrote:
> On Thursday, January 16, 2014 12:07:59 PM UTC-8, Tim Golden wrote:
>> 
>> Here's a quick example. This should walk down the Python directory,
>> creating a text file for each directory. The textfile will contain
>> the names of all the files in the directory. (NB this might create
>> a lot of text files so run it inside some temp directory).

[.. snip sample code ...]

> 
> Thanks Tim.  It worked like a charm and saved me weeks of work using
> a drag and drop utility. About 250 pdf files created of 50 to 100
> pages each.  Heres the code in case any one else can use it. [snip]

Glad it was helpful. And thanks for coming back with the solution:
hopefully future searchers will find it useful. (And it's a great advert
for how easy it is to do useful things in just a few lines of Python).

TJG

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Re: Converting folders of jpegs to single pdf per folder Tim Golden <mail@timgolden.me.uk> - 2014-01-16 19:41 +0000
  Re: Converting folders of jpegs to single pdf per folder vasishtha.spier@gmail.com - 2014-01-16 11:50 -0800
    Re: Converting folders of jpegs to single pdf per folder Mark Lawrence <breamoreboy@yahoo.co.uk> - 2014-01-16 20:01 +0000
    Re: Converting folders of jpegs to single pdf per folder Tim Golden <mail@timgolden.me.uk> - 2014-01-16 20:07 +0000
      Re: Converting folders of jpegs to single pdf per folder vasishtha.spier@gmail.com - 2014-01-16 21:42 -0800
        Re: Converting folders of jpegs to single pdf per folder Tim Golden <mail@timgolden.me.uk> - 2014-01-17 08:53 +0000
        Re: Converting folders of jpegs to single pdf per folder Tim Golden <mail@timgolden.me.uk> - 2014-01-17 09:01 +0000
    Re: Converting folders of jpegs to single pdf per folder Tim Golden <mail@timgolden.me.uk> - 2014-01-16 20:12 +0000
      Re: Converting folders of jpegs to single pdf per folder vasishtha.spier@gmail.com - 2014-01-16 12:20 -0800

csiph-web