From cf6fae5a2fccbcdf841fea7b8fccaf1b646638d2 Mon Sep 17 00:00:00 2001 From: Eric Lippmann Date: Tue, 24 Mar 2026 09:03:42 +0100 Subject: [PATCH 1/4] Run CI on support branches, all PRs, and on demand Potential bugfix releases for maintained older versions should receive the same PHP checks as the default branch. Extend push builds to also cover \`support/*\` and drop the pull request target filter so validation still runs for pull requests merged through other pull requests. Enable \`workflow_dispatch\` for ad-hoc verification. --- .github/workflows/php.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/php.yml b/.github/workflows/php.yml index 22bfa1e..137caa3 100644 --- a/.github/workflows/php.yml +++ b/.github/workflows/php.yml @@ -4,9 +4,9 @@ on: push: branches: - main + - support/* pull_request: - branches: - - main + workflow_dispatch: jobs: php: From 5abbd540cd0df5f94c83336bd8787b07d5e0efdf Mon Sep 17 00:00:00 2001 From: Eric Lippmann Date: Tue, 24 Mar 2026 09:15:17 +0100 Subject: [PATCH 2/4] Normalize `composer.json` and enable sorted package lists Enable Composer's `sort-packages` setting and run `composer normalize` to establish a consistent structure for `composer.json`. This keeps future dependency changes deterministic and reduces unnecessary diff noise. --- composer.json | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/composer.json b/composer.json index 5348316..1522780 100644 --- a/composer.json +++ b/composer.json @@ -1,8 +1,8 @@ { "name": "ipl/orm", - "type": "library", "description": "Icinga PHP Library - ORM", "license": "MIT", + "type": "library", "keywords": [ "sql", "database", @@ -15,19 +15,22 @@ "ipl/sql": ">=0.9.1", "ipl/stdlib": ">=0.15.0" }, - "autoload": { - "psr-4": { - "ipl\\Orm\\": "src" - } - }, "require-dev": { "ext-pdo_sqlite": "*", "ipl/sql": "dev-main", "ipl/stdlib": "dev-main" }, + "autoload": { + "psr-4": { + "ipl\\Orm\\": "src" + } + }, "autoload-dev": { "psr-4": { "ipl\\Tests\\Orm\\": "tests" } + }, + "config": { + "sort-packages": true } } From 25b99beac04d27bba19ec003dd874a2e4397f5f4 Mon Sep 17 00:00:00 2001 From: Eric Lippmann Date: Tue, 24 Mar 2026 09:28:55 +0100 Subject: [PATCH 3/4] Keep `git archive` outputs free of repository-only files Add a minimal `.gitattributes` file so `git archive` excludes CI and Git configuration files as well as test-related files. This keeps release archives focused on the package contents. --- .gitattributes | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 .gitattributes diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..d8bac3e --- /dev/null +++ b/.gitattributes @@ -0,0 +1,6 @@ +# Exclude Git and CI configuration files from archives. +.git* export-ignore + +# Exclude test-related files from archives. +tests/ export-ignore +phpstan* export-ignore From 053da82044283f258be9442528702708622de004 Mon Sep 17 00:00:00 2001 From: Eric Lippmann Date: Tue, 24 Mar 2026 09:41:23 +0100 Subject: [PATCH 4/4] Clean up `.gitignore` to only cover project-specific artifacts Remove the broad hidden file exclusion and its `.git*` whitelist in favor of a global `~/.gitignore`. Editor and OS artifacts such as `.DS_Store`, `.idea/`, or `.vscode/` are environment-specific and not the project's responsibility to exclude. Each developer should maintain a global ignore file for such artifacts: git config --global core.excludesFile ~/.gitignore Keep only Composer installation artifacts with a comment clarifying why `composer.lock` is excluded for library projects. --- .gitignore | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/.gitignore b/.gitignore index 34d585a..681b17e 100644 --- a/.gitignore +++ b/.gitignore @@ -1,9 +1,5 @@ -# Exclude all hidden files -.* - -# Except those related to Git (and GitHub) -!.git* - -# Exclude files from composer install -vendor/ +# Ignore Composer installation artifacts; composer.lock is intentionally +# excluded as this is a library - applications depending on this package +# manage their own lock file. +/vendor/ composer.lock