Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!us.feeder.erje.net!newsfeed.fsmpi.rwth-aachen.de!newsfeed.kamp.net!newsfeed.kamp.net!newsfeed.freenet.ag!news2.euro.net!newsgate.cistron.nl!newsgate.news.xs4all.nl!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.021 X-Spam-Evidence: '*H*': 0.96; '*S*': 0.00; 'subject:not': 0.03; 'subject:file': 0.07; 'better?': 0.16; 'chris,': 0.16; 'executed,': 0.16; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'subject:txt': 0.16; 'sat,': 0.16; 'wrote:': 0.18; 'command': 0.22; 'shell': 0.22; 'header:In-Reply-To:1': 0.27; 'am,': 0.29; 'message-id:@mail.gmail.com': 0.30; '25,': 0.31; 'probably': 0.32; 'received:google.com': 0.35; 'version': 0.36; "didn't": 0.36; 'should': 0.36; 'being': 0.38; 'subject:new': 0.38; 'to:addr:python-list': 0.38; 'does': 0.39; 'to:addr:python.org': 0.39; 'changed': 0.39; 'how': 0.40; 'useful.': 0.68; 'subject:add': 0.91; '2013': 0.98 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=X39v2z26F66O6MQJ4PhJQTYX1pokPaPKJHOjmQRk9Y4=; b=ox2yQbxpScjgXYuoYLnUVgM9BuDBsGF5Tw7VyuIdcT2LQuyhIefBRl0RUr+L+1N8vq izfldRzaRsxe+FunviPgbUKgV5aQJ3xUZW7rrdHSvGSEliiZMi6NRX8tFlZQ29A6lCVd 0nhDPqd4ZV+aeAH6dJi2CMdh6InpYmeghq97+T4rhC7sBVTrKkIZ6jxHJO//+oOkRcp0 jcDrr96WxD2U+rmyuQhX9vnCnMr7Fo0FScK5Z4DxPzBDbXXaMn3W4sYorolJbXbsJtMJ V4qUJQ5nl9TBaUhyImkV9bq0/ilelxN4TTlnfF7d+uQ6q5RidlWQrbTgHoQStChNasDP u+Ww== MIME-Version: 1.0 X-Received: by 10.52.164.163 with SMTP id yr3mr7703718vdb.76.1369414607847; Fri, 24 May 2013 09:56:47 -0700 (PDT) In-Reply-To: References: Date: Sat, 25 May 2013 02:56:47 +1000 Subject: Re: Read txt file, add to iptables not working on new host 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.15 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: 10 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1369414617 news.xs4all.nl 15900 [2001:888:2000:d::a6]:58486 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:45902 On Sat, May 25, 2013 at 2:32 AM, JackM wrote: > So Chris, does this version look better? Changed to inFile to with. > Heh, I didn't know you knew about with :) Since you know how to use it, you probably also know why it's useful. Anyway, the main thing is to see the exact command that's being executed, which you then should be able to try at a shell prompt. ChrisA