feat: write account details to json file as part of create_access_token

This commit is contained in:
Aravinth Manivannan 2023-09-18 19:05:13 +05:30
parent 3801772cd1
commit b2d1e1cfd0
Signed by: realaravinth
GPG Key ID: F8F50389936984FF
1 changed files with 2 additions and 0 deletions

View File

@ -294,6 +294,8 @@ class Forgejo:
print("Created access token")
data = resp.json()
with open(file, "w") as f:
data["login"] = self.username
data["email"] = self.email
content = json.dumps(data)
f.write(content)
print(f"Wrote access token to {file}")