From 6280babe1b27e4e0ea4613c9afd533993181effa Mon Sep 17 00:00:00 2001 From: Daira Hopwood Date: Thu, 2 Nov 2017 05:59:41 +0000 Subject: [PATCH] Change the directory in which the Pocklington proof files are created. Signed-off-by: Daira Hopwood --- verify.sage | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/verify.sage b/verify.sage index 96caf5e..1717c0b 100644 --- a/verify.sage +++ b/verify.sage @@ -45,6 +45,10 @@ def requirement(fn,istrue): return istrue def verify(): + try: + os.mkdir('proof') + except OSError as e: + if e.errno != EEXIST: raise try: s = set(map(Integer, readfile('primes').split())) @@ -115,7 +119,7 @@ def verify_primes(V, s, needtofactor): proof += '

(%s)^2 > n.\n' % f proof += "

n is prime by Pocklington's theorem.\n" proof += '\n' - writefile('../../../proof/%s.html' % n,proof) + writefile('proof/%s.html' % n,proof) V.add(n) break