From fcfc87603db530faf4b18f70953daa14fff0ae5d Mon Sep 17 00:00:00 2001 From: vapao Date: Tue, 9 Jun 2020 11:16:32 +0800 Subject: [PATCH] =?UTF-8?q?A=20=E6=96=B0=E5=A2=9E=E5=8F=91=E5=B8=83?= =?UTF-8?q?=E5=85=A8=E5=B1=80=E5=8F=98=E9=87=8FSPUG=5FGIT=5FBRANCH/SPUG=5F?= =?UTF-8?q?GIT=5FTAG/SPUG=5FGIT=5FCOMMIT=5FID?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- spug_api/apps/deploy/utils.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/spug_api/apps/deploy/utils.py b/spug_api/apps/deploy/utils.py index 0fc75c6..fb3f6aa 100644 --- a/spug_api/apps/deploy/utils.py +++ b/spug_api/apps/deploy/utils.py @@ -56,10 +56,10 @@ def _ext1_deploy(req, helper, env): extras = json.loads(req.extra) if extras[0] == 'branch': tree_ish = extras[2] - env.update(SPUG_BRANCH=extras[1], SPUG_COMMIT_ID=extras[2]) + env.update(SPUG_GIT_BRANCH=extras[1], SPUG_GIT_COMMIT_ID=extras[2]) else: tree_ish = extras[1] - env.update(SPUG_TAG=extras[1]) + env.update(SPUG_GIT_TAG=extras[1]) if req.type == '2': helper.send_step('local', 6, f'完成\r\n{human_time()} 回滚发布... 跳过') else: @@ -291,7 +291,7 @@ class Helper: def local(self, command, env=None): if env: - env = os.environ.copy().update(env) + env.update(os.environ) command = 'set -e\n' + command task = subprocess.Popen(command, env=env, shell=True, stdout=subprocess.PIPE, stderr=subprocess.STDOUT) while True: