From 9037fe7fc32ecdfdcc6fd01fdcebb3c86f9c67d0 Mon Sep 17 00:00:00 2001 From: Stanislas Kita Date: Tue, 28 Apr 2026 16:06:18 +0200 Subject: [PATCH 1/3] Fix(Core): Prevent error whit mising tools folder with official release --- CHANGELOG.md | 5 +++++ inc/migration.class.php | 4 +--- {tools => resources}/pmv.json | 0 3 files changed, 6 insertions(+), 3 deletions(-) rename {tools => resources}/pmv.json (100%) diff --git a/CHANGELOG.md b/CHANGELOG.md index ffecb02..708b459 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,7 +1,12 @@ # Jamf Plugin for GLPI Changelog + +## [UNRELEASED] + ## [3.2.0] - 2026-04-23 +- Fix failed to open stream: No such file or directory (`jamf/tools/pmv.json`) + ### Added - GLPI 11 compatibility diff --git a/inc/migration.class.php b/inc/migration.class.php index c3228c0..371b9bd 100644 --- a/inc/migration.class.php +++ b/inc/migration.class.php @@ -618,9 +618,7 @@ public function apply_3_0_0_migration(): void // Copy default pmv from tools dir $pmv_file_path = GLPI_PLUGIN_DOC_DIR . '/jamf/pmv.json'; if (!file_exists($pmv_file_path)) { - Toolbox::logDebug($pmv_file_path); - Toolbox::logDebug(Plugin::getPhpDir('jamf') . '/tools/pmv.json'); - copy(Plugin::getPhpDir('jamf') . '/tools/pmv.json', $pmv_file_path); + copy(Plugin::getPhpDir('jamf') . '/resources/pmv.json', $pmv_file_path); } // Register Cron task to update PMV periodically diff --git a/tools/pmv.json b/resources/pmv.json similarity index 100% rename from tools/pmv.json rename to resources/pmv.json From a938b649fcbd607c7682bb5a0cf49ef9a1a7d80e Mon Sep 17 00:00:00 2001 From: "Romain B." <8530352+Rom1-B@users.noreply.github.com> Date: Wed, 29 Apr 2026 15:20:04 +0200 Subject: [PATCH 2/3] Apply suggestion from @Rom1-B --- CHANGELOG.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 708b459..47d3f70 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,10 +3,11 @@ ## [UNRELEASED] -## [3.2.0] - 2026-04-23 +### Fixed - Fix failed to open stream: No such file or directory (`jamf/tools/pmv.json`) +## [3.2.0] - 2026-04-23 ### Added - GLPI 11 compatibility From 6a3c1e21734a8b3ca9e076d7ff10f8bae0c98563 Mon Sep 17 00:00:00 2001 From: "Romain B." <8530352+Rom1-B@users.noreply.github.com> Date: Wed, 29 Apr 2026 15:21:39 +0200 Subject: [PATCH 3/3] Apply suggestions from code review Co-authored-by: Romain B. <8530352+Rom1-B@users.noreply.github.com> --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 47d3f70..f2c5638 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,5 @@ # Jamf Plugin for GLPI Changelog - ## [UNRELEASED] ### Fixed @@ -8,6 +7,7 @@ - Fix failed to open stream: No such file or directory (`jamf/tools/pmv.json`) ## [3.2.0] - 2026-04-23 + ### Added - GLPI 11 compatibility