From e3b3c2853e13704fa3ab8a1abf76ef9838eabfe9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?geoh=C3=A4r=C3=B6?= Date: Mon, 30 Jan 2017 12:09:17 +0200 Subject: [PATCH] . MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Lisätty pvm kml-tiedoston nimeen. --- Kuntarajat.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Kuntarajat.py b/Kuntarajat.py index 69a419c..c232155 100644 --- a/Kuntarajat.py +++ b/Kuntarajat.py @@ -1,6 +1,6 @@ #!/usr/bin/python # -*- coding: UTF-8 -*- -import os, sys +import os, sys, datetime rawgeocachefi = """[LIITÄ LÖYTÖTAULUKKO PAIKKAKUNNITTAIN TÄHÄN]""" @@ -39877,7 +39877,9 @@ while k <= int(kuntia): k = k + 1 -with open("Kuntarajat.kml", "w") as f: +now = datetime.datetime.now() +tiedosto = "Kuntarajat" + now.strftime("%d%m%Y") + ".kml" +with open(tiedosto, "w") as f: f.write(kuntarajat) print(kuntarajat) print('VALMIS') \ No newline at end of file