Compare commits
2 Commits
c3df316aa4
...
e421bd1de9
Author | SHA1 | Date | |
---|---|---|---|
e421bd1de9 | |||
132096b427 |
5
bot.py
5
bot.py
@ -4,8 +4,8 @@ from discord.utils import setup_logging
|
||||
import argparse
|
||||
import discord
|
||||
import logging
|
||||
import os
|
||||
import re
|
||||
import shutil
|
||||
import subprocess as sp
|
||||
|
||||
discord.utils.setup_logging()
|
||||
@ -32,7 +32,8 @@ def _update_db():
|
||||
for line in f:
|
||||
games.append(line.strip())
|
||||
sp.run(["./index.py", "-o", _DB] + games)
|
||||
os.rename(_DB, _DB_DEST)
|
||||
shutil.move(_DB, _DB_DEST)
|
||||
_log.info("updated db")
|
||||
except:
|
||||
_log.exception(f"failed updating db")
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user