Skip to content

Commit ae907c8

Browse files
authored
3.0.1 (#14)
1 parent 5f3a8f2 commit ae907c8

File tree

4 files changed

+77
-4
lines changed

4 files changed

+77
-4
lines changed

.github/workflows/package.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: 'Package'
2+
3+
on:
4+
pull_request:
5+
6+
jobs:
7+
package:
8+
name: 'Package'
9+
runs-on: 'ubuntu-24.04'
10+
steps:
11+
- name: 'Check out repository'
12+
uses: 'actions/checkout@v4'
13+
with:
14+
path: 'ext'
15+
16+
- name: 'Install dependencies'
17+
run: 'sudo apt-get -y install php-dev'
18+
19+
- name: 'Package and verify package'
20+
run: './ext/.github/workflows/package/package.sh'
21+
22+
- name: 'Archive package'
23+
uses: 'actions/upload-artifact@v4'
24+
with:
25+
path: 'ext/inotify.tgz'
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
#!/bin/sh
2+
3+
set -e
4+
5+
cd ext
6+
7+
echo "Checking version consistency"
8+
9+
CODE_VERSION="$(grep PHP_INOTIFY_VERSION php_inotify.h|cut -d'"' -f2)"
10+
PACKAGE_VERSION="$(grep -m 1 '<release>' package.xml|cut -d'>' -f2|cut -d'<' -f1)"
11+
12+
if ! [ "$CODE_VERSION" = "$PACKAGE_VERSION" ]; then
13+
printf "Version in php_inotify.h does not match version in package.xml: '%s' vs '%s'" "$CODE_VERSION" "$PACKAGE_VERSION" >&2
14+
exit 1
15+
fi
16+
17+
echo "Packaging"
18+
19+
pecl package
20+
21+
echo "Installing package.xml"
22+
23+
mv "./inotify-$PACKAGE_VERSION.tgz" inotify.tgz
24+
sudo pecl install ./inotify.tgz
25+
26+
echo "Checking that all test files was included"
27+
28+
sudo pecl list-files inotify|grep ^test|sed 's@.*/tests/@@'|sort > installed-test-files
29+
find tests/ -type f|sed 's@^tests/@@'|sort > repository-test-files
30+
31+
if ! diff -u repository-test-files installed-test-files; then
32+
echo "Some test files are missing from package.xml (see diff above)" >&2
33+
exit 1
34+
fi

package.xml

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,17 +10,20 @@
1010
<email>[email protected]</email>
1111
<active>yes</active>
1212
</lead>
13-
<date>2020-12-18</date>
13+
<date>2025-02-24</date>
1414
<time>14:00:00</time>
1515
<!--
1616
Remember to change PHP_INOTIFY_VERSION in php_inotify.h
1717
Before release
1818
-->
19-
<version><release>3.0.0</release><api>0.1.2</api></version>
19+
<version>
20+
<release>3.0.1</release>
21+
<api>0.1.2</api>
22+
</version>
2023
<stability><release>stable</release><api>stable</api></stability>
2124
<license uri="http://www.php.net/license">PHP License</license>
2225
<notes>
23-
* PHP 8 compatible release
26+
* Add support for PIE
2427
</notes>
2528
<contents>
2629
<dir name="/">
@@ -35,6 +38,7 @@
3538
<file name="tail.php" role="php" />
3639
<dir name="tests">
3740
<file name="002.phpt" role="test" />
41+
<file name="003.phpt" role="test" />
3842
</dir>
3943
</dir>
4044
</contents>
@@ -55,6 +59,16 @@
5559
<extsrcrelease />
5660

5761
<changelog>
62+
<release>
63+
<date>2020-12-18</date>
64+
<time>14:00:00</time>
65+
<version><release>3.0.0</release><api>0.1.2</api></version>
66+
<stability><release>stable</release><api>stable</api></stability>
67+
<license uri="http://www.php.net/license">PHP License</license>
68+
<notes>
69+
* PHP 8 compatible release
70+
</notes>
71+
</release>
5872
<release>
5973
<date>2016-01-30</date>
6074
<time>14:00:00</time>

php_inotify.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ PHP_FUNCTION(inotify_rm_watch);
4040
PHP_FUNCTION(inotify_queue_len);
4141
PHP_FUNCTION(inotify_read);
4242

43-
#define PHP_INOTIFY_VERSION "3.0.0"
43+
#define PHP_INOTIFY_VERSION "3.0.1"
4444

4545
#define INOTIFY_BUF_TOO_SMALL(ret,errno) \
4646
((ret) == 0 || ((ret) == -1 && (errno) == EINVAL))

0 commit comments

Comments
 (0)