From 0c5d90c12bd87bd5e6b9fc693c8384ed5884221e Mon Sep 17 00:00:00 2001 From: admin Date: Mon, 8 Dec 2025 18:00:31 +0800 Subject: [PATCH] Initial commit --- create_repo.py | 9 ++++++--- wechat-mini-program/app.wxss | 1 - 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/create_repo.py b/create_repo.py index ae7dd4e..78e2a0c 100644 --- a/create_repo.py +++ b/create_repo.py @@ -44,7 +44,6 @@ __pycache__/ .vscode/ .idea/ *.log -.env """ with open(".gitignore", "w") as f: f.write(content.strip()) @@ -55,9 +54,13 @@ __pycache__/ def main(): clone_url = None + # Initialize session and disable proxy + session = requests.Session() + session.trust_env = False + # 1. Create Repository via API try: - response = requests.post(API_URL, auth=AUTH, json=REPO_DATA) + response = session.post(API_URL, auth=AUTH, json=REPO_DATA) if response.status_code == 201: print("Repository created successfully") clone_url = response.json()['clone_url'] @@ -67,7 +70,7 @@ def main(): user = AUTH[0] repo_name = REPO_DATA["name"] get_url = f"https://git.aitosuv.com/api/v1/repos/{user}/{repo_name}" - resp_get = requests.get(get_url, auth=AUTH) + resp_get = session.get(get_url, auth=AUTH) if resp_get.status_code == 200: clone_url = resp_get.json()['clone_url'] else: diff --git a/wechat-mini-program/app.wxss b/wechat-mini-program/app.wxss index 3d1b8dc..bb16fab 100644 --- a/wechat-mini-program/app.wxss +++ b/wechat-mini-program/app.wxss @@ -42,4 +42,3 @@ page { flex-direction: column; box-sizing: border-box; } -