replaced response json
This commit is contained in:
parent
8036dc33b3
commit
2162cf78cd
4
generate
4
generate
@ -4,7 +4,7 @@ from pathlib import Path
|
|||||||
import json
|
import json
|
||||||
|
|
||||||
|
|
||||||
CARGO_MOMMY_DATA = "https://raw.githubusercontent.com/diamondburned/go-mommy/refs/heads/main/responses.json"
|
CARGO_MOMMY_DATA = "https://raw.githubusercontent.com/Gankra/cargo-mommy/refs/heads/main/responses.json"
|
||||||
MODULE_PATH = Path("python_mommy_venv")
|
MODULE_PATH = Path("python_mommy_venv")
|
||||||
|
|
||||||
|
|
||||||
@ -14,7 +14,7 @@ if __name__ == "__main__":
|
|||||||
res = requests.get(CARGO_MOMMY_DATA)
|
res = requests.get(CARGO_MOMMY_DATA)
|
||||||
if not res.ok:
|
if not res.ok:
|
||||||
raise Exception(f"couldn't fetch {CARGO_MOMMY_DATA} ({res.status_code})")
|
raise Exception(f"couldn't fetch {CARGO_MOMMY_DATA} ({res.status_code})")
|
||||||
|
|
||||||
print(f"writing {Path(MODULE_PATH, 'responses.json')}")
|
print(f"writing {Path(MODULE_PATH, 'responses.json')}")
|
||||||
with Path(MODULE_PATH, "responses.json").open("w") as f:
|
with Path(MODULE_PATH, "responses.json").open("w") as f:
|
||||||
json.dump(res.json(), f, indent=4)
|
json.dump(res.json(), f, indent=4)
|
||||||
|
@ -14,7 +14,7 @@ serious_logger = logging.getLogger("serious")
|
|||||||
|
|
||||||
PREFIX = "MOMMY"
|
PREFIX = "MOMMY"
|
||||||
|
|
||||||
RESPONSES_URL = "https://raw.githubusercontent.com/diamondburned/go-mommy/refs/heads/main/responses.json"
|
RESPONSES_URL = "https://raw.githubusercontent.com/Gankra/cargo-mommy/refs/heads/main/responses.json"
|
||||||
RESPONSES_FILE = Path(__file__).parent / "responses.json"
|
RESPONSES_FILE = Path(__file__).parent / "responses.json"
|
||||||
ADDITIONAL_ENV_VARS = {
|
ADDITIONAL_ENV_VARS = {
|
||||||
"pronoun": "PRONOUNS",
|
"pronoun": "PRONOUNS",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user