I’m trying to install a pkg using flox and it doesn’t seem to be installing the latest version available by default.
I’m trying to install FZF and by default its giving me an old version.
~/development ❯❯❯ flox install fzf
✅ 'fzf' installed to environment 'kendallm/default'
~/development ❯❯❯ which fzf
/Users/kendall/.flox/run/aarch64-darwin.default.run/bin/fzf
~/development ❯❯❯ fzf --version
0.42.0 (0.42.0)
If I search for fzf I see the latest version there
~/development ❯❯❯ flox show fzf
fzf - Command-line fuzzy finder written in Go
fzf@0.57.0
fzf@0.56.3
fzf@0.56.2
fzf@0.56.0
fzf@0.55.0
fzf@0.54.3
fzf@0.54.2
fzf@0.54.1
fzf@0.54.0
....
fzf@0.27.0 (aarch64-linux, x86_64-darwin, x86_64-linux only)
fzf@0.26.0 (aarch64-linux, x86_64-darwin, x86_64-linux only)
fzf@0.25.1 (aarch64-linux, x86_64-darwin, x86_64-linux only)
fzf@0.25.0 (aarch64-linux, x86_64-darwin, x86_64-linux only)
fzf@0.24.4 (aarch64-linux, x86_64-darwin, x86_64-linux only)
nixpkgs also seems to show a newer version compatible with my system but flox isn’t installing that one by default. How does flox determine which version to install if I don’t specify one?
https://search.nixos.org/packages?channel=24.11&show=fzf&from=0&size=50&sort=relevance&type=packages&query=fzf
what else is in your environment? Flox is going to attempt to find software that came out at the same time as other items in your environment (meaning the same commit of nixpkgs). This can be changed if
a. you upgrade the environment running flox upgrade
and there is nothing pinned to an old version.
b. You unpin whatever is pinned and run flox upgrade
c. You put the thing that needs to be pinned in its own package group.
d. You put fzf in its own package group.
(more on package groups Flox | Conflict Resolution Made Easy with Package Groups in Flox)
I don’t have anything pinned and already tried flox upgrade but it didn’t show any available.
~ ❯❯❯ flox list
awscli: awscli (1.29.9)
bat: bat (0.23.0)
curl: curl (8.2.1)
delta: delta (0.16.5)
diff-so-fancy: diff-so-fancy (1.4.4)
exa: exa (unstable-2023-03-01)
ffmpeg: ffmpeg (5.1.3)
findutils: findutils (4.9.0)
fish: fish (3.6.1)
fzf: fzf (0.42.0)
gh: gh (2.33.0)
git: git (2.41.0)
gmailctl: gmailctl (0.10.6)
gnused: gnused (4.9)
htop: htop (3.2.2)
jq: jq (1.6)
mas: mas (1.8.6)
mosh: mosh (1.4.0)
neovim: neovim (0.9.1)
ngrep: ngrep (1.47)
nmap: nmap (7.94)
ripgrep: ripgrep (13.0.0)
tealdeer: tealdeer (1.6.1)
tig: tig (2.5.8)
tree: tree (2.1.1)
vale: vale (2.28.2)
yadm: yadm (3.2.2)
youtube-dl: youtube-dl (python3.10-youtube-dl-2021.12.17)
~ ❯❯❯ flox upgrade
ℹ️ No packages need to be upgraded in environment 'kendallm/default'.
~ ❯❯❯
The install block of my flox manifest
[install]
yadm.pkg-path = "yadm"
vale.pkg-path = "vale"
jq.pkg-path = "jq"
awscli.pkg-path = "awscli"
bat.pkg-path = "bat"
curl.pkg-path = "curl"
gh.pkg-path = "gh"
exa.pkg-path = "exa"
neovim.pkg-path = "neovim"
git.pkg-path = "git"
delta.pkg-path = "delta"
ripgrep.pkg-path = "ripgrep"
diff-so-fancy.pkg-path = "diff-so-fancy"
ffmpeg.pkg-path = "ffmpeg"
gnused.pkg-path = "gnused"
findutils.pkg-path = "findutils"
fish.pkg-path = "fish"
gmailctl.pkg-path = "gmailctl"
htop.pkg-path = "htop"
mas.pkg-path = "mas"
mas.systems = ["aarch64-darwin", "x86_64-darwin"]
mosh.pkg-path = "mosh"
ngrep.pkg-path = "ngrep"
nmap.pkg-path = "nmap"
tealdeer.pkg-path = "tealdeer"
tig.pkg-path = "tig"
tree.pkg-path = "tree"
youtube-dl.pkg-path = "youtube-dl"
fzf.pkg-path = "fzf"
I’ve only ever installed things without a direct version for my default environment, so could it be that there is a dependency somewhere on a specific version? If so how can I find where that dependency is?
Okay, I figured it out. exa
was unmaintained so it had me using an older nixpkg commit than I was expecting. I was able to remove exa and upgrade my packages fine.
Do you know if there is a way to see which commits of nixpkgs are tied to which dependencies? I wonder if there is an easier way to figure out whats outdated other than guessing.
Your lockfile (.flox/env/manifest.lock
) contains this information, but not in a way that’s easy to answer the question of “which packages are old” (you would have to look up each commit to see when it created). We’re discussing internally how to make this a better experience.
1 Like