DEV Community

TekWizely
TekWizely

Posted on

My-Alternatives: A wrapper for update-alternatives offering user-level customizations. Supports Debian, SUSE, and RedHat

I'm excited to announce release v0.7.0 of my-alternatives

My-Alternatives is a light-weight wrapper over update-alternatives, offering user-level customizations.

Supports Debian, SUSE, and RedHat


Easy to Get Started

With my-alternatives, configuring custom alternatives is as easy as:

# initialize my-alternatives
# note: place this in your .profile
$ eval "$( my-alternatives init )"

# customize an alternative
$ my-alternatives select <name>
Enter fullscreen mode Exit fullscreen mode

See the Project's Homepage for more information


Release Notes - v0.7.0

Re-Write

This release marks a full re-write of the my-alternatives tool, changing it into wrapper for update-alternatives that manages user-level configurations and uses them when invoking update-alternatives (i.e --admindir & --altdir).

This new approach makes it much easier to support all available commands for managing your custom alternatives.

RedHat

This release also includes support for RedHat.

This is significant because RedHat maintains its own implementation of update-alternatives, which is slightly different than the Debian version.

The RedHat version does not include the uber-useful --query command, making it impossible to integrate it using just the public API.

As such, supporting it requires a hack, exploiting knowledge of the tool's private internals.

SUSE

The SUSE implementation of update-alternatives is really just a re-branded version of the Debian tool.

Multiple Scripts

As part of introducing RedHat support, this release now includes two versions of the my-alternatives script, each named according to the primary OS flavor they support:

  • Debian / SUSE : my-alternatives-debian
  • RedHat / CentOS : my-alternatives-redhat

Top comments (0)