Write secrets from CI environment

This commit is contained in:
Manuel Cortez 2021-10-30 01:34:37 -05:00
parent 0e2ff4de8a
commit 5a6dc23524
No known key found for this signature in database
GPG Key ID: 262CC30FA01B5CBF

View File

@ -28,9 +28,11 @@ file2 = open("..\\scripts\\twblue.nsi", "w", encoding="utf-8")
file2.write(contents)
file2.close()
print("done")
print("Writing keys to module...")
file3 = open("appkeys.py", "w")
keys = """twitter_api_key = {}
twitter_api_secret = {}
keys = """twitter_api_key = "{}"
twitter_api_secret = "{}"
""".format(os.environ.get("TWITTER_API_KEY"), os.environ.get("TWITTER_API_SECRET"))
file3.write(keys)
file3.close()
print("Wrote set of keys for consumer of {}".format(os.environ.get("TWITTER_API_KEY")))