Blog
Release: Flox 1.4.0
Flox Team | 15 April 2025

We’ve just released version 1.4.0 of the Flox CLI. You can get the new release here.
This release contains a new feature: composition. It allows for the combination of multiple environments into a single one. This could be useful for adding a database or cache service into an existing environment, or managing environments within a monorepo. This is a new feature and does have some known issues, see caveats section.
Composition
We have full documentation available:
- Explanation of what composition is, and why you might want to use it.
- Tutorial on working with composition
To try out composition, you could:
mkdir -p imagemagick gum myproject
cd imagemagick && flox install imagemagick && cd -
cd gum && flox install gum && cd -
cd myproject; flox init
flox edit
Then add the following under the new [include]
block.
[include]
environments = [
{ dir = "../imagemagick" },
{ dir = "../gum" }
]
This will result in a single environment with the properties (packages, hooks, variables) from imagemagick
, gum
, and myproject
.
You can try composition with even fewer steps using a remote environments from FloxHub:
[include]
environments = [
{ remote = "flox/postgres" },
{ remote = "flox/redis" },
]
Flox also now has a new subcommand, include
, that can be used to refresh composed environments.
⚠️ Caveats: There are some configurations and environments that may be incomplete or broken when using composition, particularly if the environment relies upon items not included in the Flox environment manifest (e.g. a package-lock.json
or requirements.txt
file). Specifically, environments using flox init --auto-setup
are not composable. Additionally, transitive includes (included a Flox environment that includes another Flox environments) are not yet supported.
Go setup
Community member jpmcb added detection of the GOWORK
environment variable. Once set, go
can build using the defined workspace. If can also be set to off
to force specific behavior if it was previously set. See GOWORK tutorial from go.dev if you're interested in learning more about Go workspaces. #2868
Editor Configuration
By popular request, we now default to nano
for flox edit
. If you still want to use vim
or other editors, ensure that either VISUAL
or EDITOR
is set. #2910
Misc Fixes
- In-place activations (using something like
eval <(flox activate)
works again on bash-3.2 (default on macOS) https://github.com/flox/flox/pull/2942 - https://github.com/flox/flox/issues/2051
flox search
is now more friendly thanks to https://github.com/flox/flox/pull/2911 from mahyarmirrashed
Community Contributions
- From mahyarmirrashed - multiple contributions
- From jpmcb - Support GOWORK env variable for a Go workspace file