mirror of
https://github.com/nicoverbruggen/phpmon.git
synced 2025-08-08 04:20:07 +02:00
🐛 Fix for #124 ('valet --version' failing)
This commit is contained in:
@ -49,14 +49,6 @@ class Startup {
|
|||||||
breaking: true
|
breaking: true
|
||||||
)
|
)
|
||||||
|
|
||||||
Valet.shared.version = VersionExtractor.from(valet("--version"))
|
|
||||||
performEnvironmentCheck(
|
|
||||||
Valet.shared.version == nil,
|
|
||||||
messageText: "startup.errors.valet_version_unknown.title".localized,
|
|
||||||
informativeText: "startup.errors.valet_version_unknown.desc".localized,
|
|
||||||
breaking: true
|
|
||||||
)
|
|
||||||
|
|
||||||
performEnvironmentCheck(
|
performEnvironmentCheck(
|
||||||
HomebrewDiagnostics.cannotLoadService(),
|
HomebrewDiagnostics.cannotLoadService(),
|
||||||
messageText: "startup.errors.services_json_error.title".localized,
|
messageText: "startup.errors.services_json_error.title".localized,
|
||||||
@ -81,12 +73,13 @@ class Startup {
|
|||||||
breaking: true
|
breaking: true
|
||||||
)
|
)
|
||||||
|
|
||||||
let services = Shell.pipe("\(Paths.brew) services list | grep php")
|
// Determine the Valet version only AFTER confirming the correct permission is in place
|
||||||
|
Valet.shared.version = VersionExtractor.from(valet("--version"))
|
||||||
performEnvironmentCheck(
|
performEnvironmentCheck(
|
||||||
(services.countInstances(of: "started") > 1),
|
Valet.shared.version == nil,
|
||||||
messageText: "startup.errors.services.title".localized,
|
messageText: "startup.errors.valet_version_unknown.title".localized,
|
||||||
informativeText: "startup.errors.services.desc".localized,
|
informativeText: "startup.errors.valet_version_unknown.desc".localized,
|
||||||
breaking: false
|
breaking: true
|
||||||
)
|
)
|
||||||
|
|
||||||
if (!failed) {
|
if (!failed) {
|
||||||
|
Reference in New Issue
Block a user