Update deploy.yml
This commit is contained in:
parent
c5e09243fa
commit
c391e91149
1 changed files with 3 additions and 3 deletions
6
.github/workflows/deploy.yml
vendored
6
.github/workflows/deploy.yml
vendored
|
|
@ -18,21 +18,21 @@ jobs:
|
||||||
else
|
else
|
||||||
echo "Unsupported branch"
|
echo "Unsupported branch"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
|
||||||
|
|
||||||
- name: Update bot files
|
- name: Update bot files
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # token automatique fourni par GitHub
|
||||||
run: |
|
run: |
|
||||||
git config --global --add safe.directory $DEPLOY_PATH
|
git config --global --add safe.directory $DEPLOY_PATH
|
||||||
cd $DEPLOY_PATH
|
cd $DEPLOY_PATH
|
||||||
if [ ! -d ".git" ]; then
|
if [ ! -d ".git" ]; then
|
||||||
git init
|
git init
|
||||||
git remote add origin https://github.com/ArcElewyn/Discord.git
|
git remote add origin https://x-access-token:$GITHUB_TOKEN@github.com/ArcElewyn/Discord.git
|
||||||
git fetch origin $GITHUB_REF_NAME
|
git fetch origin $GITHUB_REF_NAME
|
||||||
git reset --hard origin/$GITHUB_REF_NAME
|
git reset --hard origin/$GITHUB_REF_NAME
|
||||||
else
|
else
|
||||||
git fetch origin $GITHUB_REF_NAME
|
git fetch origin $GITHUB_REF_NAME
|
||||||
git reset --hard origin/$GITHUB_REF_NAME
|
git reset --hard origin/$GITHUB_REF_NAME
|
||||||
fi
|
|
||||||
|
|
||||||
- name: Restart bot
|
- name: Restart bot
|
||||||
run: |
|
run: |
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue