Skip to content
Open
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
13 changes: 8 additions & 5 deletions concepts/activation.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -247,8 +247,8 @@ sequenceDiagram
rect rgb(235, 248, 240)
Note over P: bash
P->>P: run setup scripts
P->>P: set user variables
P->>P: source profile.d scripts (plugins)
P->>P: set user variables
P->>P: source hook.on-activate
P->>P: exec FLOX_SHELL
end
Expand Down Expand Up @@ -278,10 +278,13 @@ which is also the variable you can use to override which shell Flox uses when
you activate an environment.

As part of this activation script,
Flox runs some initial setup, then sets the variables you've provided in the
[[vars] section of your manifest](/man/manifest.toml#vars).
It then sources every installed package's `profile.d` scripts — this is how
[plugins](/concepts/plugins) hook into activation.
Flox runs some initial setup, then sources every installed package's
`profile.d` scripts — this is how [plugins](/concepts/plugins) hook into

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps we should add the caveat that this is only true in dev (the default) and build modes, in run mode package scripts are deliberately skipped.

activation. This only happens in `dev` (the default) and `build` modes;
`run` mode deliberately skips package `profile.d` scripts. Next, it sets
the variables you've provided in the
[[vars] section of your manifest](/man/manifest.toml#vars) — these aren't
visible to profile.d scripts, only to what runs after them.
Next, the script _sources_ the `hook.on-activate` script that you've provided
in the [[hook] section of your manifest](/man/manifest.toml#hook).
Since this script is run by the Bash shell we're using,
Expand Down