Skip to content

feat: add preHook option to landrunApp#21

Merged
srid merged 1 commit intosrid:masterfrom
adrian-gierakowski:feat/preHook
Mar 6, 2026
Merged

feat: add preHook option to landrunApp#21
srid merged 1 commit intosrid:masterfrom
adrian-gierakowski:feat/preHook

Conversation

@adrian-gierakowski
Copy link
Copy Markdown
Collaborator

This adds a preHook option to landrunApp, allowing users to
inject shell commands that run before the sandbox is initialized. This is
useful for creating directories needed by the sandbox or decrypting/setting
environment variables.

  • Modified options.nix to add preHook.
  • Updated linux/wrapper.nix and darwin/wrapper.nix to inject hooks.
  • Added integration tests in tests/flake.nix and tests/test.bats.

closes #19

This adds a `preHook` option to `landrunApp`, allowing users to
inject shell commands that run before the sandbox is initialized. This is
useful for creating directories needed by the sandbox or decrypting/setting
environment variables.

- Modified `options.nix` to add `preHook`.
- Updated `linux/wrapper.nix` and `darwin/wrapper.nix` to inject hooks.
- Added integration tests in `tests/flake.nix` and `tests/test.bats`.

closes srid#19
@srid srid merged commit ebbea23 into srid:master Mar 6, 2026
2 checks passed
@srid srid mentioned this pull request Mar 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

add preStartHooks option to landrunApp, to allow executing code before starting the sandbox

2 participants