添加git代理
This commit is contained in:
parent
fa6d686acf
commit
aaec3e0b21
@ -18,6 +18,15 @@ jobs:
|
|||||||
runs-on: ubuntu-22.04
|
runs-on: ubuntu-22.04
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
|
- name: 设置 Git 代理
|
||||||
|
run: |
|
||||||
|
if [ -n "${{ env.GIT_PROXY }}" ]; then
|
||||||
|
echo "配置 Git 代理: ${{ env.GIT_PROXY }}"
|
||||||
|
git config --global http.proxy ${{ env.GIT_PROXY }}
|
||||||
|
git config --global https.proxy ${{ env.GIT_PROXY }}
|
||||||
|
else
|
||||||
|
echo "未设置 GIT_PROXY 环境变量,跳过代理配置"
|
||||||
|
fi
|
||||||
- name: 检出代码
|
- name: 检出代码
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user