From ca21eb8871e2bffa6a29e297cf2fc67fe5e84c93 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Sat, 18 Nov 2023 19:39:19 +0100 Subject: [PATCH 01/10] Debug approve action Signed-off-by: Joas Schilling --- .github/workflows/appstore-build-publish.yml | 167 ---------------- .github/workflows/command-rebase.yml | 51 ----- .../workflows/dependabot-approve-merge.yml | 20 +- .github/workflows/fixup.yml | 33 ---- .github/workflows/integration-mysql.yml | 164 ---------------- .github/workflows/integration-oci.yml | 176 ----------------- .github/workflows/integration-pgsql.yml | 171 ----------------- .github/workflows/integration-sqlite.yml | 155 --------------- .github/workflows/jest.yml | 45 ----- .github/workflows/lint-eslint.yml | 94 --------- .github/workflows/lint-info-xml.yml | 33 ---- .github/workflows/lint-php-cs.yml | 40 ---- .github/workflows/lint-php.yml | 54 ------ .github/workflows/lint-stylelint.yml | 46 ----- .github/workflows/node.yml | 98 ---------- .../workflows/occ-command-documentation.yml | 88 --------- .github/workflows/openapi.yml | 47 ----- .github/workflows/phpunit-mysql.yml | 174 ----------------- .github/workflows/phpunit-oci.yml | 181 ------------------ .github/workflows/phpunit-pgsql.yml | 171 ----------------- .github/workflows/phpunit-sqlite.yml | 160 ---------------- .github/workflows/pr-feedback.yml | 29 --- .github/workflows/psalm.yml | 36 ---- .github/workflows/update-nextcloud-ocp.yml | 107 ----------- 24 files changed, 7 insertions(+), 2333 deletions(-) delete mode 100644 .github/workflows/appstore-build-publish.yml delete mode 100644 .github/workflows/command-rebase.yml delete mode 100644 .github/workflows/fixup.yml delete mode 100644 .github/workflows/integration-mysql.yml delete mode 100644 .github/workflows/integration-oci.yml delete mode 100644 .github/workflows/integration-pgsql.yml delete mode 100644 .github/workflows/integration-sqlite.yml delete mode 100644 .github/workflows/jest.yml delete mode 100644 .github/workflows/lint-eslint.yml delete mode 100644 .github/workflows/lint-info-xml.yml delete mode 100644 .github/workflows/lint-php-cs.yml delete mode 100644 .github/workflows/lint-php.yml delete mode 100644 .github/workflows/lint-stylelint.yml delete mode 100644 .github/workflows/node.yml delete mode 100644 .github/workflows/occ-command-documentation.yml delete mode 100644 .github/workflows/openapi.yml delete mode 100644 .github/workflows/phpunit-mysql.yml delete mode 100644 .github/workflows/phpunit-oci.yml delete mode 100644 .github/workflows/phpunit-pgsql.yml delete mode 100644 .github/workflows/phpunit-sqlite.yml delete mode 100644 .github/workflows/pr-feedback.yml delete mode 100644 .github/workflows/psalm.yml delete mode 100644 .github/workflows/update-nextcloud-ocp.yml diff --git a/.github/workflows/appstore-build-publish.yml b/.github/workflows/appstore-build-publish.yml deleted file mode 100644 index eec594740f0..00000000000 --- a/.github/workflows/appstore-build-publish.yml +++ /dev/null @@ -1,167 +0,0 @@ -# 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: Build and publish app release - -on: - release: - types: [published] - -env: - PHP_VERSION: 8.1 - -jobs: - build_and_publish: - runs-on: ubuntu-latest - - # Only allowed to be run on nextcloud-releases repositories - if: ${{ github.repository_owner == 'nextcloud-releases' }} - - steps: - - name: Check actor permission - uses: skjnldsv/check-actor-permission@e591dbfe838300c007028e1219ca82cc26e8d7c5 # v2.1 - with: - require: write - - - name: Set app env - run: | - # Split and keep last - echo "APP_NAME=${GITHUB_REPOSITORY##*/}" >> $GITHUB_ENV - echo "APP_VERSION=${GITHUB_REF##*/}" >> $GITHUB_ENV - - - name: Checkout - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - path: ${{ env.APP_NAME }} - - - name: Get appinfo data - id: appinfo - uses: skjnldsv/xpath-action@7e6a7c379d0e9abc8acaef43df403ab4fc4f770c # master - with: - filename: ${{ env.APP_NAME }}/appinfo/info.xml - expression: "//info//dependencies//nextcloud/@min-version" - - - name: Read package.json node and npm engines version - uses: skjnldsv/read-package-engines-version-actions@0ce2ed60f6df073a62a77c0a4958dd0fc68e32e7 # v2.1 - id: versions - # Continue if no package.json - continue-on-error: true - with: - path: ${{ env.APP_NAME }} - fallbackNode: "^16" - fallbackNpm: "^7" - - - name: Set up node ${{ steps.versions.outputs.nodeVersion }} - # Skip if no package.json - if: ${{ steps.versions.outputs.nodeVersion }} - uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c # v3 - with: - node-version: ${{ steps.versions.outputs.nodeVersion }} - - - name: Set up npm ${{ steps.versions.outputs.npmVersion }} - # Skip if no package.json - if: ${{ steps.versions.outputs.npmVersion }} - run: npm i -g npm@"${{ steps.versions.outputs.npmVersion }}" - - - name: Set up php ${{ env.PHP_VERSION }} - uses: shivammathur/setup-php@c5fc0d8281aba02c7fda07d3a70cc5371548067d # v2 - with: - php-version: ${{ env.PHP_VERSION }} - coverage: none - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Check composer.json - id: check_composer - uses: andstor/file-existence-action@20b4d2e596410855db8f9ca21e96fbe18e12930b # v2 - with: - files: "${{ env.APP_NAME }}/composer.json" - - - name: Install composer dependencies - if: steps.check_composer.outputs.files_exists == 'true' - run: | - cd ${{ env.APP_NAME }} - composer install --no-dev - - - name: Build ${{ env.APP_NAME }} - # Skip if no package.json - if: ${{ steps.versions.outputs.nodeVersion }} - run: | - cd ${{ env.APP_NAME }} - npm ci - npm run build - - - name: Check Krankerl config - id: krankerl - uses: andstor/file-existence-action@20b4d2e596410855db8f9ca21e96fbe18e12930b # v2 - with: - files: ${{ env.APP_NAME }}/krankerl.toml - - - name: Install Krankerl - if: steps.krankerl.outputs.files_exists == 'true' - run: | - wget https://github.com/ChristophWurst/krankerl/releases/download/v0.14.0/krankerl_0.14.0_amd64.deb - sudo dpkg -i krankerl_0.14.0_amd64.deb - - - name: Package ${{ env.APP_NAME }} ${{ env.APP_VERSION }} with krankerl - if: steps.krankerl.outputs.files_exists == 'true' - run: | - cd ${{ env.APP_NAME }} - krankerl package - - - name: Package ${{ env.APP_NAME }} ${{ env.APP_VERSION }} with makefile - if: steps.krankerl.outputs.files_exists != 'true' - run: | - cd ${{ env.APP_NAME }} - make appstore - - - name: Checkout server ${{ fromJSON(steps.appinfo.outputs.result).nextcloud.min-version }} - continue-on-error: true - id: server-checkout - run: | - NCVERSION=${{ fromJSON(steps.appinfo.outputs.result).nextcloud.min-version }} - wget --quiet https://download.nextcloud.com/server/releases/latest-$NCVERSION.zip - unzip latest-$NCVERSION.zip - - - name: Checkout server master fallback - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - if: ${{ steps.server-checkout.outcome != 'success' }} - with: - submodules: true - repository: nextcloud/server - path: nextcloud - - - name: Sign app - run: | - # Extracting release - cd ${{ env.APP_NAME }}/build/artifacts - tar -xvf ${{ env.APP_NAME }}.tar.gz - cd ../../../ - # Setting up keys - echo "${{ secrets.APP_PRIVATE_KEY }}" > ${{ env.APP_NAME }}.key - wget --quiet "https://github.com/nextcloud/app-certificate-requests/raw/master/${{ env.APP_NAME }}/${{ env.APP_NAME }}.crt" - # Signing - php nextcloud/occ integrity:sign-app --privateKey=../${{ env.APP_NAME }}.key --certificate=../${{ env.APP_NAME }}.crt --path=../${{ env.APP_NAME }}/build/artifacts/${{ env.APP_NAME }} - # Rebuilding archive - cd ${{ env.APP_NAME }}/build/artifacts - tar -zcvf ${{ env.APP_NAME }}.tar.gz ${{ env.APP_NAME }} - - - name: Attach tarball to github release - uses: svenstaro/upload-release-action@2b9d2847a97b04d02ad5c3df2d3a27baa97ce689 # v2 - id: attach_to_release - with: - repo_token: ${{ secrets.GITHUB_TOKEN }} - file: ${{ env.APP_NAME }}/build/artifacts/${{ env.APP_NAME }}.tar.gz - asset_name: ${{ env.APP_NAME }}-${{ env.APP_VERSION }}.tar.gz - tag: ${{ github.ref }} - overwrite: true - - - name: Upload app to Nextcloud appstore - uses: nextcloud-releases/nextcloud-appstore-push-action@a011fe619bcf6e77ddebc96f9908e1af4071b9c1 # v1 - with: - app_name: ${{ env.APP_NAME }} - appstore_token: ${{ secrets.APPSTORE_TOKEN }} - download_url: ${{ steps.attach_to_release.outputs.browser_download_url }} - app_private_key: ${{ secrets.APP_PRIVATE_KEY }} diff --git a/.github/workflows/command-rebase.yml b/.github/workflows/command-rebase.yml deleted file mode 100644 index ec95ccbbf4b..00000000000 --- a/.github/workflows/command-rebase.yml +++ /dev/null @@ -1,51 +0,0 @@ -# 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: Rebase command - -on: - issue_comment: - types: created - -permissions: - contents: read - -jobs: - rebase: - runs-on: ubuntu-latest - permissions: - contents: none - - # On pull requests and if the comment starts with `/rebase` - if: github.event.issue.pull_request != '' && startsWith(github.event.comment.body, '/rebase') - - steps: - - name: Add reaction on start - uses: peter-evans/create-or-update-comment@ca08ebd5dc95aa0cd97021e9708fcd6b87138c9b # v3.0.1 - with: - token: ${{ secrets.COMMAND_BOT_PAT }} - repository: ${{ github.event.repository.full_name }} - comment-id: ${{ github.event.comment.id }} - reaction-type: "+1" - - - name: Checkout the latest code - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - fetch-depth: 0 - token: ${{ secrets.COMMAND_BOT_PAT }} - - - name: Automatic Rebase - uses: cirrus-actions/rebase@b87d48154a87a85666003575337e27b8cd65f691 # 1.8 - env: - GITHUB_TOKEN: ${{ secrets.COMMAND_BOT_PAT }} - - - name: Add reaction on failure - uses: peter-evans/create-or-update-comment@ca08ebd5dc95aa0cd97021e9708fcd6b87138c9b # v3.0.1 - if: failure() - with: - token: ${{ secrets.COMMAND_BOT_PAT }} - repository: ${{ github.event.repository.full_name }} - comment-id: ${{ github.event.comment.id }} - reaction-type: "-1" diff --git a/.github/workflows/dependabot-approve-merge.yml b/.github/workflows/dependabot-approve-merge.yml index 5b4b1f16d1f..90a957c85bc 100644 --- a/.github/workflows/dependabot-approve-merge.yml +++ b/.github/workflows/dependabot-approve-merge.yml @@ -21,22 +21,16 @@ concurrency: jobs: auto-approve-merge: - if: github.actor == 'dependabot[bot]' runs-on: ubuntu-latest permissions: # for hmarr/auto-approve-action to approve PRs pull-requests: write steps: - # Github actions bot approve - - uses: hmarr/auto-approve-action@b40d6c9ed2fa10c9a2749eca7eb004418a705501 # v2 - if: contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), github.ref) != true - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - - # Nextcloud bot approve and merge request - - uses: ahmadnassri/action-dependabot-auto-merge@45fc124d949b19b6b8bf6645b6c9d55f4f9ac61a # v2 - if: contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), github.ref) != true - with: - target: minor - github-token: ${{ secrets.DEPENDABOT_AUTOMERGE_TOKEN }} + # GitHub actions bot approve + - run: | + echo '${{ github.ref }}' + echo github.ref + echo contains('/nextcloud/vue-', github.ref) + echo contains('/webrtc-adapter-', github.ref) + echo contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), github.ref) diff --git a/.github/workflows/fixup.yml b/.github/workflows/fixup.yml deleted file mode 100644 index 9548d19f2d5..00000000000 --- a/.github/workflows/fixup.yml +++ /dev/null @@ -1,33 +0,0 @@ -# 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: Block fixup and squash commits - -on: - pull_request: - types: [opened, ready_for_review, reopened, synchronize] - -permissions: - contents: read - -concurrency: - group: fixup-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - commit-message-check: - if: github.event.pull_request.draft == false - - permissions: - pull-requests: write - name: Block fixup and squash commits - - runs-on: ubuntu-latest - - steps: - - name: Run check - uses: skjnldsv/block-fixup-merge-action@42d26e1b536ce61e5cf467d65fb76caf4aa85acf # v1 - with: - repo-token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/integration-mysql.yml b/.github/workflows/integration-mysql.yml deleted file mode 100644 index 9ede8f4fe89..00000000000 --- a/.github/workflows/integration-mysql.yml +++ /dev/null @@ -1,164 +0,0 @@ -# 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: Integration mysql - -on: - pull_request: - paths: - # Only running on PR for this file to save CI time (otherwise pgsql only) - - '.github/workflows/integration-mysql.yml' - schedule: - - cron: "5 2 * * *" - -permissions: - contents: read - -concurrency: - group: integration-mysql-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - changes: - runs-on: ubuntu-latest - - outputs: - src: ${{ steps.changes.outputs.src}} - - steps: - - uses: dorny/paths-filter@4512585405083f25c027a35db413c2b3b9006d50 # v2.11.1 - id: changes - continue-on-error: true - with: - filters: | - src: - - '.github/workflows/**' - - 'appinfo/**' - - 'lib/**' - - 'templates/**' - - 'tests/integration/**' - - 'vendor/**' - - 'vendor-bin/**' - - '.php-cs-fixer.dist.php' - - 'composer.json' - - 'composer.lock' - - integration-mysql: - runs-on: ubuntu-latest - - needs: changes - if: needs.changes.outputs.src != 'false' - - strategy: - fail-fast: false - matrix: - test-suite: ['callapi', 'chat', 'chat-2', 'command', 'conversation', 'conversation-2', 'federation', 'integration', 'sharing', 'sharing-2'] - php-versions: ['8.2'] - server-versions: ['master'] - guests-versions: ['master'] - call-summary-bot-versions: ['main'] - notifications-versions: ['master'] - - services: - mysql: - image: ghcr.io/nextcloud/continuous-integration-mariadb-10.6:latest - ports: - - 4444:3306/tcp - env: - MYSQL_ROOT_PASSWORD: rootpassword - options: --health-cmd="mysqladmin ping" --health-interval 5s --health-timeout 2s --health-retries 5 - - steps: - - name: Set app env - run: | - # Split and keep last - echo "APP_NAME=${GITHUB_REPOSITORY##*/}" >> $GITHUB_ENV - - - name: Checkout server - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - submodules: true - repository: nextcloud/server - ref: ${{ matrix.server-versions }} - - - name: Checkout app - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - path: apps/${{ env.APP_NAME }} - - - name: Checkout call_summary_bot app - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - repository: nextcloud/call_summary_bot - path: apps/call_summary_bot - ref: ${{ matrix.call-summary-bot-versions }} - - - name: Checkout guests app - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - repository: nextcloud/guests - path: apps/guests - ref: ${{ matrix.guests-versions }} - - - name: Checkout notifications app - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - repository: nextcloud/notifications - path: apps/notifications - ref: ${{ matrix.notifications-versions }} - - - name: Set up php ${{ matrix.php-versions }} - uses: shivammathur/setup-php@c5fc0d8281aba02c7fda07d3a70cc5371548067d # v2 - with: - php-version: ${{ matrix.php-versions }} - # https://docs.nextcloud.com/server/stable/admin_manual/installation/source_installation.html#prerequisites-for-manual-installation - extensions: bz2, ctype, curl, dom, fileinfo, gd, iconv, intl, json, libxml, mbstring, openssl, pcntl, posix, session, simplexml, xmlreader, xmlwriter, zip, zlib, mysql, pdo_mysql - coverage: none - ini-file: development - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Set up production dependencies - working-directory: apps/${{ env.APP_NAME }} - run: composer i --no-dev - - - name: Set up behat dependencies - working-directory: apps/${{ env.APP_NAME }}/tests/integration - run: composer i - - - name: Set up Nextcloud - env: - DB_PORT: 4444 - run: | - mkdir data - ./occ maintenance:install --verbose --database=mysql --database-name=nextcloud --database-host=127.0.0.1 --database-port=$DB_PORT --database-user=root --database-pass=rootpassword --admin-user admin --admin-pass admin - ./occ config:system:set hashing_default_password --value=true --type=boolean - ./occ app:enable --force ${{ env.APP_NAME }} - ./occ app:enable --force call_summary_bot - ./occ app:enable --force guests - ./occ app:enable --force notifications - - - name: Run integration - working-directory: apps/${{ env.APP_NAME }}/tests/integration - run: bash run.sh features/${{ matrix.test-suite }} - - - name: Print logs - if: always() - run: | - cat data/nextcloud.log - - summary: - permissions: - contents: none - runs-on: ubuntu-latest - needs: [changes, integration-mysql] - - if: always() - - name: integration-mysql-summary - - steps: - - name: Summary status - run: if ${{ needs.changes.outputs.src != 'false' && needs.integration-mysql.result != 'success' }}; then exit 1; fi diff --git a/.github/workflows/integration-oci.yml b/.github/workflows/integration-oci.yml deleted file mode 100644 index 9530912e3c8..00000000000 --- a/.github/workflows/integration-oci.yml +++ /dev/null @@ -1,176 +0,0 @@ -# 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: Integration oci - -on: - pull_request: - paths: - # Only running on PR for this file to save CI time (otherwise pgsql only) - - '.github/workflows/integration-oci.yml' - schedule: - - cron: "5 2 * * *" - -permissions: - contents: read - -concurrency: - group: integration-oci-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - changes: - runs-on: ubuntu-latest - - outputs: - src: ${{ steps.changes.outputs.src}} - - steps: - - uses: dorny/paths-filter@4512585405083f25c027a35db413c2b3b9006d50 # v2.11.1 - id: changes - continue-on-error: true - with: - filters: | - src: - - '.github/workflows/**' - - 'appinfo/**' - - 'lib/**' - - 'templates/**' - - 'tests/integration/**' - - 'vendor/**' - - 'vendor-bin/**' - - '.php-cs-fixer.dist.php' - - 'composer.json' - - 'composer.lock' - - integration-oci: - runs-on: ubuntu-22.04 - - needs: changes - if: needs.changes.outputs.src != 'false' - - strategy: - fail-fast: false - matrix: - test-suite: ['callapi', 'chat', 'chat-2', 'command', 'conversation', 'conversation-2', 'federation', 'integration', 'sharing', 'sharing-2'] - php-versions: ['8.2'] - server-versions: ['master'] - guests-versions: ['master'] - call-summary-bot-versions: ['main'] - notifications-versions: ['master'] - - services: - oracle: - image: ghcr.io/gvenzl/oracle-xe:11 - - # Provide passwords and other environment variables to container - env: - ORACLE_RANDOM_PASSWORD: true - APP_USER: autotest - APP_USER_PASSWORD: owncloud - - # Forward Oracle port - ports: - - 1521:1521/tcp - - # Provide healthcheck script options for startup - options: >- - --health-cmd healthcheck.sh - --health-interval 10s - --health-timeout 5s - --health-retries 10 - - steps: - - name: Set app env - run: | - # Split and keep last - echo "APP_NAME=${GITHUB_REPOSITORY##*/}" >> $GITHUB_ENV - - - name: Checkout server - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - submodules: true - repository: nextcloud/server - ref: ${{ matrix.server-versions }} - - - name: Checkout app - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - path: apps/${{ env.APP_NAME }} - - - name: Checkout call_summary_bot app - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - repository: nextcloud/call_summary_bot - path: apps/call_summary_bot - ref: ${{ matrix.call-summary-bot-versions }} - - - name: Checkout guests app - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - repository: nextcloud/guests - path: apps/guests - ref: ${{ matrix.guests-versions }} - - - name: Checkout notifications app - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - repository: nextcloud/notifications - path: apps/notifications - ref: ${{ matrix.notifications-versions }} - - - name: Set up php ${{ matrix.php-versions }} - uses: shivammathur/setup-php@c5fc0d8281aba02c7fda07d3a70cc5371548067d # v2 - with: - php-version: ${{ matrix.php-versions }} - # https://docs.nextcloud.com/server/stable/admin_manual/installation/source_installation.html#prerequisites-for-manual-installation - extensions: bz2, ctype, curl, dom, fileinfo, gd, iconv, intl, json, libxml, mbstring, openssl, pcntl, posix, session, simplexml, xmlreader, xmlwriter, zip, zlib, oci8 - coverage: none - ini-file: development - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Set up production dependencies - working-directory: apps/${{ env.APP_NAME }} - run: composer i --no-dev - - - name: Set up behat dependencies - working-directory: apps/${{ env.APP_NAME }}/tests/integration - run: composer i - - - name: Set up Nextcloud - env: - DB_PORT: 1521 - run: | - mkdir data - ./occ maintenance:install --verbose --database=oci --database-name=XE --database-host=127.0.0.1 --database-port=$DB_PORT --database-user=autotest --database-pass=owncloud --admin-user admin --admin-pass admin - ./occ config:system:set hashing_default_password --value=true --type=boolean - ./occ app:enable --force ${{ env.APP_NAME }} - ./occ app:enable --force call_summary_bot - ./occ app:enable --force guests - ./occ app:enable --force notifications - - - name: Run integration - working-directory: apps/${{ env.APP_NAME }}/tests/integration - run: bash run.sh features/${{ matrix.test-suite }} - - - name: Print logs - if: always() - run: | - cat data/nextcloud.log - - summary: - permissions: - contents: none - runs-on: ubuntu-latest - needs: [changes, integration-oci] - - if: always() - - name: integration-oci-summary - - steps: - - name: Summary status - run: if ${{ needs.changes.outputs.src != 'false' && needs.integration-oci.result != 'success' }}; then exit 1; fi diff --git a/.github/workflows/integration-pgsql.yml b/.github/workflows/integration-pgsql.yml deleted file mode 100644 index fb0207a78a1..00000000000 --- a/.github/workflows/integration-pgsql.yml +++ /dev/null @@ -1,171 +0,0 @@ -# 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: Integration pgsql - -on: - pull_request: - schedule: - - cron: "5 2 * * *" - -permissions: - contents: read - -concurrency: - group: integration-pgsql-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - changes: - runs-on: ubuntu-latest - - outputs: - src: ${{ steps.changes.outputs.src}} - - steps: - - uses: dorny/paths-filter@4512585405083f25c027a35db413c2b3b9006d50 # v2.11.1 - id: changes - continue-on-error: true - with: - filters: | - src: - - '.github/workflows/**' - - 'appinfo/**' - - 'lib/**' - - 'templates/**' - - 'tests/integration/**' - - 'vendor/**' - - 'vendor-bin/**' - - '.php-cs-fixer.dist.php' - - 'composer.json' - - 'composer.lock' - - integration-pgsql: - runs-on: ubuntu-latest - - needs: changes - if: needs.changes.outputs.src != 'false' - - strategy: - fail-fast: false - matrix: - test-suite: ['callapi', 'chat', 'chat-2', 'command', 'conversation', 'conversation-2', 'federation', 'integration', 'sharing', 'sharing-2'] - php-versions: ['8.3'] - server-versions: ['master'] - guests-versions: ['master'] - call-summary-bot-versions: ['main'] - notifications-versions: ['master'] - - services: - postgres: - image: ghcr.io/nextcloud/continuous-integration-postgres-14:latest - ports: - - 4444:5432/tcp - env: - POSTGRES_USER: root - POSTGRES_PASSWORD: rootpassword - POSTGRES_DB: nextcloud - options: --health-cmd pg_isready --health-interval 5s --health-timeout 2s --health-retries 5 - - steps: - - name: Set app env - run: | - # Split and keep last - echo "APP_NAME=${GITHUB_REPOSITORY##*/}" >> $GITHUB_ENV - - - name: Checkout server - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - submodules: true - repository: nextcloud/server - ref: ${{ matrix.server-versions }} - - - name: Patch version check for nightly PHP - if: ${{ matrix.php-versions == '8.4' }} - run: echo " lib/versioncheck.php - - - name: Checkout app - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - path: apps/${{ env.APP_NAME }} - - - name: Checkout call_summary_bot app - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - repository: nextcloud/call_summary_bot - path: apps/call_summary_bot - ref: ${{ matrix.call-summary-bot-versions }} - - - name: Checkout guests app - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - repository: nextcloud/guests - path: apps/guests - ref: ${{ matrix.guests-versions }} - - - name: Checkout notifications app - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - repository: nextcloud/notifications - path: apps/notifications - ref: ${{ matrix.notifications-versions }} - - - name: Set up php ${{ matrix.php-versions }} - uses: shivammathur/setup-php@c5fc0d8281aba02c7fda07d3a70cc5371548067d # v2 - with: - php-version: ${{ matrix.php-versions }} - # https://docs.nextcloud.com/server/stable/admin_manual/installation/source_installation.html#prerequisites-for-manual-installation - extensions: apcu, bz2, ctype, curl, dom, fileinfo, gd, iconv, intl, json, libxml, mbstring, openssl, pcntl, posix, session, simplexml, xmlreader, xmlwriter, zip, zlib, pgsql, pdo_pgsql - coverage: none - ini-file: development - # Temporary workaround for missing pcntl_* in PHP 8.3: ini-values: apc.enable_cli=on - ini-values: apc.enable_cli=on, disable_functions= - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Set up production dependencies - working-directory: apps/${{ env.APP_NAME }} - run: composer i --no-dev - - - name: Set up behat dependencies - working-directory: apps/${{ env.APP_NAME }}/tests/integration - run: composer i - - - name: Set up Nextcloud - env: - DB_PORT: 4444 - run: | - mkdir data - ./occ maintenance:install --verbose --database=pgsql --database-name=nextcloud --database-host=127.0.0.1 --database-port=$DB_PORT --database-user=root --database-pass=rootpassword --admin-user admin --admin-pass admin - ./occ config:system:set hashing_default_password --value=true --type=boolean - ./occ config:system:set memcache.local --value="\\OC\\Memcache\\APCu" - ./occ config:system:set memcache.distributed --value="\\OC\\Memcache\\APCu" - ./occ app:enable --force ${{ env.APP_NAME }} - ./occ app:enable --force call_summary_bot - ./occ app:enable --force guests - ./occ app:enable --force notifications - - - name: Run integration - working-directory: apps/${{ env.APP_NAME }}/tests/integration - run: bash run.sh features/${{ matrix.test-suite }} - - - name: Print logs - if: always() - run: | - cat data/nextcloud.log - - summary: - permissions: - contents: none - runs-on: ubuntu-latest - needs: [changes, integration-pgsql] - - if: always() - - name: integration-pgsql-summary - - steps: - - name: Summary status - run: if ${{ needs.changes.outputs.src != 'false' && needs.integration-pgsql.result != 'success' }}; then exit 1; fi diff --git a/.github/workflows/integration-sqlite.yml b/.github/workflows/integration-sqlite.yml deleted file mode 100644 index ee7bea5cf91..00000000000 --- a/.github/workflows/integration-sqlite.yml +++ /dev/null @@ -1,155 +0,0 @@ -# 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: Integration sqlite - -on: - pull_request: - paths: - # Only running on PR for this file to save CI time (otherwise pgsql only) - - '.github/workflows/integration-sqlite.yml' - schedule: - - cron: "5 2 * * *" - -permissions: - contents: read - -concurrency: - group: integration-sqlite-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - changes: - runs-on: ubuntu-latest - - outputs: - src: ${{ steps.changes.outputs.src}} - - steps: - - uses: dorny/paths-filter@4512585405083f25c027a35db413c2b3b9006d50 # v2.11.1 - id: changes - continue-on-error: true - with: - filters: | - src: - - '.github/workflows/**' - - 'appinfo/**' - - 'lib/**' - - 'templates/**' - - 'tests/integration/**' - - 'vendor/**' - - 'vendor-bin/**' - - '.php-cs-fixer.dist.php' - - 'composer.json' - - 'composer.lock' - - integration-sqlite: - runs-on: ubuntu-latest - - needs: changes - if: needs.changes.outputs.src != 'false' - - strategy: - fail-fast: false - matrix: - test-suite: ['callapi', 'chat', 'chat-2', 'command', 'conversation', 'conversation-2', 'federation', 'integration', 'sharing', 'sharing-2'] - php-versions: ['8.2'] - server-versions: ['master'] - guests-versions: ['master'] - call-summary-bot-versions: ['main'] - notifications-versions: ['master'] - - steps: - - name: Set app env - run: | - # Split and keep last - echo "APP_NAME=${GITHUB_REPOSITORY##*/}" >> $GITHUB_ENV - - - name: Checkout server - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - submodules: true - repository: nextcloud/server - ref: ${{ matrix.server-versions }} - - - name: Checkout app - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - path: apps/${{ env.APP_NAME }} - - - name: Checkout call_summary_bot app - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - repository: nextcloud/call_summary_bot - path: apps/call_summary_bot - ref: ${{ matrix.call-summary-bot-versions }} - - - name: Checkout guests app - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - repository: nextcloud/guests - path: apps/guests - ref: ${{ matrix.guests-versions }} - - - name: Checkout notifications app - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - repository: nextcloud/notifications - path: apps/notifications - ref: ${{ matrix.notifications-versions }} - - - name: Set up php ${{ matrix.php-versions }} - uses: shivammathur/setup-php@c5fc0d8281aba02c7fda07d3a70cc5371548067d # v2 - with: - php-version: ${{ matrix.php-versions }} - # https://docs.nextcloud.com/server/stable/admin_manual/installation/source_installation.html#prerequisites-for-manual-installation - extensions: bz2, ctype, curl, dom, fileinfo, gd, iconv, intl, json, libxml, mbstring, openssl, pcntl, posix, session, simplexml, xmlreader, xmlwriter, zip, zlib, sqlite, pdo_sqlite - coverage: none - ini-file: development - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Set up production dependencies - working-directory: apps/${{ env.APP_NAME }} - run: composer i --no-dev - - - name: Set up behat dependencies - working-directory: apps/${{ env.APP_NAME }}/tests/integration - run: composer i - - - name: Set up Nextcloud - env: - DB_PORT: 4444 - run: | - mkdir data - ./occ maintenance:install --verbose --database=sqlite --database-name=nextcloud --database-host=127.0.0.1 --database-port=$DB_PORT --database-user=root --database-pass=rootpassword --admin-user admin --admin-pass admin - ./occ config:system:set hashing_default_password --value=true --type=boolean - ./occ app:enable --force ${{ env.APP_NAME }} - ./occ app:enable --force call_summary_bot - ./occ app:enable --force guests - ./occ app:enable --force notifications - - - name: Run integration - working-directory: apps/${{ env.APP_NAME }}/tests/integration - run: bash run.sh features/${{ matrix.test-suite }} - - - name: Print logs - if: always() - run: | - cat data/nextcloud.log - - summary: - permissions: - contents: none - runs-on: ubuntu-latest - needs: [changes, integration-sqlite] - - if: always() - - name: integration-sqlite-summary - - steps: - - name: Summary status - run: if ${{ needs.changes.outputs.src != 'false' && needs.integration-sqlite.result != 'success' }}; then exit 1; fi diff --git a/.github/workflows/jest.yml b/.github/workflows/jest.yml deleted file mode 100644 index 22e795ed7fa..00000000000 --- a/.github/workflows/jest.yml +++ /dev/null @@ -1,45 +0,0 @@ -name: Jest - -on: - pull_request: - paths: - - '.github/workflows/**' - - 'src/**' - - 'appinfo/info.xml' - - 'package.json' - - 'package-lock.json' - - 'tsconfig.json' - - '**.js' - -concurrency: - group: jest-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - build: - runs-on: ubuntu-latest - - name: node - steps: - - uses: actions/checkout@v3 - - - name: Read package.json node and npm engines version - uses: skjnldsv/read-package-engines-version-actions@v1.2 - id: versions - with: - fallbackNode: '^12' - fallbackNpm: '^6' - - - name: Set up node ${{ steps.versions.outputs.nodeVersion }} - uses: actions/setup-node@v3 - with: - node-version: ${{ steps.versions.outputs.nodeVersion }} - - - name: Set up npm ${{ steps.versions.outputs.npmVersion }} - run: npm i -g npm@"${{ steps.versions.outputs.npmVersion }}" - - - name: Install dependencies - run: npm ci - - - name: Run jest - run: npm run test:coverage -- --colors diff --git a/.github/workflows/lint-eslint.yml b/.github/workflows/lint-eslint.yml deleted file mode 100644 index dc313a57737..00000000000 --- a/.github/workflows/lint-eslint.yml +++ /dev/null @@ -1,94 +0,0 @@ -# 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 -# -# Use lint-eslint together with lint-eslint-when-unrelated to make eslint a required check for GitHub actions -# https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/defining-the-mergeability-of-pull-requests/troubleshooting-required-status-checks#handling-skipped-but-required-checks - -name: Lint eslint - -on: pull_request - -permissions: - contents: read - -concurrency: - group: lint-eslint-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - changes: - runs-on: ubuntu-latest - - outputs: - src: ${{ steps.changes.outputs.src}} - - steps: - - uses: dorny/paths-filter@4512585405083f25c027a35db413c2b3b9006d50 # v2.11.1 - id: changes - continue-on-error: true - with: - filters: | - src: - - '.github/workflows/**' - - 'src/**' - - 'appinfo/info.xml' - - 'package.json' - - 'package-lock.json' - - 'tsconfig.json' - - '.eslintrc.*' - - '.eslintignore' - - '**.js' - - '**.ts' - - '**.vue' - - lint: - runs-on: ubuntu-latest - - needs: changes - if: needs.changes.outputs.src != 'false' - - name: NPM lint - - steps: - - name: Checkout - uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 - - - name: Read package.json node and npm engines version - uses: skjnldsv/read-package-engines-version-actions@8205673bab74a63eb9b8093402fd9e0e018663a1 # v2.2 - id: versions - with: - fallbackNode: '^20' - fallbackNpm: '^9' - - - name: Set up node ${{ steps.versions.outputs.nodeVersion }} - uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # v3 - with: - node-version: ${{ steps.versions.outputs.nodeVersion }} - - - name: Set up npm ${{ steps.versions.outputs.npmVersion }} - run: npm i -g npm@"${{ steps.versions.outputs.npmVersion }}" - - - name: Install dependencies - env: - CYPRESS_INSTALL_BINARY: 0 - run: npm ci - - - name: Lint - run: npm run lint - - summary: - permissions: - contents: none - runs-on: ubuntu-latest - needs: [changes, lint] - - if: always() - - # This is the summary, we just avoid to rename it so that branch protection rules still match - name: eslint - - steps: - - name: Summary status - run: if ${{ needs.changes.outputs.src != 'false' && needs.lint.result != 'success' }}; then exit 1; fi diff --git a/.github/workflows/lint-info-xml.yml b/.github/workflows/lint-info-xml.yml deleted file mode 100644 index 33ca345901a..00000000000 --- a/.github/workflows/lint-info-xml.yml +++ /dev/null @@ -1,33 +0,0 @@ -# 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 info.xml - -on: pull_request - -permissions: - contents: read - -concurrency: - group: lint-info-xml-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - xml-linters: - runs-on: ubuntu-latest - - name: info.xml lint - steps: - - name: Checkout - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - - - name: Download schema - run: wget https://raw.githubusercontent.com/nextcloud/appstore/master/nextcloudappstore/api/v1/release/info.xsd - - - name: Lint info.xml - uses: ChristophWurst/xmllint-action@39155a91429af431d65fafc21fa52ba5c4f5cb71 # v1.1 - with: - xml-file: ./appinfo/info.xml - xml-schema-file: ./info.xsd diff --git a/.github/workflows/lint-php-cs.yml b/.github/workflows/lint-php-cs.yml deleted file mode 100644 index f8d3375111f..00000000000 --- a/.github/workflows/lint-php-cs.yml +++ /dev/null @@ -1,40 +0,0 @@ -# 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 php-cs - -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@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - - - name: Set up php - uses: shivammathur/setup-php@c5fc0d8281aba02c7fda07d3a70cc5371548067d # v2 - with: - php-version: 8.1 - coverage: none - ini-file: development - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - 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 ) diff --git a/.github/workflows/lint-php.yml b/.github/workflows/lint-php.yml deleted file mode 100644 index d759ff89143..00000000000 --- a/.github/workflows/lint-php.yml +++ /dev/null @@ -1,54 +0,0 @@ -# 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 php - -on: pull_request - -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", "8.3" ] - - name: php-lint - - steps: - - name: Checkout - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - - - name: Set up php ${{ matrix.php-versions }} - uses: shivammathur/setup-php@c5fc0d8281aba02c7fda07d3a70cc5371548067d # v2 - with: - php-version: ${{ matrix.php-versions }} - coverage: none - ini-file: development - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - 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 diff --git a/.github/workflows/lint-stylelint.yml b/.github/workflows/lint-stylelint.yml deleted file mode 100644 index 60cb63a560c..00000000000 --- a/.github/workflows/lint-stylelint.yml +++ /dev/null @@ -1,46 +0,0 @@ -# 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 stylelint - -on: pull_request - -permissions: - contents: read - -concurrency: - group: lint-stylelint-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - lint: - runs-on: ubuntu-latest - - name: stylelint - - steps: - - name: Checkout - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - - - name: Read package.json node and npm engines version - uses: skjnldsv/read-package-engines-version-actions@0ce2ed60f6df073a62a77c0a4958dd0fc68e32e7 # v2.1 - id: versions - with: - fallbackNode: '^16' - fallbackNpm: '^7' - - - name: Set up node ${{ steps.versions.outputs.nodeVersion }} - uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c # v3 - with: - node-version: ${{ steps.versions.outputs.nodeVersion }} - - - name: Set up npm ${{ steps.versions.outputs.npmVersion }} - run: npm i -g npm@"${{ steps.versions.outputs.npmVersion }}" - - - name: Install dependencies - run: npm ci - - - name: Lint - run: npm run stylelint diff --git a/.github/workflows/node.yml b/.github/workflows/node.yml deleted file mode 100644 index c623d086b96..00000000000 --- a/.github/workflows/node.yml +++ /dev/null @@ -1,98 +0,0 @@ -# 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: Node - -on: pull_request - -permissions: - contents: read - -concurrency: - group: node-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - changes: - runs-on: ubuntu-latest - - outputs: - src: ${{ steps.changes.outputs.src}} - - steps: - - uses: dorny/paths-filter@4512585405083f25c027a35db413c2b3b9006d50 # v2.11.1 - id: changes - continue-on-error: true - with: - filters: | - src: - - '.github/workflows/**' - - 'src/**' - - 'appinfo/info.xml' - - 'package.json' - - 'package-lock.json' - - 'tsconfig.json' - - '**.js' - - '**.ts' - - '**.vue' - - build: - runs-on: ubuntu-latest - - needs: changes - if: needs.changes.outputs.src != 'false' - - name: NPM build - steps: - - name: Checkout - uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 - - - name: Read package.json node and npm engines version - uses: skjnldsv/read-package-engines-version-actions@8205673bab74a63eb9b8093402fd9e0e018663a1 # v2.2 - id: versions - with: - fallbackNode: '^20' - fallbackNpm: '^9' - - - name: Set up node ${{ steps.versions.outputs.nodeVersion }} - uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # v3 - with: - node-version: ${{ steps.versions.outputs.nodeVersion }} - - - name: Set up npm ${{ steps.versions.outputs.npmVersion }} - run: npm i -g npm@"${{ steps.versions.outputs.npmVersion }}" - - - name: Install dependencies & build - env: - CYPRESS_INSTALL_BINARY: 0 - run: | - npm ci - npm run build --if-present - - - name: Check webpack build changes - run: | - bash -c "[[ ! \"`git status --porcelain `\" ]] || (echo 'Please recompile and commit the assets, see the section \"Show changes on failure\" for details' && exit 1)" - - - name: Show changes on failure - if: failure() - run: | - git status - git --no-pager diff - exit 1 # make it red to grab attention - - summary: - permissions: - contents: none - runs-on: ubuntu-latest - needs: [changes, build] - - if: always() - - # This is the summary, we just avoid to rename it so that branch protection rules still match - name: node - - steps: - - name: Summary status - run: if ${{ needs.changes.outputs.src != 'false' && needs.build.result != 'success' }}; then exit 1; fi diff --git a/.github/workflows/occ-command-documentation.yml b/.github/workflows/occ-command-documentation.yml deleted file mode 100644 index 24a76008d4e..00000000000 --- a/.github/workflows/occ-command-documentation.yml +++ /dev/null @@ -1,88 +0,0 @@ -name: Documentation - -on: - pull_request: - paths: - - '.github/workflows/**' - - 'appinfo/**' - - 'lib/**' - - 'templates/**' - - 'tests/**' - - 'vendor/**' - - 'vendor-bin/**' - - '.php-cs-fixer.dist.php' - - 'composer.json' - - 'composer.lock' - -permissions: - contents: read - -concurrency: - group: occ-commands-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - occ-commands: - runs-on: ubuntu-latest - - strategy: - matrix: - php-versions: ['8.2'] - server-versions: ['master'] - - steps: - - name: Set app env - run: | - # Split and keep last - echo "APP_NAME=${GITHUB_REPOSITORY##*/}" >> $GITHUB_ENV - - - name: Checkout server - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - submodules: true - repository: nextcloud/server - ref: ${{ matrix.server-versions }} - - - name: Checkout app - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - with: - path: apps/${{ env.APP_NAME }} - - - name: Set up php ${{ matrix.php-versions }} - uses: shivammathur/setup-php@c5fc0d8281aba02c7fda07d3a70cc5371548067d # v2 - with: - php-version: ${{ matrix.php-versions }} - # https://docs.nextcloud.com/server/stable/admin_manual/installation/source_installation.html#prerequisites-for-manual-installation - extensions: bz2, ctype, curl, dom, fileinfo, gd, iconv, intl, json, libxml, mbstring, openssl, pcntl, posix, session, simplexml, xmlreader, xmlwriter, zip, zlib, sqlite, pdo_sqlite - coverage: none - ini-file: development - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Check composer file existence - id: check_composer - uses: andstor/file-existence-action@20b4d2e596410855db8f9ca21e96fbe18e12930b # v2 - with: - files: apps/${{ env.APP_NAME }}/composer.json - - - name: Set up dependencies - # Only run if phpunit config file exists - if: steps.check_composer.outputs.files_exists == 'true' - working-directory: apps/${{ env.APP_NAME }} - run: composer i - - - name: Set up Nextcloud - env: - DB_PORT: 4444 - run: | - mkdir data - ./occ maintenance:install --verbose --database=sqlite --database-name=nextcloud --database-host=127.0.0.1 --database-port=$DB_PORT --database-user=root --database-pass=rootpassword --admin-user admin --admin-pass admin - ./occ app:enable ${{ env.APP_NAME }} - ./occ config:system:set debug --value true --type boolean - - - name: Check if documentation is up to date - id: check_documentation - run: | - ./occ talk:developer:update-docs - cd apps/${{ env.APP_NAME }} - bash -c "[[ ! \"`git status --porcelain `\" ]] || (cat docs/occ.md && echo 'Documentation outdated. Run the command talk:developer:update-docs locally, commit the occ.md file and push the changes.' && exit 1)" diff --git a/.github/workflows/openapi.yml b/.github/workflows/openapi.yml deleted file mode 100644 index 12735ece066..00000000000 --- a/.github/workflows/openapi.yml +++ /dev/null @@ -1,47 +0,0 @@ -name: OpenAPI - -on: pull_request - -permissions: - contents: read - -concurrency: - group: openapi-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - openapi: - runs-on: ubuntu-latest - - if: ${{ github.repository_owner != 'nextcloud-gmbh' }} - - steps: - - name: Checkout - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - - - name: Set up php - uses: shivammathur/setup-php@c5fc0d8281aba02c7fda07d3a70cc5371548067d # v2 - with: - php-version: '8.2' - extensions: xml - coverage: none - ini-file: development - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Set up dependencies - run: composer i - - - name: Regenerate OpenAPI - run: composer run openapi - - - name: Check openapi.json changes - run: | - bash -c "[[ ! \"`git status --porcelain `\" ]] || (echo 'Please run \"composer run openapi\" and commit the openapi.json, see the section \"Show changes on failure\" for details' && exit 1)" - - - name: Show changes on failure - if: failure() - run: | - git status - git --no-pager diff - exit 1 # make it red to grab attention diff --git a/.github/workflows/phpunit-mysql.yml b/.github/workflows/phpunit-mysql.yml deleted file mode 100644 index ddd3aaaaf6c..00000000000 --- a/.github/workflows/phpunit-mysql.yml +++ /dev/null @@ -1,174 +0,0 @@ -# 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: PHPUnit mysql - -on: - pull_request: - schedule: - - cron: "5 2 * * *" - -permissions: - contents: read - -concurrency: - group: phpunit-mysql-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - changes: - runs-on: ubuntu-latest - - outputs: - src: ${{ steps.changes.outputs.src}} - - steps: - - uses: dorny/paths-filter@4512585405083f25c027a35db413c2b3b9006d50 # v2.11.1 - id: changes - continue-on-error: true - with: - filters: | - src: - - '.github/workflows/**' - - 'appinfo/**' - - 'lib/**' - - 'templates/**' - - 'tests/**' - - 'vendor/**' - - 'vendor-bin/**' - - '.php-cs-fixer.dist.php' - - 'composer.json' - - 'composer.lock' - - phpunit-mysql: - runs-on: ubuntu-latest - - needs: changes - if: needs.changes.outputs.src != 'false' - - strategy: - matrix: - php-versions: ['8.0', '8.1', '8.2', '8.3'] - server-versions: ['master'] - - services: - mysql: - image: ghcr.io/nextcloud/continuous-integration-mariadb-10.6:latest - ports: - - 4444:3306/tcp - env: - MYSQL_ROOT_PASSWORD: rootpassword - options: --health-cmd="mysqladmin ping" --health-interval 5s --health-timeout 2s --health-retries 5 - - steps: - - name: Set app env - run: | - # Split and keep last - echo "APP_NAME=${GITHUB_REPOSITORY##*/}" >> $GITHUB_ENV - - - name: Checkout server - uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 - with: - submodules: true - repository: nextcloud/server - ref: ${{ matrix.server-versions }} - - - name: Checkout app - uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 - with: - path: apps/${{ env.APP_NAME }} - - - name: Set up php ${{ matrix.php-versions }} - uses: shivammathur/setup-php@4bd44f22a98a19e0950cbad5f31095157cc9621b # v2 - with: - php-version: ${{ matrix.php-versions }} - # https://docs.nextcloud.com/server/stable/admin_manual/installation/source_installation.html#prerequisites-for-manual-installation - extensions: bz2, ctype, curl, dom, fileinfo, gd, iconv, intl, json, libxml, mbstring, openssl, pcntl, posix, session, simplexml, xmlreader, xmlwriter, zip, zlib, mysql, pdo_mysql - coverage: none - ini-file: development - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Enable ONLY_FULL_GROUP_BY MySQL option - run: | - echo "SET GLOBAL sql_mode=(SELECT CONCAT(@@sql_mode,',ONLY_FULL_GROUP_BY'));" | mysql -h 127.0.0.1 -P 4444 -u root -prootpassword - echo "SELECT @@sql_mode;" | mysql -h 127.0.0.1 -P 4444 -u root -prootpassword - - - name: Check composer file existence - id: check_composer - uses: andstor/file-existence-action@20b4d2e596410855db8f9ca21e96fbe18e12930b # v2 - with: - files: apps/${{ env.APP_NAME }}/composer.json - - - name: Set up dependencies - # Only run if phpunit config file exists - if: steps.check_composer.outputs.files_exists == 'true' - working-directory: apps/${{ env.APP_NAME }} - run: composer i - - - name: Set up Nextcloud - env: - DB_PORT: 4444 - run: | - mkdir data - ./occ maintenance:install --verbose --database=mysql --database-name=nextcloud --database-host=127.0.0.1 --database-port=$DB_PORT --database-user=root --database-pass=rootpassword --admin-user admin --admin-pass admin - ./occ app:enable --force ${{ env.APP_NAME }} - - - name: Check PHPUnit script is defined - id: check_phpunit - continue-on-error: true - working-directory: apps/${{ env.APP_NAME }} - run: | - composer run --list | grep "^ test:unit " | wc -l | grep 1 - - - name: PHPUnit - # Only run if phpunit config file exists - if: steps.check_phpunit.outcome == 'success' - working-directory: apps/${{ env.APP_NAME }} - run: composer run test:unit - - - name: Check PHPUnit integration script is defined - id: check_integration - continue-on-error: true - working-directory: apps/${{ env.APP_NAME }} - run: | - composer run --list | grep "^ test:integration " | wc -l | grep 1 - - - name: Run Nextcloud - # Only run if phpunit integration config file exists - if: steps.check_integration.outcome == 'success' - run: php -S localhost:8080 & - - - name: PHPUnit integration - # Only run if phpunit integration config file exists - if: steps.check_integration.outcome == 'success' - working-directory: apps/${{ env.APP_NAME }} - run: composer run test:integration - - - name: Print logs - if: always() - run: | - cat data/nextcloud.log - - - name: Skipped - # Fail the action when neither unit nor integration tests ran - if: steps.check_phpunit.outcome == 'failure' && steps.check_integration.outcome == 'failure' - run: | - echo 'Neither PHPUnit nor PHPUnit integration tests are specified in composer.json scripts' - exit 1 - - summary: - permissions: - contents: none - runs-on: ubuntu-latest - needs: [changes, phpunit-mysql] - - if: always() - - name: phpunit-mysql-summary - - steps: - - name: Summary status - run: if ${{ needs.changes.outputs.src != 'false' && needs.phpunit-mysql.result != 'success' }}; then exit 1; fi diff --git a/.github/workflows/phpunit-oci.yml b/.github/workflows/phpunit-oci.yml deleted file mode 100644 index 843e4e6be52..00000000000 --- a/.github/workflows/phpunit-oci.yml +++ /dev/null @@ -1,181 +0,0 @@ -# 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: PHPUnit OCI - -on: - pull_request: - schedule: - - cron: "5 2 * * *" - -permissions: - contents: read - -concurrency: - group: phpunit-oci-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - changes: - runs-on: ubuntu-latest - - outputs: - src: ${{ steps.changes.outputs.src}} - - steps: - - uses: dorny/paths-filter@4512585405083f25c027a35db413c2b3b9006d50 # v2.11.1 - id: changes - continue-on-error: true - with: - filters: | - src: - - '.github/workflows/**' - - 'appinfo/**' - - 'lib/**' - - 'templates/**' - - 'tests/**' - - 'vendor/**' - - 'vendor-bin/**' - - '.php-cs-fixer.dist.php' - - 'composer.json' - - 'composer.lock' - - phpunit-oci: - runs-on: ubuntu-22.04 - - needs: changes - if: needs.changes.outputs.src != 'false' - - strategy: - matrix: - php-versions: ['8.0'] - server-versions: ['master'] - - services: - oracle: - image: ghcr.io/gvenzl/oracle-xe:11 - - # Provide passwords and other environment variables to container - env: - ORACLE_RANDOM_PASSWORD: true - APP_USER: autotest - APP_USER_PASSWORD: owncloud - - # Forward Oracle port - ports: - - 1521:1521/tcp - - # Provide healthcheck script options for startup - options: >- - --health-cmd healthcheck.sh - --health-interval 10s - --health-timeout 5s - --health-retries 10 - - steps: - - name: Set app env - run: | - # Split and keep last - echo "APP_NAME=${GITHUB_REPOSITORY##*/}" >> $GITHUB_ENV - - - name: Checkout server - uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 - with: - submodules: true - repository: nextcloud/server - ref: ${{ matrix.server-versions }} - - - name: Checkout app - uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 - with: - path: apps/${{ env.APP_NAME }} - - - name: Set up php ${{ matrix.php-versions }} - uses: shivammathur/setup-php@4bd44f22a98a19e0950cbad5f31095157cc9621b # v2 - with: - php-version: ${{ matrix.php-versions }} - # https://docs.nextcloud.com/server/stable/admin_manual/installation/source_installation.html#prerequisites-for-manual-installation - extensions: bz2, ctype, curl, dom, fileinfo, gd, iconv, intl, json, libxml, mbstring, openssl, pcntl, posix, session, simplexml, xmlreader, xmlwriter, zip, zlib, oci8 - coverage: none - ini-file: development - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Check composer file existence - id: check_composer - uses: andstor/file-existence-action@20b4d2e596410855db8f9ca21e96fbe18e12930b # v2 - with: - files: apps/${{ env.APP_NAME }}/composer.json - - - name: Set up dependencies - # Only run if phpunit config file exists - if: steps.check_composer.outputs.files_exists == 'true' - working-directory: apps/${{ env.APP_NAME }} - run: composer i - - - name: Set up Nextcloud - env: - DB_PORT: 1521 - run: | - mkdir data - ./occ maintenance:install --verbose --database=oci --database-name=XE --database-host=127.0.0.1 --database-port=$DB_PORT --database-user=autotest --database-pass=owncloud --admin-user admin --admin-pass admin - ./occ app:enable --force ${{ env.APP_NAME }} - - - name: Check PHPUnit script is defined - id: check_phpunit - continue-on-error: true - working-directory: apps/${{ env.APP_NAME }} - run: | - composer run --list | grep "^ test:unit " | wc -l | grep 1 - - - name: PHPUnit - # Only run if phpunit config file exists - if: steps.check_phpunit.outcome == 'success' - working-directory: apps/${{ env.APP_NAME }} - run: composer run test:unit - - - name: Check PHPUnit integration script is defined - id: check_integration - continue-on-error: true - working-directory: apps/${{ env.APP_NAME }} - run: | - composer run --list | grep "^ test:integration " | wc -l | grep 1 - - - name: Run Nextcloud - # Only run if phpunit integration config file exists - if: steps.check_integration.outcome == 'success' - run: php -S localhost:8080 & - - - name: PHPUnit integration - # Only run if phpunit integration config file exists - if: steps.check_integration.outcome == 'success' - working-directory: apps/${{ env.APP_NAME }} - run: composer run test:integration - - - name: Print logs - if: always() - run: | - cat data/nextcloud.log - - - name: Skipped - # Fail the action when neither unit nor integration tests ran - if: steps.check_phpunit.outcome == 'failure' && steps.check_integration.outcome == 'failure' - run: | - echo 'Neither PHPUnit nor PHPUnit integration tests are specified in composer.json scripts' - exit 1 - - summary: - permissions: - contents: none - runs-on: ubuntu-latest - needs: [changes, phpunit-oci] - - if: always() - - name: phpunit-oci-summary - - steps: - - name: Summary status - run: if ${{ needs.changes.outputs.src != 'false' && needs.phpunit-oci.result != 'success' }}; then exit 1; fi diff --git a/.github/workflows/phpunit-pgsql.yml b/.github/workflows/phpunit-pgsql.yml deleted file mode 100644 index 8e296c90dde..00000000000 --- a/.github/workflows/phpunit-pgsql.yml +++ /dev/null @@ -1,171 +0,0 @@ -# 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: PHPUnit pgsql - -on: - pull_request: - schedule: - - cron: "5 2 * * *" - -permissions: - contents: read - -concurrency: - group: phpunit-pgsql-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - changes: - runs-on: ubuntu-latest - - outputs: - src: ${{ steps.changes.outputs.src}} - - steps: - - uses: dorny/paths-filter@4512585405083f25c027a35db413c2b3b9006d50 # v2.11.1 - id: changes - continue-on-error: true - with: - filters: | - src: - - '.github/workflows/**' - - 'appinfo/**' - - 'lib/**' - - 'templates/**' - - 'tests/**' - - 'vendor/**' - - 'vendor-bin/**' - - '.php-cs-fixer.dist.php' - - 'composer.json' - - 'composer.lock' - - phpunit-pgsql: - runs-on: ubuntu-latest - - needs: changes - if: needs.changes.outputs.src != 'false' - - strategy: - matrix: - php-versions: ['8.0'] - server-versions: ['master'] - - services: - postgres: - image: ghcr.io/nextcloud/continuous-integration-postgres-14:latest - ports: - - 4444:5432/tcp - env: - POSTGRES_USER: root - POSTGRES_PASSWORD: rootpassword - POSTGRES_DB: nextcloud - options: --health-cmd pg_isready --health-interval 5s --health-timeout 2s --health-retries 5 - - steps: - - name: Set app env - run: | - # Split and keep last - echo "APP_NAME=${GITHUB_REPOSITORY##*/}" >> $GITHUB_ENV - - - name: Checkout server - uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 - with: - submodules: true - repository: nextcloud/server - ref: ${{ matrix.server-versions }} - - - name: Checkout app - uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 - with: - path: apps/${{ env.APP_NAME }} - - - name: Set up php ${{ matrix.php-versions }} - uses: shivammathur/setup-php@4bd44f22a98a19e0950cbad5f31095157cc9621b # v2 - with: - php-version: ${{ matrix.php-versions }} - # https://docs.nextcloud.com/server/stable/admin_manual/installation/source_installation.html#prerequisites-for-manual-installation - extensions: bz2, ctype, curl, dom, fileinfo, gd, iconv, intl, json, libxml, mbstring, openssl, pcntl, posix, session, simplexml, xmlreader, xmlwriter, zip, zlib, pgsql, pdo_pgsql - coverage: none - ini-file: development - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Check composer file existence - id: check_composer - uses: andstor/file-existence-action@20b4d2e596410855db8f9ca21e96fbe18e12930b # v2 - with: - files: apps/${{ env.APP_NAME }}/composer.json - - - name: Set up dependencies - # Only run if phpunit config file exists - if: steps.check_composer.outputs.files_exists == 'true' - working-directory: apps/${{ env.APP_NAME }} - run: composer i - - - name: Set up Nextcloud - env: - DB_PORT: 4444 - run: | - mkdir data - ./occ maintenance:install --verbose --database=pgsql --database-name=nextcloud --database-host=127.0.0.1 --database-port=$DB_PORT --database-user=root --database-pass=rootpassword --admin-user admin --admin-pass admin - ./occ app:enable --force ${{ env.APP_NAME }} - - - name: Check PHPUnit script is defined - id: check_phpunit - continue-on-error: true - working-directory: apps/${{ env.APP_NAME }} - run: | - composer run --list | grep "^ test:unit " | wc -l | grep 1 - - - name: PHPUnit - # Only run if phpunit config file exists - if: steps.check_phpunit.outcome == 'success' - working-directory: apps/${{ env.APP_NAME }} - run: composer run test:unit - - - name: Check PHPUnit integration script is defined - id: check_integration - continue-on-error: true - working-directory: apps/${{ env.APP_NAME }} - run: | - composer run --list | grep "^ test:integration " | wc -l | grep 1 - - - name: Run Nextcloud - # Only run if phpunit integration config file exists - if: steps.check_integration.outcome == 'success' - run: php -S localhost:8080 & - - - name: PHPUnit integration - # Only run if phpunit integration config file exists - if: steps.check_integration.outcome == 'success' - working-directory: apps/${{ env.APP_NAME }} - run: composer run test:integration - - - name: Print logs - if: always() - run: | - cat data/nextcloud.log - - - name: Skipped - # Fail the action when neither unit nor integration tests ran - if: steps.check_phpunit.outcome == 'failure' && steps.check_integration.outcome == 'failure' - run: | - echo 'Neither PHPUnit nor PHPUnit integration tests are specified in composer.json scripts' - exit 1 - - summary: - permissions: - contents: none - runs-on: ubuntu-latest - needs: [changes, phpunit-pgsql] - - if: always() - - name: phpunit-pgsql-summary - - steps: - - name: Summary status - run: if ${{ needs.changes.outputs.src != 'false' && needs.phpunit-pgsql.result != 'success' }}; then exit 1; fi diff --git a/.github/workflows/phpunit-sqlite.yml b/.github/workflows/phpunit-sqlite.yml deleted file mode 100644 index 562ba2ba384..00000000000 --- a/.github/workflows/phpunit-sqlite.yml +++ /dev/null @@ -1,160 +0,0 @@ -# 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: PHPUnit sqlite - -on: - pull_request: - schedule: - - cron: "5 2 * * *" - -permissions: - contents: read - -concurrency: - group: phpunit-sqlite-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - changes: - runs-on: ubuntu-latest - - outputs: - src: ${{ steps.changes.outputs.src}} - - steps: - - uses: dorny/paths-filter@4512585405083f25c027a35db413c2b3b9006d50 # v2.11.1 - id: changes - continue-on-error: true - with: - filters: | - src: - - '.github/workflows/**' - - 'appinfo/**' - - 'lib/**' - - 'templates/**' - - 'tests/**' - - 'vendor/**' - - 'vendor-bin/**' - - '.php-cs-fixer.dist.php' - - 'composer.json' - - 'composer.lock' - - phpunit-sqlite: - runs-on: ubuntu-latest - - needs: changes - if: needs.changes.outputs.src != 'false' - - strategy: - matrix: - php-versions: ['8.0'] - server-versions: ['master'] - - steps: - - name: Set app env - run: | - # Split and keep last - echo "APP_NAME=${GITHUB_REPOSITORY##*/}" >> $GITHUB_ENV - - - name: Checkout server - uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 - with: - submodules: true - repository: nextcloud/server - ref: ${{ matrix.server-versions }} - - - name: Checkout app - uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 - with: - path: apps/${{ env.APP_NAME }} - - - name: Set up php ${{ matrix.php-versions }} - uses: shivammathur/setup-php@4bd44f22a98a19e0950cbad5f31095157cc9621b # v2 - with: - php-version: ${{ matrix.php-versions }} - # https://docs.nextcloud.com/server/stable/admin_manual/installation/source_installation.html#prerequisites-for-manual-installation - extensions: bz2, ctype, curl, dom, fileinfo, gd, iconv, intl, json, libxml, mbstring, openssl, pcntl, posix, session, simplexml, xmlreader, xmlwriter, zip, zlib, sqlite, pdo_sqlite - coverage: none - ini-file: development - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Check composer file existence - id: check_composer - uses: andstor/file-existence-action@20b4d2e596410855db8f9ca21e96fbe18e12930b # v2 - with: - files: apps/${{ env.APP_NAME }}/composer.json - - - name: Set up dependencies - # Only run if phpunit config file exists - if: steps.check_composer.outputs.files_exists == 'true' - working-directory: apps/${{ env.APP_NAME }} - run: composer i - - - name: Set up Nextcloud - env: - DB_PORT: 4444 - run: | - mkdir data - ./occ maintenance:install --verbose --database=sqlite --database-name=nextcloud --database-host=127.0.0.1 --database-port=$DB_PORT --database-user=root --database-pass=rootpassword --admin-user admin --admin-pass admin - ./occ app:enable --force ${{ env.APP_NAME }} - - - name: Check PHPUnit script is defined - id: check_phpunit - continue-on-error: true - working-directory: apps/${{ env.APP_NAME }} - run: | - composer run --list | grep "^ test:unit " | wc -l | grep 1 - - - name: PHPUnit - # Only run if phpunit config file exists - if: steps.check_phpunit.outcome == 'success' - working-directory: apps/${{ env.APP_NAME }} - run: composer run test:unit - - - name: Check PHPUnit integration script is defined - id: check_integration - continue-on-error: true - working-directory: apps/${{ env.APP_NAME }} - run: | - composer run --list | grep "^ test:integration " | wc -l | grep 1 - - - name: Run Nextcloud - # Only run if phpunit integration config file exists - if: steps.check_integration.outcome == 'success' - run: php -S localhost:8080 & - - - name: PHPUnit integration - # Only run if phpunit integration config file exists - if: steps.check_integration.outcome == 'success' - working-directory: apps/${{ env.APP_NAME }} - run: composer run test:integration - - - name: Print logs - if: always() - run: | - cat data/nextcloud.log - - - name: Skipped - # Fail the action when neither unit nor integration tests ran - if: steps.check_phpunit.outcome == 'failure' && steps.check_integration.outcome == 'failure' - run: | - echo 'Neither PHPUnit nor PHPUnit integration tests are specified in composer.json scripts' - exit 1 - - summary: - permissions: - contents: none - runs-on: ubuntu-latest - needs: [changes, phpunit-sqlite] - - if: always() - - name: phpunit-sqlite-summary - - steps: - - name: Summary status - run: if ${{ needs.changes.outputs.src != 'false' && needs.phpunit-sqlite.result != 'success' }}; then exit 1; fi diff --git a/.github/workflows/pr-feedback.yml b/.github/workflows/pr-feedback.yml deleted file mode 100644 index d63b5656e9d..00000000000 --- a/.github/workflows/pr-feedback.yml +++ /dev/null @@ -1,29 +0,0 @@ -name: 'Ask for feedback on PRs' -on: - schedule: - - cron: '30 1 * * *' - -jobs: - pr-feedback: - runs-on: ubuntu-22.04 - steps: - - name: The get-github-handles-from-website action - uses: marcelklehr/get-github-handles-from-website-action@a739600f6b91da4957f51db0792697afbb2f143c # v1.0.0 - id: scrape - with: - website: 'https://nextcloud.com/team/' - - uses: marcelklehr/pr-feedback-action@601109aa729eb4c8d6d0ece7567b9d4901db4aef - with: - feedback-message: | - Hello there, - Thank you so much for taking the time and effort to create a pull request to our Nextcloud project. - - We hope that the review process is going smooth and is helpful for you. We want to ensure your pull request is reviewed to your satisfaction. If you have a moment, our community management team would very much appreciate your feedback on your experience with this PR review process. - - Your feedback is valuable to us as we continuously strive to improve our community developer experience. Please take a moment to complete our short survey by clicking on the following link: https://cloud.nextcloud.com/apps/forms/s/i9Ago4EQRZ7TWxjfmeEpPkf6 - - Thank you for contributing to Nextcloud and we hope to hear from you soon! - days-before-feedback: 14 - start-date: "2023-07-10" - exempt-authors: "${{ steps.scrape.outputs.users }}" - exempt-bots: true diff --git a/.github/workflows/psalm.yml b/.github/workflows/psalm.yml deleted file mode 100644 index 5c103a80a52..00000000000 --- a/.github/workflows/psalm.yml +++ /dev/null @@ -1,36 +0,0 @@ -# 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: Static analysis - -on: pull_request - -concurrency: - group: psalm-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - static-analysis: - runs-on: ubuntu-latest - - name: Nextcloud - steps: - - name: Checkout - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - - - name: Set up php - uses: shivammathur/setup-php@c5fc0d8281aba02c7fda07d3a70cc5371548067d # v2 - with: - php-version: 8.1 - coverage: none - ini-file: development - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Install dependencies - run: composer i - - - name: Run coding standards check - run: composer run psalm diff --git a/.github/workflows/update-nextcloud-ocp.yml b/.github/workflows/update-nextcloud-ocp.yml deleted file mode 100644 index 19d0fb69d7b..00000000000 --- a/.github/workflows/update-nextcloud-ocp.yml +++ /dev/null @@ -1,107 +0,0 @@ -# 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: Update nextcloud/ocp - -on: - workflow_dispatch: - schedule: - - cron: "5 2 * * 0" - -jobs: - update-nextcloud-ocp: - runs-on: ubuntu-latest - - strategy: - fail-fast: false - matrix: - branches: ["main", "master", "stable27", "stable26", "stable25"] - - name: update-nextcloud-ocp-${{ matrix.branches }} - - steps: - - uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - with: - ref: ${{ matrix.branches }} - submodules: true - - - name: Set up php8.1 - uses: shivammathur/setup-php@4bd44f22a98a19e0950cbad5f31095157cc9621b # v2 - with: - php-version: 8.1 - # https://docs.nextcloud.com/server/stable/admin_manual/installation/source_installation.html#prerequisites-for-manual-installation - extensions: bz2, ctype, curl, dom, fileinfo, gd, iconv, intl, json, libxml, mbstring, openssl, pcntl, posix, session, simplexml, xmlreader, xmlwriter, zip, zlib, sqlite, pdo_sqlite - coverage: none - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Read codeowners - id: codeowners - run: | - grep '/appinfo/info.xml' .github/CODEOWNERS | awk '{ print "codeowners="$2 }' >> $GITHUB_OUTPUT - continue-on-error: true - - - name: Composer install - run: composer install - - - name: Composer update nextcloud/ocp - id: update_branch - if: matrix.branches != 'main' - run: composer require --dev nextcloud/ocp:dev-${{ matrix.branches }} - - - name: Raise on issue on failure - uses: dacbd/create-issue-action@ba4d1c45cccf9c483f2720cefb40e437f0ee6f7d # v1.2.1 - if: ${{ failure() && steps.update_branch.conclusion == 'failure' }} - with: - token: ${{ secrets.GITHUB_TOKEN }} - title: Failed to update nextcloud/ocp package on branch ${{ matrix.branches }} - body: Please check the output of the GitHub action and manually resolve the issues
${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
${{ steps.codeowners.outputs.codeowners }} - - - name: Composer update nextcloud/ocp - id: update_main - if: matrix.branches == 'main' - run: composer require --dev nextcloud/ocp:dev-master - - - name: Raise on issue on failure - uses: dacbd/create-issue-action@ba4d1c45cccf9c483f2720cefb40e437f0ee6f7d # v1.2.1 - if: ${{ failure() && steps.update_main.conclusion == 'failure' }} - with: - token: ${{ secrets.GITHUB_TOKEN }} - title: Failed to update nextcloud/ocp package on branch ${{ matrix.branches }} - body: Please check the output of the GitHub action and manually resolve the issues
${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
${{ steps.codeowners.outputs.codeowners }} - - - name: Reset checkout 3rdparty - run: | - git clean -f 3rdparty - git checkout 3rdparty - continue-on-error: true - - - name: Reset checkout vendor - run: | - git clean -f vendor - git checkout vendor - continue-on-error: true - - - name: Reset checkout vendor-bin - run: | - git clean -f vendor-bin - git checkout vendor-bin - continue-on-error: true - - - name: Create Pull Request - uses: peter-evans/create-pull-request@153407881ec5c347639a548ade7d8ad1d6740e38 # v3 - with: - token: ${{ secrets.COMMAND_BOT_PAT }} - commit-message: "chore(dev-deps): Bump nextcloud/ocp package" - committer: GitHub - author: nextcloud-command - signoff: true - branch: automated/noid/${{ matrix.branches }}-update-nextcloud-ocp - title: "[${{ matrix.branches }}] Update nextcloud/ocp dependency" - body: | - Auto-generated update of [nextcloud/ocp](https://github.com/nextcloud-deps/ocp/) dependency - labels: | - dependencies - 3. to review From d2896ee843ca4568f194ac93df1de6e7a533a360 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Sat, 18 Nov 2023 19:42:12 +0100 Subject: [PATCH 02/10] dsa Signed-off-by: Joas Schilling --- .../workflows/dependabot-approve-merge.yml | 35 ++++++++++--------- 1 file changed, 18 insertions(+), 17 deletions(-) diff --git a/.github/workflows/dependabot-approve-merge.yml b/.github/workflows/dependabot-approve-merge.yml index 90a957c85bc..ec07788b72c 100644 --- a/.github/workflows/dependabot-approve-merge.yml +++ b/.github/workflows/dependabot-approve-merge.yml @@ -12,25 +12,26 @@ on: - master - stable* -permissions: - contents: read - -concurrency: - group: dependabot-approve-merge-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - jobs: auto-approve-merge: runs-on: ubuntu-latest - permissions: - # for hmarr/auto-approve-action to approve PRs - pull-requests: write steps: - # GitHub actions bot approve - - run: | - echo '${{ github.ref }}' - echo github.ref - echo contains('/nextcloud/vue-', github.ref) - echo contains('/webrtc-adapter-', github.ref) - echo contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), github.ref) + - name: Test ${{ github.ref }} + run: echo '${{ github.ref }}' + - name: Test contains('/nextcloud/vue-', github.ref) + run: echo contains('/nextcloud/vue-', github.ref) + - name: Test contains('/webrtc-adapter-', github.ref) + run: echo contains('/webrtc-adapter-', github.ref) + - name: Test contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), github.ref) + run: echo contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), github.ref) + + - name: JS + uses: actions/github-script@v5 + with: + github-token: ${{secrets.GITHUB_TOKEN}} + script: | + console.log(github.ref) + console.log(contains('/nextcloud/vue-', github.ref)) + console.log(contains('/webrtc-adapter-', github.ref)) + console.log(contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), github.ref)) From 85cfcbc85f87b50f2f0856d318e358c68443692d Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Sat, 18 Nov 2023 19:49:12 +0100 Subject: [PATCH 03/10] fsedfv Signed-off-by: Joas Schilling --- .../{dependabot-approve-merge.yml => debugging.yml} | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) rename .github/workflows/{dependabot-approve-merge.yml => debugging.yml} (90%) diff --git a/.github/workflows/dependabot-approve-merge.yml b/.github/workflows/debugging.yml similarity index 90% rename from .github/workflows/dependabot-approve-merge.yml rename to .github/workflows/debugging.yml index ec07788b72c..9a2e58e8f8a 100644 --- a/.github/workflows/dependabot-approve-merge.yml +++ b/.github/workflows/debugging.yml @@ -3,17 +3,12 @@ # https://github.com/nextcloud/.github # https://docs.github.com/en/actions/learn-github-actions/sharing-workflows-with-your-organization -name: Dependabot +name: debugging -on: - pull_request_target: - branches: - - main - - master - - stable* +on: pull_request jobs: - auto-approve-merge: + debugging: runs-on: ubuntu-latest steps: From 58857a2e67addb444a2a066b64acdd7f5f470821 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Sat, 18 Nov 2023 19:53:06 +0100 Subject: [PATCH 04/10] freg Signed-off-by: Joas Schilling --- .github/workflows/debugging.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.github/workflows/debugging.yml b/.github/workflows/debugging.yml index 9a2e58e8f8a..ac70e245d8e 100644 --- a/.github/workflows/debugging.yml +++ b/.github/workflows/debugging.yml @@ -13,15 +13,23 @@ jobs: steps: - name: Test ${{ github.ref }} + continue-on-error: true run: echo '${{ github.ref }}' + - name: Test ${{ github.ref_name }} + continue-on-error: true + run: echo '${{ github.ref_name }}' - name: Test contains('/nextcloud/vue-', github.ref) + continue-on-error: true run: echo contains('/nextcloud/vue-', github.ref) - name: Test contains('/webrtc-adapter-', github.ref) + continue-on-error: true run: echo contains('/webrtc-adapter-', github.ref) - name: Test contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), github.ref) + continue-on-error: true run: echo contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), github.ref) - name: JS + continue-on-error: true uses: actions/github-script@v5 with: github-token: ${{secrets.GITHUB_TOKEN}} From a1579729c5b533aeb51cbd65c6121986adc82404 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Sat, 18 Nov 2023 20:00:14 +0100 Subject: [PATCH 05/10] fdesfv Signed-off-by: Joas Schilling --- .github/workflows/debugging.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/debugging.yml b/.github/workflows/debugging.yml index ac70e245d8e..16c3ad06c15 100644 --- a/.github/workflows/debugging.yml +++ b/.github/workflows/debugging.yml @@ -12,10 +12,15 @@ jobs: runs-on: ubuntu-latest steps: + - uses: mdecoleman/pr-branch-name2.0.0 + id: vars + with: + repo-token: ${{ secrets.GITHUB_TOKEN }} + - run: echo ${{ steps.vars.outputs.branch }} - name: Test ${{ github.ref }} continue-on-error: true run: echo '${{ github.ref }}' - - name: Test ${{ github.ref_name }} + - name: Test ${{ github.event.pull_request }} continue-on-error: true run: echo '${{ github.ref_name }}' - name: Test contains('/nextcloud/vue-', github.ref) From 7c6d4c4dcf1655111b5bace532d336e0bf2373a7 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Sat, 18 Nov 2023 20:00:59 +0100 Subject: [PATCH 06/10] dfsvf Signed-off-by: Joas Schilling --- .github/workflows/debugging.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/debugging.yml b/.github/workflows/debugging.yml index 16c3ad06c15..44204420425 100644 --- a/.github/workflows/debugging.yml +++ b/.github/workflows/debugging.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - - uses: mdecoleman/pr-branch-name2.0.0 + - uses: mdecoleman/pr-branch-name@2.0.0 id: vars with: repo-token: ${{ secrets.GITHUB_TOKEN }} From 9c00c8b99b2bb53fa614cfdb712af612657c4b21 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Sat, 18 Nov 2023 20:07:46 +0100 Subject: [PATCH 07/10] fsdefv Signed-off-by: Joas Schilling --- .github/workflows/debugging.yml | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/.github/workflows/debugging.yml b/.github/workflows/debugging.yml index 44204420425..b6118145ceb 100644 --- a/.github/workflows/debugging.yml +++ b/.github/workflows/debugging.yml @@ -13,9 +13,26 @@ jobs: steps: - uses: mdecoleman/pr-branch-name@2.0.0 - id: vars + id: branchname with: repo-token: ${{ secrets.GITHUB_TOKEN }} + + - name: Test contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true + if: contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true + run: echo 'contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true' + + - name: Test contains(fromJSON('["/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true + if: contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true + run: echo 'contains(fromJSON('["/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true' + + - name: Test contains(fromJSON('["/nextcloud/vue-"'), steps.branchname.outputs.branch) != true + if: contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true + run: echo 'contains(fromJSON('["/nextcloud/vue-"'), steps.branchname.outputs.branch) != true' + + - name: Test contains('/nextcloud/vue-', steps.branchname.outputs.branch) != true + if: contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true + run: echo 'contains('/nextcloud/vue-', steps.branchname.outputs.branch) != true' + - run: echo ${{ steps.vars.outputs.branch }} - name: Test ${{ github.ref }} continue-on-error: true From 65217e0adacb5f4b7bc7525ab659182a8669c3a1 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Sat, 18 Nov 2023 20:10:19 +0100 Subject: [PATCH 08/10] dsvdsvfsdfcsd Signed-off-by: Joas Schilling --- .github/workflows/debugging.yml | 28 +++++++++++++++++++++------- 1 file changed, 21 insertions(+), 7 deletions(-) diff --git a/.github/workflows/debugging.yml b/.github/workflows/debugging.yml index b6118145ceb..c2e056a03cc 100644 --- a/.github/workflows/debugging.yml +++ b/.github/workflows/debugging.yml @@ -19,19 +19,33 @@ jobs: - name: Test contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true if: contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true - run: echo 'contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true' + continue-on-error: true + run: echo '"/nextcloud/vue-", "/webrtc-adapter-"' - name: Test contains(fromJSON('["/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true - if: contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true - run: echo 'contains(fromJSON('["/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true' + if: contains(fromJSON('["/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true + continue-on-error: true + run: echo '"/webrtc-adapter-"' - name: Test contains(fromJSON('["/nextcloud/vue-"'), steps.branchname.outputs.branch) != true - if: contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true - run: echo 'contains(fromJSON('["/nextcloud/vue-"'), steps.branchname.outputs.branch) != true' + if: contains(fromJSON('["/nextcloud/vue-"'), steps.branchname.outputs.branch) != true + continue-on-error: true + run: echo '"/nextcloud/vue-"' - name: Test contains('/nextcloud/vue-', steps.branchname.outputs.branch) != true - if: contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true - run: echo 'contains('/nextcloud/vue-', steps.branchname.outputs.branch) != true' + if: contains('/nextcloud/vue-', steps.branchname.outputs.branch) != true + continue-on-error: true + run: echo '/nextcloud/vue-' + + - name: Test contains('/webrtc-adapter-', steps.branchname.outputs.branch) != true + if: contains('/webrtc-adapter-', steps.branchname.outputs.branch) != true + continue-on-error: true + run: echo '/webrtc-adapter-' + + - name: Test contains('/webrtc-adapter-', steps.branchname.outputs.branch) != contains('/nextcloud/vue-', steps.branchname.outputs.branch) + if: contains('/webrtc-adapter-', steps.branchname.outputs.branch) != contains('/nextcloud/vue-', steps.branchname.outputs.branch) + continue-on-error: true + run: echo '/nextcloud/vue- != /webrtc-adapter-' - run: echo ${{ steps.vars.outputs.branch }} - name: Test ${{ github.ref }} From 689c12081fd3b2480b182d81fcc2de576b3fc8a7 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Sat, 18 Nov 2023 20:14:18 +0100 Subject: [PATCH 09/10] dfvdfv Signed-off-by: Joas Schilling --- .github/workflows/debugging.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/debugging.yml b/.github/workflows/debugging.yml index c2e056a03cc..b7efbc8ef47 100644 --- a/.github/workflows/debugging.yml +++ b/.github/workflows/debugging.yml @@ -28,7 +28,7 @@ jobs: run: echo '"/webrtc-adapter-"' - name: Test contains(fromJSON('["/nextcloud/vue-"'), steps.branchname.outputs.branch) != true - if: contains(fromJSON('["/nextcloud/vue-"'), steps.branchname.outputs.branch) != true + if: contains(fromJSON('["/nextcloud/vue-"]'), steps.branchname.outputs.branch) != true continue-on-error: true run: echo '"/nextcloud/vue-"' From 88a9d30142f2beb2785d268bf9bdec10ae420935 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Sat, 18 Nov 2023 20:19:38 +0100 Subject: [PATCH 10/10] fasd Signed-off-by: Joas Schilling --- .github/workflows/debugging.yml | 27 ++++----------------------- 1 file changed, 4 insertions(+), 23 deletions(-) diff --git a/.github/workflows/debugging.yml b/.github/workflows/debugging.yml index b7efbc8ef47..4042c399878 100644 --- a/.github/workflows/debugging.yml +++ b/.github/workflows/debugging.yml @@ -17,35 +17,16 @@ jobs: with: repo-token: ${{ secrets.GITHUB_TOKEN }} - - name: Test contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true - if: contains(fromJSON('["/nextcloud/vue-", "/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true - continue-on-error: true - run: echo '"/nextcloud/vue-", "/webrtc-adapter-"' - - - name: Test contains(fromJSON('["/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true - if: contains(fromJSON('["/webrtc-adapter-"]'), steps.branchname.outputs.branch) != true + - name: Test contains(steps.branchname.outputs.branch, '/webrtc-adapter-') != true + if: contains(steps.branchname.outputs.branch, '/webrtc-adapter-') != true continue-on-error: true run: echo '"/webrtc-adapter-"' - - name: Test contains(fromJSON('["/nextcloud/vue-"'), steps.branchname.outputs.branch) != true - if: contains(fromJSON('["/nextcloud/vue-"]'), steps.branchname.outputs.branch) != true + - name: Test contains(steps.branchname.outputs.branch, '/nextcloud/vue-') != true + if: contains(steps.branchname.outputs.branch, '/nextcloud/vue-') != true continue-on-error: true run: echo '"/nextcloud/vue-"' - - name: Test contains('/nextcloud/vue-', steps.branchname.outputs.branch) != true - if: contains('/nextcloud/vue-', steps.branchname.outputs.branch) != true - continue-on-error: true - run: echo '/nextcloud/vue-' - - - name: Test contains('/webrtc-adapter-', steps.branchname.outputs.branch) != true - if: contains('/webrtc-adapter-', steps.branchname.outputs.branch) != true - continue-on-error: true - run: echo '/webrtc-adapter-' - - - name: Test contains('/webrtc-adapter-', steps.branchname.outputs.branch) != contains('/nextcloud/vue-', steps.branchname.outputs.branch) - if: contains('/webrtc-adapter-', steps.branchname.outputs.branch) != contains('/nextcloud/vue-', steps.branchname.outputs.branch) - continue-on-error: true - run: echo '/nextcloud/vue- != /webrtc-adapter-' - run: echo ${{ steps.vars.outputs.branch }} - name: Test ${{ github.ref }}