readme: compatibility with Github
This commit is contained in:
parent
8730db6b49
commit
e21efb3c3c
1 changed files with 2 additions and 0 deletions
|
@ -73,6 +73,8 @@ steps:
|
||||||
- name: Simple checkout
|
- name: Simple checkout
|
||||||
run: |
|
run: |
|
||||||
git init
|
git init
|
||||||
|
# On Github, the token isn't readily available.
|
||||||
|
test -z "$GITHUB_TOKEN" && GITHUB_TOKEN="${{ github.token }}"
|
||||||
MY_AUTHENTICATED_URL="$( echo "$GITHUB_SERVER_URL" | sed "s#^\(https\?://\)#\1$GITHUB_TOKEN\@#" )"
|
MY_AUTHENTICATED_URL="$( echo "$GITHUB_SERVER_URL" | sed "s#^\(https\?://\)#\1$GITHUB_TOKEN\@#" )"
|
||||||
git remote add origin "$MY_AUTHENTICATED_URL"/"$GITHUB_REPOSITORY"
|
git remote add origin "$MY_AUTHENTICATED_URL"/"$GITHUB_REPOSITORY"
|
||||||
# Little and optional speed optimization
|
# Little and optional speed optimization
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue