misc fixes

master
trémeur 3 days ago
parent bb33cc084d
commit 409d6c4893

@ -131,7 +131,7 @@ def indexgen():
else:
rank = "red"
rankcode = re.sub(" ","",rank)
content.write("<a href=\"/levels\"><img src=\"/assets/levels/" + rankcode + ".gif\"></a>" + tcgcore.printcard("sig_" + variables.name.lower()) + "\n<ul>\n<li>player name: <span class=\"name\">" + variables.name + "</span></li>\n<li>" + str(len(tcgcore.ownedcards())) + " cards held <span class=\"rank " + rank + "\">(" + rank + ")</span></li>\n<li>started <code>" + firstdate.strftime("%Y-%m-%d") + "</code></li>\n<li>last updated <code>" + datetime.datetime.today().strftime("%Y-%m-%d") + "</code></li>\n<li><a href=\"https://git.praze.net/tre/tcg\">code</a> under construction</li>\n</ul>\n")
content.write("<a href=\"/levels\"><img src=\"/assets/levels/" + rankcode + ".gif\"></a>" + tcgcore.printcard("sig_" + variables.name.lower()) + "\n<ul>\n<li>player name: <span class=\"name\">" + variables.name + "</span></li>\n<li>" + str(len(tcgcore.ownedcards())) + " cards held <span class=\"rank " + rank + "\">(" + rank + ")</span></li>\n<li>started <code>" + firstdate.strftime("%Y-%m-%d") + "</code></li>\n<li>last updated <code>" + datetime.datetime.today().strftime("%Y-%m-%d") + "</code></li>\n<li><a href=\"https://git.praze.net/tre/tcg\" target=\"_blank\">code</a> under construction</li>\n</ul>\n")
crayred = 0
crayorange = 0
crayyellow = 0

@ -62,7 +62,11 @@ def massseriesgen(series,massindex):
content.write("<h1>" + series + "</h1>\n<p><a href=\"/mass\">back to mass decks page</a></p>\n<p>")
themassdecks = []
for card in massowned[series]:
themassdecks.append(card[:-2])
try:
if card[:-2] in variables.masscollect[series]["decks"]:
themassdecks.append(card[:-2])
except:
pass
themassdecks = sorted(list(dict.fromkeys(themassdecks)))
massmastered = []
for deck in themassdecks:

@ -1,7 +1,7 @@
import variables
buildscript = open("build.sh","w")
buildscript.write("#!/usr/bin/env bash\n\npython3 generate.py\n\nrclone copy build " + variables.servername + ":" + variables.serverpath + " -P")
buildscript.write("#!/usr/bin/env bash\n\npython3 generate.py\n\nrclone copy build " + variables.servername + ":" + variables.serverpath + " -P -L")
buildscript.close()
if not os.path.exists("build/user.css"):

Loading…
Cancel
Save