Skip to content

feat(conversation) - add Note to self conversation #244

feat(conversation) - add Note to self conversation

feat(conversation) - add Note to self conversation #244

# 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 summary
on:
pull_request:
paths-ignore:
- '.github/workflows/**'
- 'appinfo/**'
- 'lib/**'
- 'templates/**'
- 'tests/integration/**'
- 'vendor/**'
- 'vendor-bin/**'
- '.php-cs-fixer.dist.php'
- 'composer.json'
- 'composer.lock'
env:
PATHS_IGNORE: '.github/workflows/**;appinfo/**;lib/**;templates/**;tests/integration/**;vendor/**;vendor-bin/**;.php-cs-fixer.dist.php;composer.json;composer.lock'
permissions:
contents: read
jobs:
action-no-summary:
permissions:
contents: none
runs-on: ubuntu-latest
name: action-not-src
outputs:
found_file: ${{ steps.confirm-negative-list.outputs.result }}
steps:
- uses: actions/checkout@v3
with:
fetch-depth: ${{ github.event_name == 'pull_request' && 2 || 0 }}
- name: Get changed files from diff
id: changed-files
run: |
if ${{ github.event_name == 'pull_request' }}; then
echo "changed_files=$(git diff --name-only -r HEAD^1 HEAD | xargs)" >> $GITHUB_OUTPUT
else
echo "changed_files=$(git diff --name-only ${{ github.event.before }} ${{ github.event.after }} | xargs)" >> $GITHUB_OUTPUT
fi
- name: Set up node 20
uses: actions/setup-node@e33196f7422957bea03ed53f6fbb155025ffc7b8 # v3
with:
node-version: 20
- name: Install minimatch
run: npm i minimatch
- name: Check if a file is in paths-ignored
id: confirm-negative-list
uses: actions/github-script@v5
with:
github-token: ${{secrets.GITHUB_TOKEN}}
result-encoding: string
script: |
const { minimatch } = require('minimatch')
const changedPaths = "${{ steps.changed-files.outputs.changed_files }}".split(' ')
let matched = ''
process.env.PATHS_IGNORE.split(';').every(pattern => {
changedPaths.every(path => {
console.info('Testing ' + path + ' for pattern ' + pattern)
if (minimatch(path, pattern)) {
console.info(path + ' matched, aborting "unrelated summary"')
matched = '1'
return false
}
return true
})
return !matched
})
return matched
summary-mysql:
permissions:
contents: none
runs-on: ubuntu-latest
needs: action-no-summary
name: integration-mysql-summary
if: needs.action-no-summary.outputs.found_file == ''
steps:
- name: Summary status
run: 'echo "No PHP files changed, skipped Integration tests"'
summary-oci:
permissions:
contents: none
runs-on: ubuntu-latest
needs: action-no-summary
name: integration-oci-summary
if: needs.action-no-summary.outputs.found_file == ''
steps:
- name: Summary status
run: 'echo "No PHP files changed, skipped Integration tests"'
summary-pgsql:
permissions:
contents: none
runs-on: ubuntu-latest
needs: action-no-summary
name: integration-pgsql-summary
if: needs.action-no-summary.outputs.found_file == ''
steps:
- name: Summary status
run: 'echo "No PHP files changed, skipped Integration tests"'
summary-sqlite:
permissions:
contents: none
runs-on: ubuntu-latest
needs: action-no-summary
name: integration-sqlite-summary
if: needs.action-no-summary.outputs.found_file == ''
steps:
- name: Summary status
run: 'echo "No PHP files changed, skipped Integration tests"'