Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!news.albasani.net!news2.arglkargh.de!news.wiretrip.org!newsfeed.xs4all.nl!newsfeed5.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.009 X-Spam-Evidence: '*H*': 0.98; '*S*': 0.00; 'operations.': 0.05; 'scripting': 0.05; 'python': 0.07; 'template.': 0.09; 'am,': 0.14; 'wrote:': 0.14; 'alternative,': 0.16; 'hartley': 0.16; 'incidental': 0.16; 'subject:create': 0.16; 'jonathan': 0.19; 'shell': 0.19; 'template': 0.20; 'performing': 0.22; 'header:In- Reply-To:1': 0.22; 'file,': 0.22; 'thu,': 0.22; 'received:209.85.214.174': 0.23; 'received:mail- iw0-f174.google.com': 0.23; 'creating': 0.26; 'script': 0.26; "i'm": 0.26; 'chris': 0.27; 'message-id:@mail.gmail.com': 0.28; 'url:)': 0.29; 'called': 0.32; 'to:addr:python-list': 0.32; 'project': 0.32; 'creates': 0.33; 'some': 0.37; 'received:209.85': 0.37; 'convenient': 0.38; 'received:google.com': 0.38; 'but': 0.38; 'files': 0.38; 'url:org': 0.38; 'received:209.85.214': 0.39; 'to:addr:python.org': 0.39; 'received:209': 0.39; 'how': 0.39; 'header:Received:5': 0.40; 'contained': 0.40; 'might': 0.40; 'goals': 0.60; 'simple': 0.60; 'central': 0.60; '2011': 0.62; 'benefit': 0.66; 'lightweight': 0.84 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:content-type; bh=vR26hYRAG7Z5iJXWNb4lYlOgbyWV5yUV/Kb/sfvbkTs=; b=D8TnF24MktpooIo0B6UI2yQcsQ7cBeeg0wmOu0HSDWQrUsdIBHZ+S64tQuFxvtpiIP WUUEHWARrOyD9afotx8xirojECxNYv1eod01HF82ov1YiBL+Vx77bznyAVouaRQiv4E9 Q7G0sVT//ETaRr6tcJ4YS9hgMHAasSduQAnWE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=sgsNGYOq6tD/Cm8cK5vGYANUszCXLmcdJdkqVbAkrtv9CMWD0dwLcDSUGfK6u/Rzl1 mh/SL19qyZStIcqnR877RaQdYa7hxyDVCeTHvphJghw7MC5/Kz4zNwflD/kK8OQoZSA9 m5ZsdOc7Mjy5vxLiytXcmaxjYL2mXMDWYffhM= MIME-Version: 1.0 In-Reply-To: <4DCAD6B8.3070003@tartley.com> References: <4DCAD6B8.3070003@tartley.com> Date: Thu, 12 May 2011 14:00:08 +1000 Subject: Re: lightweight way to create new projects from templates From: Chris Angelico To: python-list@python.org Content-Type: text/plain; charset=ISO-8859-1 X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 22 NNTP-Posting-Host: 82.94.164.166 X-Trace: 1305172812 news.xs4all.nl 81485 [::ffff:82.94.164.166]:42412 X-Complaints-To: abuse@xs4all.nl Xref: x330-a1.tempe.blueboxinc.net comp.lang.python:5192 On Thu, May 12, 2011 at 4:34 AM, Jonathan Hartley wrote: > Hi. > > I'm looking for a quick way to create new Python projects from a template. > > I understand that 'Paste' (http://pythonpaste.org/) is one way to do this, > but I find Paste very intimidating because of all the functionality it > includes. I'm not even sure whether 'creating new projects from templates' > is the central goal of Paste, or just an incidental benefit that it provides > while performing some other task. > > As a lightweight alternative, I'm creating a project called 'Genesis'. > Functionally, it will be little more than a 'cp -r' followed by a few search > and replace operations. Depending on how simple your goals are, it might be possible to do it with a simple shell or Python script that creates multiple files and/or directories. That way, your template is all contained in a single file, which is convenient for distribution and such; and the scripting facilities can handle the search and replace operations. Chris Angelico