Add Lerd support - #675
Open
geodro wants to merge 1 commit into
Open
Conversation
Author
|
@joetannenbaum sorry for the ping, I know the queue is long. This one is small, same shape as the Sail and DDEV entries, no conflicts. lerd has grown quite a bit since July, around 1.2k stars now, and people on Linux keep hitting the extension not resolving their PHP. The only difference from the others is that lerd bind-mounts at the same path as the host, so it doesn't need a pathForPhpEnv entry like DDEV does. If you'd rather keep all environments consistent there I can add one. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds Lerd to the list of detectable PHP environments, alongside Sail, Lando, and DDEV.
Lerd is an open-source, Herd-like local PHP development environment for Linux and macOS that runs Nginx, PHP-FPM, and services as rootless Podman containers. It exposes
lerd phpto run PHP inside a project's container, which is all the extension needs to resolve the environment.The entry follows the existing containerized pattern:
check:lerd php -r "echo PHP_BINARY;"to detect that Lerd manages the projectcommand:lerd phprelativePath: true, since PHP runs inside a containerOne simplification worth noting: Lerd bind-mounts the project at its identical host path and runs
lerd phpwith the container working directory set to the project root, so host and container paths line up 1:1. That means Lerd needs no entry inpathForPhpEnv, unlike DDEV which strips its/var/www/html/prefix.The
Laravel.phpEnvironmentenum, labels, and descriptions inpackage.jsonare updated to match, mirroring whatgenerate-php-envs.phpproduces from the new entry.