💾 Archived View for zigford.org › downgrade-gentoo-from-testing-to-stable.gmi captured on 2023-11-04 at 11:37:30. Gemini links have been rewritten to link to archived content

View Raw

More Information

⬅️ Previous capture (2023-03-20)

-=-=-=-=-=-=-

about

links

scripts

Sharing linux/windows scripts and tips

Downgrade Gentoo from testing to stable

August 05, 2018 — Jesse Harris

At some point in my main Gentoo boxes life I added the ~amd64 keyword into my make.conf. I don't remeber why I did this, but I can't think of a reason I need my entire install to be bleeding edge.

~~~

I did some googling around on the best approach to achieve this and from what I read on forums, having a bunch of testing packages downgrade to stable is not such a good idea.

One reason might be that per app config files are usually only designed to be backward compatible, not forward compatible.

At any rate, the idea is to gather a list of currently installed testing packages and add them to package.keywords for their current version.

With this method, eventually those packages will become stable.

The method I used is basically from the sabayon wiki with a few tweaks.

sabayon wiki

```

ACCEPT_KEYWORDS=amd64

```

```

equery -C -N list -F '=$cpv $mask2' '*' | \

grep \~ | sed 's/\[~amd64 keyword\]/~amd64/' > \

/etc/portage/package.keywords/testpackages

```

Basically I added '-C' to remove colours and grep

```

emerge --ask --update --newuse --deep --with-bdeps=y @world

These are the packages that would be merged, in order:

Calculating dependencies... done!

Nothing to merge; quitting.

```

Update

18 months since making this change I thought I'd see how many of the original testing packages are still on my system. This little shell snippit uses equery to check if a package listed in the testpackages portage file made earlier is still installed on the system, and if not, update the file with a # in front.

    for i in $(awk '/=/ {print $1}' testpackages)
    do
      if ! equery l "$i" > /dev/null;
      then
        sudo sed -ie "s/\(${i/\//\\/}\)/#\1/" \
          testpackages
      fi
    done

After running this grep -c '^#' testpackages shows 368 packages no longer needed in here and conversely 118 are still required.

Tags:

gentoo

portage

© Jesse Harris

mailto:jesse@zigford.org

Generated with bashblog, a single bash script to easily create blogs like this one

bashblog