Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Psl Laravel Package

azjezz/psl

PSL is a modern, well-typed standard library for PHP 8.4+, inspired by HHVM’s HSL. It offers safer, predictable APIs for async, collections, networking, I/O, crypto, terminal UI, and robust data validation—replacing brittle built-ins with consistent alternatives.

View on GitHub
Deep Wiki
Context7

Process

The Process component provides a typed, non-blocking API for spawning and managing child processes, built on top of PSL's IO system.

It serves as an alternative to proc_*, symfony/process, and amphp/process, with an API inspired by Rust's std::process module adapted to PSL conventions.

Usage

@example('io/process-output.php')

Command Construction

Command is an immutable builder. All with*() methods return a new instance.

  • Command::create(string $program) -- executes a program directly, bypassing the shell. Prevents shell injection and is the recommended approach.
  • Command::shell(string $command) -- interpreted by the system shell (/bin/sh -c on Unix, cmd.exe on Windows). Allows pipes, globbing, and variable expansion.

Stdio Configuration

Stdio controls what happens with each standard I/O stream:

  • Stdio::piped() -- pipe between parent and child (default for stdout/stderr)
  • Stdio::inherit() -- child inherits the parent's descriptor
  • Stdio::null() -- attach to /dev/null (default for stdin)
  • Stdio::tty() -- connect directly to the terminal, useful for interactive programs (Unix only)
  • Stdio::fromStreamHandle($handle) -- use an existing stream handle

Examples

Collect Output

@example('io/process-collect-output.php')

Check Exit Status

@example('io/process-exit-status.php')

Write to Stdin

@example('io/process-stdin.php')

Shell Commands

@example('io/process-shell.php')

Cancellation

@example('io/process-timeout.php')

Signals

@example('io/process-signals.php')

Environment Variables

@example('io/process-environment.php')

Non-Blocking Poll

@example('io/process-poll.php')

See src/Psl/Process/ for the full API.

Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
davejamesmiller/laravel-breadcrumbs
artisanry/parsedown
christhompsontldr/phpsdk
enqueue/dsn
bunny/bunny
enqueue/test
enqueue/null
enqueue/amqp-tools
bower-asset/punycode
bower-asset/inputmask
bower-asset/jquery
bower-asset/yii2-pjax
laravel/nova
spatie/laravel-mailcoach
spatie/laravel-superseeder
laravel/liferaft
nst/json-test-suite
danielmiessler/sec-lists
jackalope/jackalope-transport
twbs/bootstrap4