On NomadBSD 130R-20210508 and NomadBSD-1.4 I succeeded with this big package upgrade
Here are my steps:
% su
# bectl create 2021-07-21_bf-pkg-upgrade (gives you a fallback boot environment if anything goes wrong)
# sh
# for i in $(pkg query -g %n ‘py37-*’); do echo ${i}:py38-${i#py37-}; done
NB.
please notice the change in quotes (') compared to posts above mentioning this command!
With the wrong quotes the command fails silently without doing anything…
Now executing pkg query -g %n 'py37-*'
should return nothing and
executing pkg query -g %n 'py38-*'
should return a whole list of packages.
Continuing with:
# exit (return from
sh
- not strictly necessary)
# pkg upgrade (read the upgrade message and press [y] - probably necessary 2 times)
# sed -i ‘’ ‘s/python3.7/python3.8/’ /usr/local/bin/dsbxinput
# sed -i ‘’ ‘s/python3.7/python3.8/’ /usr/local/bin/lbi-gui
# sed -i ‘’ ‘s/python3.7/python3.8/’ /usr/bin/nomadbsd-chusr
# pkg remove python37
# pkg autoremove
reboot with crossed fingers (reboot meant to test if everything starts up normally, in general not needed after upgrade)
This way py38-qt5-* is updated/installed during the pkg upgrade
, so no need to do it separately,
and the only python-3.7 package left is python37
itself - it can safely be removed.
If you ignore the for i in $(pkg query...
-command, you will end up with a mess of duplicate packages for py37 and py38,
and a few py37 not upgraded to py38 (probably somewhat cleaned up by autoremove
).
After a reboot everything is coming up successfully (plank, tint2, BSD)
PS.
If you later need to boot into the boot environment created before the upgrade please read my other thread: