Skip to content

Commit cf43310

Browse files
authored
Merge pull request #8062 from codeigniter4/develop
4.4.2 Ready code
2 parents c668faf + 47b3460 commit cf43310

File tree

239 files changed

+4920
-1123
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

239 files changed

+4920
-1123
lines changed

.gitattributes

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
admin/ export-ignore
1313
contributing/ export-ignore
1414
.editorconfig export-ignore
15-
.nojekyll export-ignore export-ignore
15+
.nojekyll export-ignore
1616
CODE_OF_CONDUCT.md export-ignore
1717
CONTRIBUTING.md export-ignore
1818

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
name: Auto Label "stale" for All PRs
2+
3+
on:
4+
push:
5+
branches:
6+
- develop
7+
- '4.*'
8+
9+
jobs:
10+
build:
11+
name: Check Conflicts
12+
13+
permissions:
14+
contents: read
15+
pull-requests: write
16+
17+
runs-on: ubuntu-22.04
18+
steps:
19+
- name: Checkout
20+
uses: actions/checkout@v4
21+
22+
- name: Get PR List
23+
id: PR-list
24+
run: echo "pr_list=$(gh pr list -L 100 --json mergeable,url,labels,author)" >> $GITHUB_OUTPUT
25+
env:
26+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
27+
28+
- name: 'Add label "stale" and comment'
29+
env:
30+
PR_LIST: ${{ steps.PR-list.outputs.pr_list }}
31+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
32+
run: |
33+
34+
IFS=$'\n' # Set Internal Field Separator to newline to handle array elements
35+
36+
# Iterate through the PRs in PR_LIST
37+
for pr in $(echo "$PR_LIST" | jq -c '.[]'); do
38+
mergeable=$(echo "$pr" | jq -r '.mergeable')
39+
author=$(echo "$pr" | jq -r '.author.login')
40+
labels=$(echo "$pr" | jq -c '.labels[].name' | tr -d '[]"')
41+
url=$(echo "$pr" | jq -r '.url')
42+
43+
# CONFLICTING and no 'stale' label
44+
if [ "$mergeable" == "CONFLICTING" ] && [[ ! "$labels" == *"stale"* ]]; then
45+
# Add "stale" label
46+
gh pr edit $url --add-label "stale"
47+
48+
# Add a comment
49+
gh pr comment $url --body ":wave: Hi, @$author!<br><br>We detected conflicts in your PR against the base branch :speak_no_evil:<br>You may want to sync :arrows_counterclockwise: your branch with upstream!<br><br>Ref: [Syncing Your Branch](https://github.com/codeigniter4/CodeIgniter4/blob/develop/contributing/workflow.md#pushing-your-branch)"
50+
fi
51+
done

.github/workflows/label-signing.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Check Signed PR
2+
on:
3+
pull_request:
4+
branches:
5+
- 'develop'
6+
- '4.*'
7+
8+
concurrency:
9+
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
10+
cancel-in-progress: true
11+
12+
permissions:
13+
contents: read
14+
pull-requests: write
15+
16+
jobs:
17+
build:
18+
name: Check Signed Commit
19+
runs-on: ubuntu-latest
20+
steps:
21+
- name: Checkout
22+
uses: actions/checkout@v4
23+
24+
- name: Check signed commits in PR
25+
uses: 1Password/check-signed-commits-action@v1
26+
with:
27+
comment: |
28+
You must GPG-sign your work, certifying that you either wrote the work or otherwise have the right to pass it on to an open-source project. See Developer's Certificate of Origin. See [signing][1].
29+
30+
**Note that all your commits must be signed.** If you have an unsigned commit, you can sign the previous commits by referring to [gpg-signing-old-commits][2].
31+
[1]: https://github.com/codeigniter4/CodeIgniter4/blob/develop/contributing/pull_request.md#signing
32+
[2]: https://github.com/codeigniter4/CodeIgniter4/blob/develop/contributing/workflow.md#gpg-signing-old-commits

.github/workflows/reusable-coveralls.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,10 @@ jobs:
5757
run: composer update --ansi
5858

5959
- name: Merge coverage files
60-
run: vendor/bin/phpcov merge --clover build/logs/clover.xml build/cov
60+
run: |
61+
jq '.autoload."psr-4" += {"Config\\": "app/Config/"}' composer.json > temp.json && mv temp.json composer.json
62+
composer dump-autoload
63+
vendor/bin/phpcov merge --clover build/logs/clover.xml build/cov
6164
6265
- name: Upload coverage to Coveralls
6366
run: vendor/bin/php-coveralls --verbose --exclude-no-stmt --ansi

.github/workflows/test-phpunit.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,10 @@ jobs:
5959
- '8.0'
6060
- '8.1'
6161
- '8.2'
62+
- '8.3'
63+
include:
64+
- php-version: '8.3'
65+
composer-option: '--ignore-platform-req=php'
6266

6367
uses: ./.github/workflows/reusable-phpunit-test.yml # @TODO Extract to codeigniter4/.github repo
6468
with:
@@ -70,6 +74,7 @@ jobs:
7074
enable-coverage: ${{ matrix.php-version == needs.coverage-php-version.outputs.version }}
7175
enable-profiling: ${{ matrix.php-version == needs.coverage-php-version.outputs.version }}
7276
extra-extensions: imagick, redis, memcached
77+
extra-composer-options: ${{ matrix.composer-option }}
7378

7479
database-live-tests:
7580
needs:
@@ -84,6 +89,7 @@ jobs:
8489
- '8.0'
8590
- '8.1'
8691
- '8.2'
92+
- '8.3'
8793
db-platform:
8894
- MySQLi
8995
- OCI8
@@ -96,6 +102,8 @@ jobs:
96102
- php-version: '7.4'
97103
db-platform: MySQLi
98104
mysql-version: '8.0'
105+
- php-version: '8.3'
106+
composer-option: '--ignore-platform-req=php'
99107

100108
uses: ./.github/workflows/reusable-phpunit-test.yml # @TODO Extract to codeigniter4/.github repo
101109
with:
@@ -109,6 +117,7 @@ jobs:
109117
enable-coverage: ${{ matrix.php-version == needs.coverage-php-version.outputs.version }}
110118
enable-profiling: ${{ matrix.php-version == needs.coverage-php-version.outputs.version }}
111119
extra-extensions: mysqli, oci8, pgsql, sqlsrv-5.10.1, sqlite3
120+
extra-composer-options: ${{ matrix.composer-option }}
112121

113122
separate-process-tests:
114123
needs:
@@ -122,6 +131,10 @@ jobs:
122131
- '8.0'
123132
- '8.1'
124133
- '8.2'
134+
- '8.3'
135+
include:
136+
- php-version: '8.3'
137+
composer-option: '--ignore-platform-req=php'
125138

126139
uses: ./.github/workflows/reusable-phpunit-test.yml # @TODO Extract to codeigniter4/.github repo
127140
with:
@@ -133,6 +146,7 @@ jobs:
133146
enable-coverage: true # needs xdebug for assertHeaderEmitted() tests
134147
enable-profiling: ${{ matrix.php-version == needs.coverage-php-version.outputs.version }}
135148
extra-extensions: mysqli, oci8, pgsql, sqlsrv-5.10.1, sqlite3
149+
extra-composer-options: ${{ matrix.composer-option }}
136150

137151
cache-live-tests:
138152
needs:
@@ -146,6 +160,10 @@ jobs:
146160
- '8.0'
147161
- '8.1'
148162
- '8.2'
163+
- '8.3'
164+
include:
165+
- php-version: '8.3'
166+
composer-option: '--ignore-platform-req=php'
149167

150168
uses: ./.github/workflows/reusable-phpunit-test.yml # @TODO Extract to codeigniter4/.github repo
151169
with:
@@ -157,6 +175,7 @@ jobs:
157175
enable-coverage: ${{ matrix.php-version == needs.coverage-php-version.outputs.version }}
158176
enable-profiling: ${{ matrix.php-version == needs.coverage-php-version.outputs.version }}
159177
extra-extensions: redis, memcached
178+
extra-composer-options: ${{ matrix.composer-option }}
160179

161180
coveralls:
162181
name: Upload coverage results to Coveralls

0 commit comments

Comments
 (0)