Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>tags/v26.0.0beta1
@@ -54,7 +54,7 @@ jobs: | |||
steps: | |||
- name: Checkout ${{ needs.init.outputs.head_ref }} | |||
uses: actions/checkout@v2 | |||
uses: actions/checkout@v3 | |||
with: | |||
token: ${{ secrets.COMMAND_BOT_PAT }} | |||
fetch-depth: 0 |
@@ -21,14 +21,14 @@ jobs: | |||
# do not stop on another job's failure | |||
fail-fast: false | |||
matrix: | |||
php-versions: ['7.4', '8.0'] | |||
php-versions: ['8.0'] | |||
ftpd: ['proftpd', 'vsftpd', 'pure-ftpd'] | |||
name: php${{ matrix.php-versions }}-${{ matrix.ftpd }} | |||
steps: | |||
- name: Checkout server | |||
uses: actions/checkout@v2 | |||
uses: actions/checkout@v3 | |||
with: | |||
submodules: true | |||
@@ -20,7 +20,7 @@ jobs: | |||
steps: | |||
- name: Checkout | |||
uses: actions/checkout@v2 | |||
uses: actions/checkout@v3 | |||
- name: Read package.json node and npm engines version | |||
uses: skjnldsv/read-package-engines-version-actions@v1.1 |
@@ -0,0 +1,37 @@ | |||
# This workflow is provided via the organization template repository | |||
# | |||
# https://github.com/nextcloud/.github | |||
# https://docs.github.com/en/actions/learn-github-actions/sharing-workflows-with-your-organization | |||
name: Lint | |||
on: pull_request | |||
permissions: | |||
contents: read | |||
concurrency: | |||
group: lint-php-cs-${{ github.head_ref || github.run_id }} | |||
cancel-in-progress: true | |||
jobs: | |||
lint: | |||
runs-on: ubuntu-latest | |||
name: php-cs | |||
steps: | |||
- name: Checkout | |||
uses: actions/checkout@v3 | |||
- name: Set up php | |||
uses: shivammathur/setup-php@v2 | |||
with: | |||
php-version: "8.0" | |||
coverage: none | |||
- name: Install dependencies | |||
run: composer i | |||
- name: Lint | |||
run: composer run cs:check || ( echo "Please run `composer run cs:fix` to format your code" && exit 1 ) |
@@ -0,0 +1,57 @@ | |||
# This workflow is provided via the organization template repository | |||
# | |||
# https://github.com/nextcloud/.github | |||
# https://docs.github.com/en/actions/learn-github-actions/sharing-workflows-with-your-organization | |||
name: Lint | |||
on: | |||
pull_request: | |||
push: | |||
branches: | |||
- main | |||
- master | |||
- stable* | |||
permissions: | |||
contents: read | |||
concurrency: | |||
group: lint-php-${{ github.head_ref || github.run_id }} | |||
cancel-in-progress: true | |||
jobs: | |||
php-lint: | |||
runs-on: ubuntu-latest | |||
strategy: | |||
matrix: | |||
php-versions: ["8.0", "8.1", "8.2"] | |||
name: php-lint | |||
steps: | |||
- name: Checkout | |||
uses: actions/checkout@v3 | |||
- name: Set up php ${{ matrix.php-versions }} | |||
uses: shivammathur/setup-php@v2 | |||
with: | |||
php-version: ${{ matrix.php-versions }} | |||
coverage: none | |||
- name: Lint | |||
run: composer run lint | |||
summary: | |||
permissions: | |||
contents: none | |||
runs-on: ubuntu-latest | |||
needs: php-lint | |||
if: always() | |||
name: php-lint-summary | |||
steps: | |||
- name: Summary status | |||
run: if ${{ needs.php-lint.result != "success" && needs.php-lint.result != "skipped" }}; then exit 1; fi |
@@ -1,42 +0,0 @@ | |||
name: Lint | |||
on: pull_request | |||
jobs: | |||
php-linters: | |||
runs-on: ubuntu-latest | |||
strategy: | |||
matrix: | |||
php-versions: ['7.4', '8.0', '8.1', '8.2'] | |||
name: php${{ matrix.php-versions }} lint | |||
steps: | |||
- name: Checkout | |||
uses: actions/checkout@master | |||
- name: Set up php${{ matrix.php-versions }} | |||
uses: shivammathur/setup-php@master | |||
with: | |||
php-version: ${{ matrix.php-versions }} | |||
extensions: ctype,curl,dom,fileinfo,gd,intl,json,mbstring,openssl,pdo_sqlite,posix,sqlite,xml,zip | |||
coverage: none | |||
- name: Lint | |||
run: composer run lint | |||
php-cs-fixer: | |||
name: php-cs check | |||
runs-on: ubuntu-latest | |||
steps: | |||
- name: Checkout | |||
uses: actions/checkout@master | |||
- name: Set up php | |||
uses: shivammathur/setup-php@master | |||
with: | |||
php-version: 7.4 | |||
extensions: ctype,curl,dom,fileinfo,gd,intl,json,mbstring,openssl,pdo_sqlite,posix,sqlite,xml,zip | |||
coverage: none | |||
tools: cs2pr | |||
- name: Install dependencies | |||
run: composer i | |||
- name: Run coding standards check | |||
run: | | |||
composer run cs:check -- --format=checkstyle | cs2pr | |||
composer run cs:check || ( echo 'Please run `composer run cs:fix` to format your code' && exit 1 ) | |||
shell: bash |
@@ -16,7 +16,7 @@ jobs: | |||
steps: | |||
- name: Checkout | |||
uses: actions/checkout@v2 | |||
uses: actions/checkout@v3 | |||
- name: Read package.json node and npm engines version | |||
uses: skjnldsv/read-package-engines-version-actions@v1.1 | |||
@@ -31,7 +31,7 @@ jobs: | |||
steps: | |||
- name: Checkout | |||
uses: actions/checkout@v2 | |||
uses: actions/checkout@v3 | |||
- name: Set up node ${{ needs.versions.outputs.nodeVersion }} | |||
uses: actions/setup-node@v2 | |||
@@ -53,7 +53,7 @@ jobs: | |||
steps: | |||
- name: Checkout | |||
uses: actions/checkout@v2 | |||
uses: actions/checkout@v3 | |||
- name: Set up node ${{ needs.versions.outputs.nodeVersion }} | |||
uses: actions/setup-node@v2 | |||
@@ -75,7 +75,7 @@ jobs: | |||
steps: | |||
- name: Checkout | |||
uses: actions/checkout@v2 | |||
uses: actions/checkout@v3 | |||
- name: Set up node ${{ needs.versions.outputs.nodeVersion }} | |||
uses: actions/setup-node@v2 |
@@ -15,7 +15,7 @@ jobs: | |||
strategy: | |||
matrix: | |||
php-versions: [ '7.4', '8.0', '8.1'] | |||
php-versions: ['8.0', '8.1', '8.2'] | |||
services: | |||
oracle: |
@@ -13,7 +13,7 @@ jobs: | |||
runs-on: ubuntu-latest | |||
steps: | |||
- name: Checkout code | |||
uses: actions/checkout@v2 | |||
uses: actions/checkout@v3 | |||
with: | |||
submodules: recursive | |||
- name: Psalm |
@@ -13,7 +13,7 @@ jobs: | |||
runs-on: ubuntu-latest | |||
steps: | |||
- name: Checkout code | |||
uses: actions/checkout@v2 | |||
uses: actions/checkout@v3 | |||
with: | |||
submodules: recursive | |||
- name: Psalm |
@@ -21,7 +21,7 @@ jobs: | |||
# do not stop on another job's failure | |||
fail-fast: false | |||
matrix: | |||
php-versions: ['7.4', '8.0'] | |||
php-versions: ['8.0', '8.1'] | |||
name: php${{ matrix.php-versions }}-minio | |||
@@ -36,7 +36,7 @@ jobs: | |||
steps: | |||
- name: Checkout server | |||
uses: actions/checkout@v2 | |||
uses: actions/checkout@v3 | |||
with: | |||
submodules: true | |||
@@ -70,7 +70,7 @@ jobs: | |||
# do not stop on another job's failure | |||
fail-fast: false | |||
matrix: | |||
php-versions: ['7.4', '8.0'] | |||
php-versions: ['8.0', '8.1'] | |||
name: php${{ matrix.php-versions }}-localstack | |||
@@ -85,7 +85,7 @@ jobs: | |||
steps: | |||
- name: Checkout server | |||
uses: actions/checkout@v2 | |||
uses: actions/checkout@v3 | |||
with: | |||
submodules: true | |||
@@ -30,7 +30,7 @@ jobs: | |||
steps: | |||
- name: Checkout server | |||
uses: actions/checkout@v2 | |||
uses: actions/checkout@v3 | |||
with: | |||
submodules: true | |||
@@ -17,13 +17,13 @@ jobs: | |||
strategy: | |||
fail-fast: false | |||
matrix: | |||
php-versions: ['7.4', '8.0'] | |||
php-versions: ['8.0', '8.1'] | |||
name: php${{ matrix.php-versions }}-${{ matrix.ftpd }} | |||
steps: | |||
- name: Checkout server | |||
uses: actions/checkout@v2 | |||
uses: actions/checkout@v3 | |||
with: | |||
submodules: true | |||
- name: Pull images |
@@ -1,56 +1,61 @@ | |||
name: Static code analysis | |||
on: [pull_request] | |||
on: | |||
pull_request: | |||
jobs: | |||
static-code-analysis: | |||
runs-on: ubuntu-latest | |||
steps: | |||
- uses: actions/checkout@v2 | |||
- name: Checkout submodules | |||
shell: bash | |||
run: | | |||
auth_header="$(git config --local --get http.https://github.com/.extraheader)" | |||
git submodule sync --recursive | |||
git -c "http.extraheader=$auth_header" -c protocol.version=2 submodule update --init --force --recursive --depth=1 | |||
- name: Set up php7.4 | |||
uses: shivammathur/setup-php@master | |||
with: | |||
php-version: 7.4 | |||
extensions: ctype,curl,dom,fileinfo,gd,intl,json,mbstring,openssl,pdo_sqlite,posix,sqlite,xml,zip | |||
coverage: none | |||
- name: Composer install | |||
run: composer i | |||
- name: Psalm | |||
run: composer run psalm -- --monochrome --no-progress --output-format=github --update-baseline || ( git diff -- . ':!lib/composer' && exit 1 ) | |||
- name: Check diff | |||
run: git diff -- . ':!lib/composer' | |||
- name: Show potential changes in Psalm baseline | |||
run: | | |||
bash -c "[[ ! \"`git status --porcelain build/psalm-baseline.xml`\" ]] || ( echo 'Uncommited changes in Psalm baseline' && git status && git diff build/psalm-baseline.xml)" | |||
static-code-analysis-ocp: | |||
runs-on: ubuntu-latest | |||
steps: | |||
- uses: actions/checkout@v2 | |||
- name: Checkout submodules | |||
shell: bash | |||
run: | | |||
auth_header="$(git config --local --get http.https://github.com/.extraheader)" | |||
git submodule sync --recursive | |||
git -c "http.extraheader=$auth_header" -c protocol.version=2 submodule update --init --force --recursive --depth=1 | |||
- name: Set up php7.4 | |||
uses: shivammathur/setup-php@master | |||
with: | |||
php-version: 7.4 | |||
extensions: ctype,curl,dom,fileinfo,gd,intl,json,mbstring,openssl,pdo_sqlite,posix,sqlite,xml,zip | |||
coverage: none | |||
- name: Composer install | |||
run: composer i | |||
- name: Psalm | |||
run: composer run psalm -- -c psalm-ocp.xml --monochrome --no-progress --output-format=github --update-baseline || ( git diff -- . ':!lib/composer' && exit 1 ) | |||
- name: Check diff | |||
run: git diff -- . ':!lib/composer' | |||
- name: Show potential changes in Psalm baseline | |||
run: | | |||
bash -c "[[ ! \"`git status --porcelain build/psalm-baseline-ocp.xml`\" ]] || ( echo 'Uncommited changes in Psalm baseline' && git status && git diff build/psalm-baseline.xml)" | |||
static-code-analysis: | |||
runs-on: ubuntu-latest | |||
steps: | |||
- name: Checkout | |||
uses: actions/checkout@v3 | |||
with: | |||
submodules: true | |||
- name: Set up php | |||
uses: shivammathur/setup-php@v2 | |||
with: | |||
php-version: '8.0' | |||
extensions: ctype,curl,dom,fileinfo,gd,intl,json,mbstring,openssl,pdo_sqlite,posix,sqlite,xml,zip | |||
coverage: none | |||
- name: Composer install | |||
run: composer i | |||
- name: Psalm | |||
run: composer run psalm -- --monochrome --no-progress --output-format=github --update-baseline || ( git diff -- . ':!lib/composer' && exit 1 ) | |||
- name: Check diff | |||
run: git diff -- . ':!lib/composer' | |||
- name: Show potential changes in Psalm baseline | |||
run: | | |||
bash -c "[[ ! \"`git status --porcelain build/psalm-baseline.xml`\" ]] || ( echo 'Uncommited changes in Psalm baseline' && git status && git diff build/psalm-baseline.xml)" | |||
static-code-analysis-ocp: | |||
runs-on: ubuntu-latest | |||
steps: | |||
- name: Checkout | |||
uses: actions/checkout@v3 | |||
with: | |||
submodules: true | |||
- name: Set up php | |||
uses: shivammathur/setup-php@v2 | |||
with: | |||
php-version: '8.0' | |||
extensions: ctype,curl,dom,fileinfo,gd,intl,json,mbstring,openssl,pdo_sqlite,posix,sqlite,xml,zip | |||
coverage: none | |||
- name: Composer install | |||
run: composer i | |||
- name: Psalm | |||
run: composer run psalm -- -c psalm-ocp.xml --monochrome --no-progress --output-format=github --update-baseline || ( git diff -- . ':!lib/composer' && exit 1 ) | |||
- name: Check diff | |||
run: git diff -- . ':!lib/composer' | |||
- name: Show potential changes in Psalm baseline | |||
run: | | |||
bash -c "[[ ! \"`git status --porcelain build/psalm-baseline-ocp.xml`\" ]] || ( echo 'Uncommited changes in Psalm baseline' && git status && git diff build/psalm-baseline.xml)" |
@@ -22,10 +22,10 @@ jobs: | |||
ref: ${{ matrix.branches }} | |||
submodules: true | |||
- name: Set up php7.4 | |||
- name: Set up php | |||
uses: shivammathur/setup-php@v2 | |||
with: | |||
php-version: 7.4 | |||
php-version: '8.0' | |||
extensions: ctype,curl,dom,fileinfo,gd,intl,json,mbstring,openssl,pdo_sqlite,posix,sqlite,xml,zip | |||
coverage: none | |||