From 974cdcc40155edbafcf92842a03592b348c9db7c Mon Sep 17 00:00:00 2001
From: Florian Engelhardt <flo@dotbox.org>
Date: Wed, 27 Nov 2024 16:26:56 +0100
Subject: [PATCH 1/5] PHP 8.4 checks in CI

---
 .github/workflows/ci.yml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index c15576a..fdd8a39 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -53,7 +53,7 @@ jobs:
   Tests:
     strategy:
       matrix:
-        php-versions: ['8.0', '8.1', '8.2', '8.3']
+        php-versions: ['8.0', '8.1', '8.2', '8.3', '8.4']
     runs-on: ubuntu-latest
     steps:
       - name: Checkout

From 136ec6d8a05c9107decd5a58b1ce300c05dcdd47 Mon Sep 17 00:00:00 2001
From: Florian Engelhardt <flo@dotbox.org>
Date: Wed, 27 Nov 2024 16:37:43 +0100
Subject: [PATCH 2/5] remove psalm

---
 .github/workflows/ci.yml |  3 ---
 CHANGELOG.md             |  8 ++++++
 composer.json            |  5 +---
 psalm.xml                | 58 ----------------------------------------
 src/InotifyStream.php    |  4 ---
 5 files changed, 9 insertions(+), 69 deletions(-)
 delete mode 100644 psalm.xml

diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index fdd8a39..286248c 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -47,9 +47,6 @@ jobs:
       - name: Static Analyzer (PHPStan)
         run: composer test:phpstan
 
-      - name: Static Analyzer (Psalm)
-        run: composer test:psalm
-
   Tests:
     strategy:
       matrix:
diff --git a/CHANGELOG.md b/CHANGELOG.md
index dc3a8e3..7ff19ca 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -4,6 +4,14 @@ All notable changes to this project will be documented in this file.
 The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
 and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
 
+## [2.1.0] - 2024-11-27
+
+### Added
+- Support for PHP 8.4
+
+### Removed
+- Psalm
+
 ## [2.0.0] - 2022-01-06
 
 ### Added
diff --git a/composer.json b/composer.json
index 55697b6..cdb1b93 100644
--- a/composer.json
+++ b/composer.json
@@ -12,8 +12,7 @@
     "require-dev": {
         "phpunit/phpunit": "^8.5|^9.5",
         "phpstan/phpstan": "^1.0.0",
-        "infection/infection": "<1.0",
-        "vimeo/psalm": "^5.0"
+        "infection/infection": "<1.0"
     },
     "autoload": {
         "psr-4": {
@@ -29,7 +28,6 @@
         "fix": "./tools/php-cs-fixer.phar fix",
         "test:lint": "./tools/php-cs-fixer.phar fix --dry-run",
         "test:phpstan": "phpstan analyse --level max examples/ src/",
-        "test:psalm": "psalm src/ examples/",
         "test:unit": [
             "@putenv XDEBUG_MODE=coverage",
             "phpunit"
@@ -41,7 +39,6 @@
         "test": [
             "@test:lint",
             "@test:phpstan",
-            "@test:psalm",
             "@test:unit",
             "@test:mutation"
         ]
diff --git a/psalm.xml b/psalm.xml
deleted file mode 100644
index 74be332..0000000
--- a/psalm.xml
+++ /dev/null
@@ -1,58 +0,0 @@
-<?xml version="1.0"?>
-<psalm
-    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-    xmlns="https://getpsalm.org/schema/config"
-    xsi:schemaLocation="https://getpsalm.org/schema/config vendor/vimeo/psalm/config.xsd"
->
-    <projectFiles>
-        <directory name="src" />
-        <directory name="tests" />
-        <directory name="examples" />
-        <ignoreFiles>
-            <directory name="vendor" />
-        </ignoreFiles>
-    </projectFiles>
-
-    <stubs>
-        <file name="stubs/inotify.phpstub"/>
-    </stubs>
-
-    <issueHandlers>
-        <LessSpecificReturnType errorLevel="info" />
-
-        <!-- level 3 issues - slightly lazy code writing, but provably low false-negatives -->
-
-        <DeprecatedMethod errorLevel="info" />
-        <DeprecatedProperty errorLevel="info" />
-        <DeprecatedClass errorLevel="info" />
-        <DeprecatedConstant errorLevel="info" />
-        <DeprecatedFunction errorLevel="info" />
-        <DeprecatedInterface errorLevel="info" />
-        <DeprecatedTrait errorLevel="info" />
-
-        <InternalMethod errorLevel="info" />
-        <InternalProperty errorLevel="info" />
-        <InternalClass errorLevel="info" />
-
-        <MissingClosureReturnType errorLevel="info" />
-        <MissingReturnType errorLevel="info" />
-        <MissingPropertyType errorLevel="info" />
-        <InvalidDocblock errorLevel="info" />
-
-        <PropertyNotSetInConstructor errorLevel="info" />
-        <MissingConstructor errorLevel="info" />
-        <MissingClosureParamType errorLevel="info" />
-        <MissingParamType errorLevel="info" />
-
-        <RedundantCondition errorLevel="info" />
-
-        <DocblockTypeContradiction errorLevel="info" />
-        <RedundantConditionGivenDocblockType errorLevel="info" />
-
-        <UnresolvableInclude errorLevel="info" />
-
-        <RawObjectIteration errorLevel="info" />
-
-        <InvalidStringClass errorLevel="info" />
-    </issueHandlers>
-</psalm>
diff --git a/src/InotifyStream.php b/src/InotifyStream.php
index 934432c..e8e5b7f 100644
--- a/src/InotifyStream.php
+++ b/src/InotifyStream.php
@@ -38,10 +38,6 @@ final class InotifyStream extends EventEmitter
      */
     private $watchers = [];
 
-    /**
-     * @psalm-suppress RedundantConditionGivenDocblockType
-     * @psalm-suppress DocblockTypeContradiction
-     */
     public function __construct(?LoopInterface $loop = null)
     {
         $inotify = inotify_init();

From b4ab119d0c2e97768c88933266d0f4e0b6aaf00f Mon Sep 17 00:00:00 2001
From: Florian Engelhardt <flo@dotbox.org>
Date: Wed, 27 Nov 2024 16:39:06 +0100
Subject: [PATCH 3/5] cleanup runs

---
 .github/workflows/ci.yml | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 286248c..75c4f7e 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -1,6 +1,8 @@
 on:
-  - pull_request
-  - push
+  pull_request: null
+  push:
+    branches:
+      - master
 
 name: CI
 

From 9eb3bcb1980a8a1e33b0626fde38710f280734c9 Mon Sep 17 00:00:00 2001
From: Florian Engelhardt <flo@dotbox.org>
Date: Wed, 27 Nov 2024 16:41:21 +0100
Subject: [PATCH 4/5] fix GitHub action warnings

---
 .github/workflows/ci.yml | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 75c4f7e..b468350 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -14,7 +14,7 @@ jobs:
     runs-on: ubuntu-latest
     steps:
       - name: Checkout
-        uses: actions/checkout@v2
+        uses: actions/checkout@v4
 
       - name: Validate composer.json and composer.lock
         run: composer validate
@@ -33,7 +33,7 @@ jobs:
         run: echo "::set-output name=dir::$(composer config cache-files-dir)"
 
       - name: Cache dependencies
-        uses: actions/cache@v2
+        uses: actions/cache@v4
         with:
           path: ${{ steps.composer-cache.outputs.dir }}
           key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
@@ -56,7 +56,7 @@ jobs:
     runs-on: ubuntu-latest
     steps:
       - name: Checkout
-        uses: actions/checkout@v2
+        uses: actions/checkout@v4
 
       - name: Validate composer.json and composer.lock
         run: composer validate
@@ -75,7 +75,7 @@ jobs:
         run: echo "::set-output name=dir::$(composer config cache-files-dir)"
 
       - name: Cache dependencies
-        uses: actions/cache@v2
+        uses: actions/cache@v4
         with:
           path: ${{ steps.composer-cache.outputs.dir }}
           key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}

From 698ec9a378b05d9fade663c261e3cfe3a019f067 Mon Sep 17 00:00:00 2001
From: Florian Engelhardt <flo@dotbox.org>
Date: Wed, 27 Nov 2024 16:45:11 +0100
Subject: [PATCH 5/5] fix changelog

---
 CHANGELOG.md | 15 ++++++++++++++-
 1 file changed, 14 insertions(+), 1 deletion(-)

diff --git a/CHANGELOG.md b/CHANGELOG.md
index 7ff19ca..31e9c6d 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -4,7 +4,7 @@ All notable changes to this project will be documented in this file.
 The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
 and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
 
-## [2.1.0] - 2024-11-27
+## [2.2.0] - 2024-11-27
 
 ### Added
 - Support for PHP 8.4
@@ -12,6 +12,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
 ### Removed
 - Psalm
 
+## [2.1.0] - 2023-09-23
+
+# Added
+
+- Support PHP 8.2 (#3, thanks @devnix)
+- More specific return type for `Flowcontrol\React\Inotify\InotifyStream::addWatch` (#4, thanks @devnix)
+
+# Fixed
+
+- GitHub Action Badge in `README.md`
+
 ## [2.0.0] - 2022-01-06
 
 ### Added
@@ -67,6 +78,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
 - unit tests
 - static code analysis using Pslam and PHPStan
 
+[2.2.0]: https://github.com/flow-control/react-inotify/compare/v2.1.0...v2.2.0
+[2.1.0]: https://github.com/flow-control/react-inotify/compare/v2.0.0...v2.1.0
 [2.0.0]: https://github.com/flow-control/react-inotify/compare/v1.1.1...v2.0.0
 [1.1.1]: https://github.com/flow-control/react-inotify/compare/v1.1.0...v1.1.1
 [1.1.0]: https://github.com/flow-control/react-inotify/compare/v1.0.2...v1.1.0