Skip to content

Commit

Permalink
Code should write everything in root directory.
Browse files Browse the repository at this point in the history
  • Loading branch information
amtoine committed Aug 20, 2021
1 parent ea789d6 commit 9cd469f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/score.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
def main():
# read the stashed scores.
print("reading scores", end="... ")
with open(".scores.csv", 'r') as file:
with open(os.path.join(_root, ".scores.csv"), 'r') as file:
lines = file.readlines()
# score have following format: '<score>;<date>;<username>'.
data = list(map(lambda s: tuple(s.strip().split(';')), lines))
Expand All @@ -24,7 +24,7 @@ def main():

# read the token to connect the bot.
print("reading token", end="... ")
with open(".token.txt", 'r') as token_file:
with open(os.path.join(_root, ".token.txt"), 'r') as token_file:
token = token_file.readline()

# run the bot.
Expand Down

0 comments on commit 9cd469f

Please sign in to comment.