fix: use manual git checkout and conditional package managers for Gitea compatibility
Some checks failed
Syntax Check / syntax-check (push) Failing after 2s
Some checks failed
Syntax Check / syntax-check (push) Failing after 2s
This commit is contained in:
@@ -14,14 +14,21 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
syntax-check:
|
syntax-check:
|
||||||
runs-on: ubuntu-latest
|
runs-on: linux,x86_64,docker
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout code
|
- name: Checkout code
|
||||||
uses: actions/checkout@v3
|
run: |
|
||||||
|
git clone --depth 1 "$(echo "${{ gitea.server_url }}" | sed "s|://|://oauth2:${{ gitea.token }}@|")/${{ gitea.repository }}.git" .
|
||||||
|
git checkout -q ${{ github.sha }}
|
||||||
|
|
||||||
- name: Install ShellCheck
|
- name: Install ShellCheck
|
||||||
run: apt-get update && apt-get install -y shellcheck
|
run: |
|
||||||
|
if command -v apk >/dev/null 2>&1; then
|
||||||
|
apk add --no-cache shellcheck
|
||||||
|
elif command -v apt-get >/dev/null 2>&1; then
|
||||||
|
apt-get update && apt-get install -y shellcheck
|
||||||
|
fi
|
||||||
|
|
||||||
- name: Check bash script syntax
|
- name: Check bash script syntax
|
||||||
run: |
|
run: |
|
||||||
@@ -30,7 +37,12 @@ jobs:
|
|||||||
shellcheck example-trigger/deploy.sh
|
shellcheck example-trigger/deploy.sh
|
||||||
|
|
||||||
- name: Install PHP
|
- name: Install PHP
|
||||||
run: apt-get install -y php-cli
|
run: |
|
||||||
|
if command -v apk >/dev/null 2>&1; then
|
||||||
|
apk add --no-cache php
|
||||||
|
elif command -v apt-get >/dev/null 2>&1; then
|
||||||
|
apt-get install -y php-cli
|
||||||
|
fi
|
||||||
|
|
||||||
- name: Check PHP syntax
|
- name: Check PHP syntax
|
||||||
run: |
|
run: |
|
||||||
|
|||||||
Reference in New Issue
Block a user