Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions examples/flakes/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,13 @@ This installs the "php" and "hello" outputs from the flake at `my-php-flake`. Th

## Remote flakes

Use `github:<org>/<repo>/<ref>#<output>` as the package name to install from a Github repo.
Use `github:<org>/<repo>/<ref>#<output>` as the package name to install from a Github repo. If the flake lives in a subdirectory of the repo, add `?dir=<path>` before the `#<output>`.

```json
{
"packages": [
"github:nixos/nixpkgs/5233fd2ba76a3accb5aaa999c00509a11fd0793c#hello",
"github:F1bonacc1/process-compose"
"github:nixos/nixpkgs/5233fd2ba76a3accb5aaa999c00509a11fd0793c#cowsay",
"github:jetify-com/devbox/1d9ea45e1e51826df32ef0db7035c4c00ae2c184?dir=examples/flakes/php/my-php-flake#hello"
],
"shell": {
"init_hook": null
Expand All @@ -44,4 +44,4 @@ Use `github:<org>/<repo>/<ref>#<output>` as the package name to install from a G
}
```

This installs the `hello` package from the 5233fd... commit of Nixpkgs, and the `default` output from the `F1bonacc1/process-compose` repo.
This installs the `cowsay` package from the 5233fd... commit of Nixpkgs, and the `hello` output of the flake in the `examples/flakes/php/my-php-flake` directory of the `jetify-com/devbox` repo.
8 changes: 5 additions & 3 deletions examples/flakes/remote/devbox.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
{
"packages": [
"github:nixos/nixpkgs/5233fd2ba76a3accb5aaa999c00509a11fd0793c#hello",
"github:nixos/nixpkgs/5233fd2ba76a3accb5aaa999c00509a11fd0793c#cowsay",
"github:F1bonacc1/process-compose/v1.122.0"
"github:jetify-com/devbox/1d9ea45e1e51826df32ef0db7035c4c00ae2c184?dir=examples/flakes/php/my-php-flake#hello"
],
"shell": {
"init_hook": null,
"scripts": {
"run_test": "cowsay -- hello"
"run_test": [
"hello",
"cowsay -- hello"
]
}
},
"nixpkgs": {
Expand Down
12 changes: 4 additions & 8 deletions examples/flakes/remote/devbox.lock
Original file line number Diff line number Diff line change
@@ -1,21 +1,17 @@
{
"lockfile_version": "1",
"packages": {
"github:F1bonacc1/process-compose/v1.122.0": {
"last_modified": "2026-08-17T22:53:14Z",
"resolved": "github:F1bonacc1/process-compose/673850dd20683ef14b33890444ca3416d02c751c?lastModified=1787007194&narHash=sha256-zEhXgpQdg7WRJJPvhtK9zi4U6NJCDGKWjINlZ9m6I2A%3D"
},
"github:NixOS/nixpkgs/f80ac848e3d6f0c12c52758c0f25c10c97ca3b62": {
"last_modified": "1970-01-01T00:00:00Z",
"resolved": "github:NixOS/nixpkgs/f80ac848e3d6f0c12c52758c0f25c10c97ca3b62"
},
"github:nixos/nixpkgs/5233fd2ba76a3accb5aaa999c00509a11fd0793c#cowsay": {
"github:jetify-com/devbox/1d9ea45e1e51826df32ef0db7035c4c00ae2c184?dir=examples/flakes/php/my-php-flake#hello": {
"last_modified": "1970-01-01T00:00:00Z",
"resolved": "github:nixos/nixpkgs/5233fd2ba76a3accb5aaa999c00509a11fd0793c#cowsay"
"resolved": "github:jetify-com/devbox/1d9ea45e1e51826df32ef0db7035c4c00ae2c184?dir=examples%2Fflakes%2Fphp%2Fmy-php-flake#hello"
},
"github:nixos/nixpkgs/5233fd2ba76a3accb5aaa999c00509a11fd0793c#hello": {
"github:nixos/nixpkgs/5233fd2ba76a3accb5aaa999c00509a11fd0793c#cowsay": {
"last_modified": "1970-01-01T00:00:00Z",
"resolved": "github:nixos/nixpkgs/5233fd2ba76a3accb5aaa999c00509a11fd0793c#hello"
"resolved": "github:nixos/nixpkgs/5233fd2ba76a3accb5aaa999c00509a11fd0793c#cowsay"
}
}
}
Loading