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


Groups > comp.lang.python > #102747

Re: [SOLVED] There has to be a better way to split this string!

Path csiph.com!fu-berlin.de!uni-berlin.de!not-for-mail
From Ben Finney <ben+python@benfinney.id.au>
Newsgroups comp.lang.python
Subject Re: [SOLVED] There has to be a better way to split this string!
Date Wed, 10 Feb 2016 12:47:16 +1100
Lines 17
Message-ID <mailman.11.1455068845.7749.python-list@python.org> (permalink)
References <56BA91B5.5090400@cajuntechie.org> <56BA9505.40900@cajuntechie.org>
Mime-Version 1.0
Content-Type text/plain; charset=utf-8
Content-Transfer-Encoding 8bit
X-Trace news.uni-berlin.de r9cYQ//NFA0JtDPSc3rW6Q9UZpvT7swl3lnG8bwomVYA==
Cancel-Lock sha1:1l2zsm4uvvJCPAt0Ikwb9hgqzSI=
Return-Path <python-python-list@m.gmane.org>
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; 'subject:: [': 0.03; 'filename,': 0.09; 'filename.': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'subject:string': 0.09; 'received:80.91.229.3': 0.16; 'received:io': 0.16; 'received:plane.gmane.org': 0.16; 'received:psf.io': 0.16; 'subject:There': 0.16; 'wrote:': 0.16; 'subject:] ': 0.19; 'module': 0.25; 'header:User-Agent:1': 0.26; 'header:X-Complaints- To:1': 0.26; 'task': 0.30; 'library.': 0.35; 'should': 0.36; 'to:addr:python-list': 0.36; 'pm,': 0.36; 'received:org': 0.37; 'version': 0.38; 'to:addr:python.org': 0.40; 'making': 0.62; 'god': 0.67; 'skip:\xe2 10': 0.70; '8bit%:43': 0.72; '_o__)': 0.84; 'received:125': 0.84; 'subject:this': 0.85; 'fellows,': 0.91
X-Injected-Via-Gmane http://gmane.org/
X-Gmane-NNTP-Posting-Host jigong.madmonks.org
X-Public-Key-ID 0xAC128405
X-Public-Key-Fingerprint 517C F14B B2F3 98B0 CB35 4855 B8B2 4C06 AC12 8405
X-Public-Key-URL http://www.benfinney.id.au/contact/bfinney-pubkey.asc
X-Post-From Ben Finney <bignose+hates-spam@benfinney.id.au>
User-Agent Gnus/5.13 (Gnus v5.13) Emacs/24.4 (gnu/linux)
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.21rc2
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>
Xref csiph.com comp.lang.python:102747

Show key headers only | View raw


Anthony Papillion <anthony@cajuntechie.org> writes:

> On 02/09/2016 07:26 PM, Anthony Papillion wrote:
> > I am using datetime.now() to create a unique version of a filename.
> > […]
>
> Found the solution in strftime(). Exactly what I was looking for.

For the task of making a unique filename, you should also consider the
‘tempfile’ module in the standard library.

-- 
 \       “I distrust those people who know so well what God wants them |
  `\    to do to their fellows, because it always coincides with their |
_o__)                      own desires.” —Susan Brownell Anthony, 1896 |
Ben Finney

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


Thread

Re: [SOLVED] There has to be a better way to split this string! Ben Finney <ben+python@benfinney.id.au> - 2016-02-10 12:47 +1100

csiph-web